Possible Duplicate:
Avoiding page breaks shortly after section/subsection headings
Imagine that I've got a \section
(or \subsection
, \subsubsecion
, \paragraph
) at the end of the page X: in this case, even if a single row of the section can fit into the page, the section is shown into the page X.
Since in this case I'd prefer showing the section in the new page, I have to manually insert a \newpage
before the section.
How is it possible to specify that at least N rows of the section have to be shown into the page X (and in the other case, the entire section has to be shown on the page X+1)?
needspace
package, look at What are penalties and which ones are defined? and specially to\clubpenalty
. – Fran Sep 10 '12 at 9:06