In my dissertation, I am running into the following problems with my table of contents, which is best illustrated with a figure or two, depicting ends of lines of the table of contents in my dissertation:
Sometimes the text overhangs the number, or pushes a number out of the way.
These are issues with the way that toc (plus href?) is choosing to wrap lines of text. I did not write the .cls file which makes this table of contents, but the relevant lines that I can find are the following:
\def\l@chapter#1#2{
\pagebreak[2]\par\vskip\baselineskip
\@dottedtocline{0}{0in}{0.5in}{#1}{#2}
\nopagebreak\par
\gdef\@sechack{\vskip\baselineskip\gdef\@sechack{\relax}}
with dottedtocline defined as follows:
\def\@dottedtocline#1#2#3#4#5{
\ifnum #1>\c@tocdepth
\else
\vskip \z@ \@plus.2\p@
{\leftskip=#2\relax \rightskip=\@tocrmarg
\parfillskip=-\rightskip
\parindent=#2\relax \hangindent=1.5em
\singlespace\@afterindenttrue
\interlinepenalty\@M
\leavevmode
\@tempdima=#3\relax
\advance\leftskip by\@tempdima \null\nobreak
\hskip -\leftskip
{#4}\nobreak
\leaders\hbox{$\m@th
\mkern \@dotsep mu\hbox{.}\mkern
\@dotsep
mu$}\hfill
\nobreak
\hb@xt@\@pnumwidth{\hfil\normalfont
\normalcolor #5}
\par}
\fi}
and sechack defined as:
\def\@sechack{\relax}
The closest related topic that I can find is the following: List of figures/tables lines too long with classicthesis
However, I am not using the classicthesis style, as the given format (used to?) conform to my university's style guidelines.


