2

How to align the captions in the list of figures ?

I have the following code:

\usepackage[subfigure]{tocloft}
\renewcommand*\cftfigpresnum{Figure~}
\settowidth{\cftfignumwidth}{\cftfigpresnum}
\renewcommand{\cftfigaftersnumb}{\quad~~}

This code produces:

Figure 1 xxxxxxxxxxxx....34

Figure 2 yyyyyyyyyyyyyyyyy
            yyyyy.........................35

I would like to change to look like this:

Figure 1 xxxxxxxxxxxx....34

Figure 2 yyyyyyyyyyyyyyyyy
               yyyyy......................35

The problem I want to solve is to remove any "YYY" below the term "Figure 2" and align up with the above caption just when it starts.

lockstep
  • 250,273
  • 1
    I borrowed the answer from the great Tom at http://texblog.wordpress.com/2007/07/30/list-of-figures-and-list-of-tables-listoffigures-listoftables/#comment-3281

    My code should be:

    \newlength{\mylen} \renewcommand*\cftfigpresnum{Figure~} \settowidth{\mylen}{\cftfigpresnum\cftfigaftersnum} \addtolength{\cftfignumwidth}{\mylen}

    Thanks, Fred

    – user7806 Sep 15 '11 at 09:26
  • 4
    your comment is really an answer. if you enter it as an answer, i'll upvote it. – barbara beeton Sep 15 '11 at 12:19

1 Answers1

3

Solution by Tom and Gonzalo in List of Figures - how to add caption label, as commented by the OP:

\newlength{\mylen}
\renewcommand*\cftfigpresnum{Figure~}
\settowidth{\mylen}{\cftfigpresnum\cftfigaftersnum}
\addtolength{\cftfignumwidth}{\mylen}
Stefan Kottwitz
  • 231,401