1

I am using the tufte-book documentclass. I just want to be able to write multiple paragraphs in the caption of marignfigure. If I write this

\documentclass{tufte-book}
\usepackage{graphicx}

\begin{document}

\begin{marginfigure}
\includegraphics[scale=0.5]{example-image-a}
\caption{This is a paragraph This is a paragraph This is a paragraph.

This should be another paragraph.
}
\end{marginfigure}

\end{document}

then the output is

enter image description here

which is clearly flawed.

4
  • Use `\\` instead o a blank line
    – Mane32
    Commented Apr 2 at 2:08
  • I don't get the error shown. I get "Figure 1" in the first line. Are your packages up to date? Commented Apr 2 at 14:19
  • @JohnKormylo I compiled that in overleaf, and specifically, the screenshot is from the pdf output from overleaf. I am not aware of the state of the packages of overleaf. I also get this error on my local Latex set up, but I would have to check if all my packages are up to date.
    – Croqueta
    Commented Apr 3 at 3:11
  • @Mane32 That does work, thank you.
    – Croqueta
    Commented Apr 3 at 3:12

1 Answer 1

1

Multiple paragraphs are not possible, but you can insert line breaks and obtain your desired output:

\documentclass{tufte-book}
\usepackage{graphicx}

\begin{document}

\begin{marginfigure}
\includegraphics[scale=0.5]{example-image-a}
\caption{This is a paragraph This is a paragraph This is a paragraph.\\
This should be another paragraph.
}
\end{marginfigure}

\end{document}

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .