1

Why does a \pagebreak push the heading at the top of the next page down? To match other pages, I need to add \vspace*{-3\baselineskip} after the page break.enter image description here

\documentclass[a4paper]{article}
\usepackage{amsmath}
\usepackage{amssymb}
\usepackage{dsfont}
\usepackage{indentfirst}
\usepackage{fullpage}
\usepackage{titling}
\usepackage{fancyhdr}
\usepackage{graphicx}
\usepackage{epstopdf}

\pagestyle{fancy}
\setlength{\headheight}{0pt}
\setlength{\headsep}{32pt}
\setlength{\droptitle}{-4em}
\lhead{-}
\rhead{-}

\renewcommand\thesection{A-\arabic{section}}
\renewcommand\thesubsection{\thesection-\arabic{subsection}}
\renewcommand\thesubsubsection{\thesubsection \ \alph{subsubsection})}

\begin{document}

\subsection{}
\pagebreak
\subsection{}

\end{document}
  • Would you please add a Minimal Working Example (that is, a complete source file, from \documentclass to \end{document}) that illustrates the problem you are reporting? – GuM Aug 24 '15 at 13:19
  • BTW, the showframe package helps. For normal text, \includegraphics or \rule I don't see any difference. – John Kormylo Aug 24 '15 at 17:51
  • Also, I HAVE noticed that the first page of a document requires \vspace*{-11.05532074pt} in order to show a full page graphic. – John Kormylo Aug 24 '15 at 18:10
2

It is not \pagebreak, but fancyhdr.

If you look at the warnings in the log file, you'll see

Package Fancyhdr Warning: \headheight is too small (0.0pt): 
 Make it at least 12.0pt.
 We now make it that large for the rest of the document.
 This may cause the page layout to be inconsistent, however.

This explains the fact that the second page is moved 12pt down. Comply with the recommendation and you'll not have the problem.

| improve this answer | |
  • Ah, I didn't see the error extend past 'Package Fancyhdr Warning: headheight is too small (0.0pt): Make it at least 12.0pt.' Do you know how to turn this off? – Dimpl Aug 27 '15 at 9:38

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.