{header-footer} is about customizing headers and footers, i.e., choosing a page style for certain pages (e.g. empty, plain, headings) and (for the styles employed) placing information like the current section title and page number. Popular packages are {fancyhdr}, {scrpage2}, and {titleps}.

learn more… | top users | synonyms (2)

6
votes
3answers
2k views

Right align inside header

I have a header, prepared using fancyhdr. I would like the first row of the left header to be right-aligned with the second row of the left header. In the following MWE I would like "My City" to be ...
6
votes
1answer
3k views

How to modify Memoir class' headers/footers without redefining everything

I am using the memoir class for a multi-part (and multi-book) document. The class' headers and footers suit me fine for a twoside, openright document, but I'd like to add to them the following: In ...
5
votes
3answers
303 views

Put a frame around all pages, except one, in a book

I am writing a book and would like to put a red, 5pt thick frame around all pages, except around one page in the middle of the book, which contains a figure that is bigger than the frame. The frame ...
5
votes
1answer
270 views

Set maximum number of table of contents in the header

I'm doing my presentation in beamer and I use warsaw theme. I have around 5-6 sections and they are all mentioned at the top of every page. This makes available frame space smaller. Can I limit this ...
5
votes
2answers
3k views

Page number and name in the header of each page

How do you enter a page number on the right-hand side of each page? Also, is there a command so that "My name" is on the top left corner of each page except the first page? And maybe put a bar ...
5
votes
1answer
1k views

ToC, chapter problem, adding a dot next to the number of chapter

\documentclass[openany, 10pt]{book} \usepackage[utf8]{inputenc} \usepackage[MeX]{polski} \usepackage{titleps} \usepackage[Lenny]{fncychap} %\usepackage{tocloft} \makeatletter ...
5
votes
2answers
8k views

Add Footer Text to All Slides in Beamer

Is there a way to append footer text to the slides in beamer? I wanted to get rid of the default footer, but I want to add a bit of additional text. Right now I have: %gets rid of bottom navigation ...
4
votes
1answer
232 views

How can I place marginal notes always on the right but show normal odd/even headers?

I would like to typeset a book where the odd/even pages have the same format: each has a long text section on the left and a place to put small marginal notes on the right. If necessary, I want the ...
4
votes
2answers
466 views

Why are pagenumbers centered with \pagestyle{headings} on \chapter{}'s first pages?

I'm using documentclass report with options twoside and openright. The pagestyle is headings. This is a minimal working example: \documentclass[twoside,openright]{report} \usepackage{blindtext} ...
3
votes
0answers
91 views

How make a picture slideshow [duplicate]

I would like to use beamer class as backbone for my presentation. However, I encountered a problem. My wish is to put pictures on it and for LaTeX to decide their placement and divide them on frames ...
3
votes
1answer
4k views

Increase height of fancyhdr header

How would one increase the height of the \fancyhead{} so that the text in the main body, doesn't collide with the title? I have the following MWE: \documentclass[a4paper,10pt,oneside]{article} ...
3
votes
1answer
259 views

Incorrect running heads on last page of a long table

I'm setting a table of logarithms. I'm using longtable, and it works well. Every line of the table has a markboth reference, like so: \textbf{1.03}\markboth{1.03}{1.03} & .01284 & .01326 ...
2
votes
1answer
581 views

\pagestyle{empty} on a specific number of pages

I would like to remove the style of my report on my table of contents. I formerly used \thispagestyle{empty} before \tableofcontents but it obviously works only for the first page of the table of ...
2
votes
1answer
435 views

How to change the chaptermark of bibliography

In previously asked questions about changing the chaptermark in a bibliography, I couldn't get a solution for my problem. That is why I'm asking a new question. I'm writing my thesis. The references ...
2
votes
1answer
550 views

\markboth is not working when using \chapter and \section

I am having a problem when adding \chapter and \section in the document. \markboth is not working when I compile it. I have got a link Why is \markboth not working?. But there is no solution about my ...
2
votes
1answer
188 views

titlesec: toptitlemarks and bottitlemarks broken when \section not called explicitly

This question is linked to my previous chapter-and-verse-in-header question I am trying to produce a Bible text where the Chapter and Verse references appear in the header of each page. As can be ...
2
votes
1answer
297 views

Heading exceeds margins

I am writing a document with the book class. Hence, the title of the chapter appears at the head of each even page, and the title of the section appears at the head of each odd page. However, some of ...
2
votes
1answer
2k views

fancy header/footer on pages with chapter beginning

I'd like to produce report class document with one style of page numbering. I've declared: \usepackage{fancyhdr} \fancyfoot[R]{\thepage} \pagestyle{fancy} but on pages with new chapter the page ...
0
votes
0answers
66 views

Geometry on last page of document

I would like the geometry of my file to be different on the last page of the document. I have tried something like: \AtEndDocument{\newgeometry{left=0.6in,right=0.6in,top=0.6in,bottom=1.8in}} But ...
11
votes
4answers
592 views

Reference undefined in \section with amsbook

I have a section that is devoted to the proof of a theorem, and hence I used \section{Proof of Theorem~\ref{thm}} Of course, because of the headers that are capitalized, it asks for \ref{THM} when ...
9
votes
3answers
160 views

Can I hook into the end of the document but *after* the `\clearpage`?

The code for \enddocument begins: \def\enddocument{% \let\AtEndDocument\@firstofone \@enddocumenthook \@checkend{document}% \clearpage \begingroup I'd like to put something after ...
9
votes
2answers
342 views

Stop memoir from making mathmode section names uppercase in header

I'm typesetting my thesis with memoir and in general I'm happy with the result. However, some of my section headers have math mode text like \section{The $\phi_{ij}$ matrix} which memoir comically ...
9
votes
2answers
11k views

Insert a blank page after current page

I want to insert a blank page in a document so that the text would be added to the content of the current page till it reaches end of the page, the next page would be empty, and the text continue from ...
9
votes
1answer
757 views

How to force a page to be odd

How can one trick LaTeX to believe that a given page is odd instead of even? Or alternatively call the odd-page header in a previously defined pagestyle? ...
8
votes
1answer
708 views

How to change page number location on ALL pages (including chapter pages) WITHOUT fancyhdr?

Question revised: What must I do to change the page number position on EVERY page (especially for chapters) WITHOUT using fancyhdr? Background and details: I've searched now for many, many hours ...
8
votes
2answers
363 views

longtable changes the page heading

Consider the following MWE: \documentclass{article} \usepackage{kantlipsum} \pagestyle{headings} \usepackage{longtable} \begin{document} \section{First} \kant[1] % using this longtable changes ...
8
votes
1answer
1k views

Auto-populate the frame titles from subsection titles

Is there a way to make \frametitle automatically take the \subsection heading? Or maybe equivalently, is there a way to make the section\subsection titles in the header larger? I am afraid the ...
7
votes
2answers
9k views

Chapter name in the header with \chapter*

I need to display the chapter name with the \chapter* command to the left side of the header. This is one example of what I tried: \documentclass[12pt,a4paper,oneside]{book} ...
7
votes
1answer
508 views

Page styles only work for \thispagestyle under afterpage

Using afterpage to set a page style after some page only works for \thispagestyle, but not for \pagestyle. Why is that? How can I make it work? \lipsum[1-20] produces 4 pages of text, Lorem Ipsum ...
7
votes
2answers
2k views

Remove page number from the first page of bibliography

I'm writing a thesis and I want to remove the page number of the first page of bibliography. I tried \thispagestyle{empty} \pagestyle{plain} but it seems not work. I am using ...
7
votes
3answers
2k views

How to set rightmark after \section command?

I need to typset a book with very long section names. The long names should appear in the normal text and in the ToC but not in the header, so I can’t use the optional argument. \sectionmark is my ...
7
votes
1answer
166 views

Suppress headers and footers for complete chapter

For my thesis, I need to include a chapter which can "stand alone", meaning it must be formatted in a way that allows the pages to be exported and be published separately. This means, I need to get ...
7
votes
5answers
950 views

\pagestyle{empty} doesn't work on first page of new chapter

I have a problem with page numbering in LaTeX. I don't want any page number in my document so I used \pagestyle{empty} but every time when I start a new chapter I get a page number on the bottom ...
7
votes
5answers
1k views

How do I center text in a page heading?

I'm using \markright to create a page heading. I'm having trouble centering some text in this heading, and I'd like to know how to do this. Here's my current setup: \documentclass{article} ...
6
votes
3answers
74 views

A \cite{} as name for a chapter header

I'm writing a document where each chapter is a reading record of a paper. So I want the name of the chapter to be the title of the paper, and the header of the chapter to be the short citation of the ...
6
votes
2answers
138 views

Automatically remove ruler when no header is present

This is a question triggered by Automatically remove page number in one-page documents. When activating the fancyhdr package, it is necessary to clear the headers, which I do below with \fancyhf{}, ...
6
votes
3answers
148 views

Why does \maketitle change the availability of \@title?

I am trying to include the document title in a heading using scrartcl. For some reason when I call \maketitle, the \@title variable seems to be unset and all uses of it turn up empty. My document ...
6
votes
2answers
165 views

Eliminate topspace and bottomspace in ConTeXt

Background Looking to put the page number flush to the bottom of the page using ConTeXt. The key lines in the Minimum Working Example (MWE) below are: \setuplayout[ topspace=\zeropoint, ...
6
votes
2answers
1k views

fancyhead not in small caps

The text in my fancyhead is written in small caps. I would like to have it not in small caps. How can I do? This is my fancyhead: \usepackage{fancyhdr} ...
6
votes
1answer
356 views

Headers of \chapters* take the headers of their previous \chapter

When using book.cls and using \chapter* after a \chapter, the header used in \chapter* is wrong. An example is pasted below. Is there any known workaround for that? I have tried quite some tricks ...
6
votes
1answer
958 views

First page of ToC has a page number. How to remove it?

I have a problem with the number of the page that appears on the first page of ToC (I don't want it, of course), but only when I have at last two page of ToC. When ToC takes only one page, footer and ...
6
votes
2answers
1k views

How to make custom page frame using LaTeX?

I need to make questionnaire template for automatic processing with queXF. To do this I need to produce pages like this: The queXF requirements for the pages are unique barcode for each page ...
6
votes
4answers
872 views

How to get a big table on a page with pagestyle empty?

In my document I have a table that is quite big. I would like to have this table on a page with no header and no page number. How can I get this table on a \thispagestyle{empty}? Using it withing the ...
6
votes
1answer
956 views

Change footer in beginning of chapters

I want the footer of all pages to be "Page N°X" on the right. I used this: \usepackage{fancyhdr} \pagestyle{fancy} \fancyhf{} % clear all header and footer fields \fancyhead[R]{\leftmark} ...
5
votes
1answer
102 views

Only show header if section number > 0

The current section name + chapter.section number is shown in the header. This is normal behaviour (what I want). Example: How can I remove the header text, if there is no section on the page. The ...
5
votes
1answer
208 views

scrpage2: Three “marks” for headings

As far as I know of the \automark command (scrpage2 package), it is only possible to mark two different "header-types" (e.g. sections and chapters). I'm searching for a way to mark an additional ...
5
votes
2answers
290 views

Remove “Chapter” in header of the backmatter

In my backmatter the header appears as Chapter x: chapter-name, where x is the number (or letter if I have an appendix) of the last chapter before the backmatter. How can I make the header in the ...
5
votes
3answers
72 views

Remove footer (page number) in documents that are one page long

When I create a document that has but one page, I see no reason to have a page number in the footer. I would like to remove this. There is, however, apparently no such equivalent to ...
5
votes
1answer
176 views

different sized page numbers due to \usepackage{helvet}?

I am at the end of finishing my thesis and after printing it out for final corrections I recognized that the sizes of the page numbers differ sometimes. For example page "10" and page "11". Especially ...
5
votes
1answer
128 views

How can I put the page numbers where I need them?

I need to put the number for each page that is numbered at the top right hand corner of the document. Currently that condition is satisfied except for the first page of each chapter. That is, for the ...