1

How to delete number of figures in the list of figures? I use \listoffigures and \captionof.

Sebastiano
  • 54,118
Anis
  • 11
  • 2
    Welcome to TeX.SX! Please post a MWE of your code. It helps us help you (e.g. to not suggest packages incompatible to your documentclass etc.). – TeXnician Jun 29 '17 at 12:16
  • IIRC, the figure number is added by \caption as part of the label field, not a separate argument to \addcontentsline. Easy solution is to use an empty [short caption] argument and write your own \addcontentsline. – John Kormylo Jun 29 '17 at 15:00

1 Answers1

2

The generic function that sets the number of content in a ToC (that also includes the LoF and LoT) is \numberline. It takes a single argument which holds the number of the entry being set. Manipulating this macro to ignore it's argument around the LoF is easy enough with the following:

\let\oldnumberline\numberline% Copy \numberline into \oldnumberline
\renewcommand{\numberline}[1]{\oldnumberline{}}% Remove number argument
\listoffigures% Set the List of Figures
\let\numberline\oldnumberline% Restore \numberline (if needed)

enter image description here

Note that the argument removal still sets the figure entries away from the margin, because the figure number is set in a box of predetermined width. If you want that removed as well, use the \numberline macro to insert a negative space:

\let\oldnumberline\numberline% Copy \numberline into \oldnumberline
\renewcommand{\numberline}[1]{\hspace*{-1.5em}}% Remove number argument
\listoffigures
\let\numberline\oldnumberline% Restore \numberline (if needed)

enter image description here

The space between the number and the title in the LoF is 1.5em (by default).

Werner
  • 603,163