Graphics, Figures & TablesFootnote in Caption of Figure

Information and discussion about graphics, figures & tables in LaTeX documents.
Post Reply
md42
Posts: 7
Joined: Mon Feb 01, 2010 3:09 pm

Footnote in Caption of Figure

Post by md42 »

Hi LaTeX Community!
My Question is if it's possible to have a figure with a long caption having a footnote in the Caption.

Example:

Code: Select all

\caption[TEST TEST TEST]{TEST TEST TEST TESTTEST TEST TESTTEST\footnote{My Footnotetext} LAST 1234}
I did attach a minimal example. If you remove the numbers "1234" it works fine.
But with the numbers the text seems to be too long an the footnote is shown twice than :roll:

Backgorund is I did a survey and have to explain a word in the caption as it was know by the people attending the survey but for the reader the word is unknown.

Any ideas?
Martin
Attachments
minimal.tex
minimal example
(518 Bytes) Downloaded 391 times

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org

NEW: TikZ book now 40% off at Amazon.com for a short time.

gmedina
Posts: 2313
Joined: Wed Jul 11, 2007 11:45 pm

Footnote in Caption of Figure

Post by gmedina »

Hi,

instead of the standard \footnote command you can use the \footnotemark and \footnotetext commands:

Code: Select all

\documentclass[12pt,a4paper,twoside,titlepage]{report} 
\usepackage{subfig}
\usepackage[demo]{graphicx}

\renewcommand\thempfootnote{\arabic{mpfootnote}}

\begin{document}

\begin{figure}[htb]
  \begin{minipage}{\textwidth}
  \caption[TEST TEST TEST]{TEST TEST TEST TESTTEST TEST TESTTEST\footnotemark[1]
    LAST 1234}
  \label{tab:ModRedeployLayout}
  \centering 
  \subfloat[Foo.]{% 
    \includegraphics{grafik/foo}}
  \qquad 
  \subfloat[Bar.]{% 
    \includegraphics{grafik/bar}}
  \footnotetext[1]{My Footnotetext}
  \end{minipage}  
\end{figure}

\stepcounter{footnote}
some text\footnote{a standard footnote}

\end{document}
Remarks: 1) Subfigure is an obsolete package and shouldn't be used anymore. In its stead you can use the subfig package (as I did in my example code) or the subcaption package.
2) It's not necessary (nowadays) to explicitly declare the driver for the graphicx package (i.e., you can safely delete the pdftex option and load the package simply as \usepackage{graphicx}).
3) I used the demo option for the graphicx package to make the example compilable for everyone; this option produces black rectangles instead of actual figures. Don't forget to delete that option in your actual code.
4) Instead of a center environment I used the \centering command to prevent additional vertical space (which sometimes is not desired).
1,1,2,3,5,8,13,21,34,55,89,144,233,...
md42
Posts: 7
Joined: Mon Feb 01, 2010 3:09 pm

Footnote in Caption of Figure

Post by md42 »

Thanks gmedina,
it worked perfect!

Remarks:
I use the center Command as I have Text under the subfig withhin the minipage and while the figure should be centered the below text shoudn't.

The text is withhin the minipage as i want the text always below the figure and make sure LaTeX is not Placing the figure on one page and the text on another.
(Background is I have sevaral figures with text which shouldn't be mixed up).
Or is there a better way to achive the same?
User avatar
gmedina
Posts: 2313
Joined: Wed Jul 11, 2007 11:45 pm

Footnote in Caption of Figure

Post by gmedina »

md42 wrote:...Or is there a better way to achive the same?
That's OK.
1,1,2,3,5,8,13,21,34,55,89,144,233,...
md42
Posts: 7
Joined: Mon Feb 01, 2010 3:09 pm

Re: Footnote in Caption of Figure

Post by md42 »

Thanks gmedina :)
Post Reply