6

I am currently compiling a booklet of presentation abstracts. Each entry has a title (which I render as a \section*), an author, and the abstract text itself.

For some of the entires, LaTeX decides to break the page between the author and the abstract text, which is visually unpleasing. I want to avoid this and have breaks only between entries and within the abstract text itself.

I tried to solve this by putting \nopagebreak wherever I can, but to no avail. Putting each entry in a ‘samepage’ environment is also problematic because then LaTeX would not break within the abstract texts anymore.

How can I fix this?

My current approach is this:

\section*{Towards a Unified Theory on Brontosauruses}\nopagebreak
\vspace{-0.35em}\noindent{\large Anne Elk}\\[0.7em]\nopagebreak
\nopagebreak All brontosauruses are thin at one end, much, much thicker 
in the middle, and then thin again at the far end. […]

\vspace{0.8em}

It leads to the following output: Output of the above LaTeX code

1
  • 4
    +1 for the M. Python reference. See the needspace package, in which \Needspace{length} can be issued before the \section* to indicate a page break if there isn't at least length left on the page. Commented Sep 2, 2015 at 14:47

1 Answer 1

4

You should use \\*:

\documentclass{article}

\usepackage{lipsum}

\setcounter{secnumdepth}{-2} % no section is numbered

\begin{document}

line\par
line\par
line\par
line\par
line\par
\lipsum[1-4]

\section{Towards a Unified Theory on Brontosauruses}
\vspace{-0.35em}
\noindent{\large Anne Elk}\\*[0.7em]
All brontosauruses are thin at one end, much, much thicker
in the middle, and then thin again at the far end.

\vspace{0.8em}

\lipsum[3]

\end{document}

If you comment the first line, the first line of the abstract will be typeset in the first page.

Maybe you want to define an environment:

\newenvironment{conferenceabstract}[2]
  {\section{#1}\vspace{-0.35em}\noindent{\large #1}\\*[0.7em]}
  {\par\vspace{0.8cm}}

and input the thing as

\begin{conferenceabstract}
  {Towards a Unified Theory on Brontosauruses}
  {Anne Elk}
All brontosauruses are thin at one end, much, much thicker
in the middle, and then thin again at the far end.
\end{conferenceabstract}

The full text follows
1
  • Interesting. I have no idea why \\* works and \\\nopagebreak does not, but I'm not going to complain. I ended up combining your approach with the \needspace suggested above. Cheers! Commented Sep 2, 2015 at 15:18

You must log in to answer this question.

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