Skip to content

Long page headers

Often the title of sections and chapters are typeset as page headers. These help to quickly find your way when browsing through a book. Nice! However, the headers can become so long that they collide with the chapternumber and even totally run off the page. Consider such a long chapter title below:

\chapter{The life of Brian seen from the Pythonian perspective of the young 
         Immanuel Kant}

The typeset page can be seen below.

Long pageheader

Very often the long section or chaptertitle is also problematic in the table of contents, as can be seen below:

Long toc

My first advice would be to shorten your title. If that is not an option, the following can help. The solution is actually quite simple. You solve the latter problem by giving a shorter alternative title for the table of contents as (first) optional argument to your section macro. The former problem can be solved by specifying a chaptermark or sectionmark to use in the heading.

\chapter[The life of Brian in the perspective of Immanuel Kant]
        {The life of Brian seen from the Pythonian perspective of the young 
         Immanuel Kant}
\chaptermark{The life of Brian in the perspective of I. Kant}