hi there,
When adding figures or tables, I'm editing the \caption entry in order to add formating to the caption text (and distinguish it from the main text) in the following form:
\caption{\sffamily \footnotesize blah blah blah}
However, when I create the LOF, the caption text in the list maintains the format style applied in the caption entry (i.e. \sffamily \footnotesize).
I was wondering if there is any option to ignore the applied style in the LOF and use another format style, such as \textnormal \normalsize ?
I've tried tocloft but have only been able to change the style of the list numbers, not the caption title itself. For example
Current output:
1.1 (<- in '\textnormal\normalsize' style) - blah blah blah (<- in '\sffamily\footnotesize' style)
Desired output:
1.1 (<- in '\textnormal\normalsize' style) - blah blah blah (<- in '\textnormal\normalsize' style).
Thanks in advance
Text Formatting ⇒ ignore caption style from list of figures
NEW: TikZ book now 40% off at Amazon.com for a short time.

ignore caption style from list of figures
Hi,
Please note that the changes affect only the captions and not the entries in the LoF.
it is not a good idea to modify the caption font atributes like that. You can use the features provided by the caption package. A little example:gdoglz wrote:...
\caption{\sffamily \footnotesize blah blah blah}
...
Code: Select all
\documentclass{book}
\usepackage{caption}
\captionsetup{font=sf,size=footnotesize}
\begin{document}
\listoffigures
\begin{figure}[!ht]
\centering
\rule{4cm}{2cm}
\caption{this is just a caption for test figure one.}
\label{fig:test1}
\end{figure}
\begin{figure}[!ht]
\centering
\rule{4cm}{2cm}
\caption{this is just a caption for test figure two.}
\label{fig:test2}
\end{figure}
\end{document}
1,1,2,3,5,8,13,21,34,55,89,144,233,...
Re: ignore caption style from list of figures
Brilliant! Thanks a lot!!