I get confused with fancyhdr
. Let's consider this minimal example:
\documentclass{book}
\usepackage{fancyhdr}
\usepackage{lipsum}
\pagestyle{fancy}
\begin{document}
\frontmatter
\title{A dummy document}
\author{John Doe}
\maketitle
\tableofcontents
\section{Abstract}
\lipsum{2}
\mainmatter
\chapter{Foo}
\section{Neo}
\lipsum{8-12}
\section{Trinity}
\lipsum{13-20}
\chapter{Bar}
\section{Morpheus}
\lipsum{21-25}
\backmatter
\section{Appendix}
\lipsum{26}
\end{document}
I can note different header/footer styles:
- Empty (title page)
- No headers + header line + page number in roman (after title page)
- No headers + page number in roman (page with tableofcontents)
- Headers + page number in roman (other pages in frontmatter)
- No headers + page number in arabic (chapter pages)
- Headers + page numbers in arabic (other pages in mainmatter)
I don't really understand (2) and (3). How can I configure all these different configurations?
If I add the following it doesn't affect the titlepage, the chapter pages and the numbering type:
\fancyhead{}
\fancyhead[CE]{Even}
\fancyhead[CO]{Odd}
How can I configure fancyhdr to:
- Remove headers/footers on empty pages?
- Configure header/footers on chapter pages?
- Configure header/footers on other pages?
\chapter
yet the headers are empty. (3) is a normalplain
page like (5). But I haven't usedfancyhdr
in eons so I can't really write an answer... But as far as the first question goes, there is theemptypage
package.