General ⇒ Force caption to continue on next page?
-
- Posts: 1
- Joined: Thu Jul 31, 2008 11:46 pm
Force caption to continue on next page?
Thanks!
Learn LaTeX easily with newest books:
The LaTeX Beginner's Guide: 2nd edition and perfect for students writing a thesis
The LaTeX Cookbook: 2nd edition full of practical examples for mathematics, physics, chemistry, and more
LaTeX Graphics with TikZ: the first book about TikZ for perfect drawings in your LaTeX thesis
Force caption to continue on next page?
Code: Select all
\documentclass{article}
\usepackage{afterpage}
\usepackage{nonfloat}
\usepackage{lipsum}
\begin{document}
\lipsum[1]
\afterpage{
\centering
\rule{0.85\textwidth}{0.85\textheight}
\figcaption[Short caption text for the list of figures]{\lipsum[2-3]}
\label{fig:f1}
\vspace{\intextsep}
}
\lipsum[4-8]
\end{document}
I've tried to use the caption package and \captionof instead of nonfloat and \figcaption, But it doesn't work, since, for some reason I ignore, \captionof produces a page break between the figure and the caption.
Force caption to continue on next page?
The caption package puts the caption inside a \parbox so no page break can occur inside. One can change this, but would need redefinition of internal caption commands.Juanjo wrote: I've tried to use the caption package and \captionof instead of nonfloat and \figcaption, But it doesn't work, since, for some reason I ignore, \captionof produces a page break between the figure and the caption.
But since the nonfloat package change some LaTeX internals regarding floating environments (\textfraction, \topfraction, \bottomfraction, \floatpagefraction, \@fptop, \@fpsep, and \@fpbot), I would recommend the usage of the capt-of package and \captionof{figure} instead.
Regarding the original question: The fltpage package can split figure and caption in quite an elegant way, maybe this is an alternative to splitting the caption in parts.
Force caption to continue on next page?
So, for a long caption, since no pagebreak can occur inside the caption and there is no room in the same page of the picture to typeset the caption, there is a pagebreak between picture and caption, which finally appear in separate pages. All clear now, thanks.sommerfee wrote:The caption package puts the caption inside a \parbox so no page break can occur inside. One can change this, but would need redefinition of internal caption commands.Juanjo wrote: I've tried to use the caption package and \captionof instead of nonfloat and \figcaption, But it doesn't work, since, for some reason I ignore, \captionof produces a page break between the figure and the caption.
I agree.sommerfee wrote: But since the nonfloat package change some LaTeX internals regarding floating environments (\textfraction, \topfraction, \bottomfraction, \floatpagefraction, \@fptop, \@fpsep, and \@fpbot), I would recommend the usage of the capt-of package and \captionof{figure} instead.
If I've understood its documentation, this package always writes the picture in one page and the caption in a different one (just before or just after, depending on package options). The caption is not splitted and so this package seems unable to solve the issue in the O.P.sommerfee wrote: Regarding the original question: The fltpage package can split figure and caption in quite an elegant way, maybe this is an alternative to splitting the caption in parts.