Possible Duplicate:
Chapter title in header too long

I'm using LaTeX to write a report, but some of the sections and subsections have long titles, and these titles overlap in the header of the pages. An example code of what I mean is below.

\documentclass[a4paper,11pt]{article}

\begin{document}
\pagestyle{fancy} % makes the header look fancy

\section{this is a very long section}
\subsection{this is a bery long subsection. Going to overlap}

test1

\newpage

test2

\end{document}


If you look at the second page of the PDF that is generated the header is overlapping. Is there a way of auto-scaling or manually scaling the header sizes so they don't overlap?

marked as duplicate by Thorsten, diabonas, barbara beeton, cmhughes, egregMar 14 '12 at 21:05

• You're putting too much information in you headers; even scaling them you will get overlaps or unreadable text – egreg Mar 14 '12 at 16:15
• @Mark: In most cases, we can get rid of "LaTeX:" in the question title altogether. This is often the case with questions migrated from Stack Overflow. – doncherry Mar 14 '12 at 16:17
• @doncherry: That's a good point, but it's useful to differentiate it from, say, ConTeXt in some cases. You're definitely right here though. – qubyte Mar 14 '12 at 16:21
• – Thorsten Mar 14 '12 at 16:43

 \section[short header]{this is a very long section}