0

I am using pagenumbering{roman} for my titlepage tables and pagenumbering{arabic} for the rest. My problem is, that the part with roman numbering behaves strange, I try to explain it as follows:

first page/titlepage: no numbering
second page:          i
third page:           no numbering
fourth page:          iii
fifth page:           no numbering
sixth page:           v
seventh page:         no numbering
eighth page:          no numbering
ninth page:           viii

What I would like is an uninterrupted numbering from i to viii.

Can someone help me with that?

P.S.: This is a shortened version of my preamble:

\documentclass[a4paper,12pt]{report}
\usepackage[ngerman]{babel}
\usepackage[T1]{fontenc}
\usepackage[ansinew,latin1]{inputenc}
\usepackage{setspace}
\usepackage{geometry}
\onehalfspacing
\setcounter{secnumdepth}{4}
\setcounter{tocdepth}{1}

\begin{document}

\pagestyle{empty}
\clearpage
\pagenumbering{roman}

\begin{titlepage}
\newgeometry{margin=3cm}
\centering

Some text

\end{titlepage}


\tableofcontents
\cleardoublepage
\newpage
more text
\newpage
some more text

\newpage
some more text

\newpage
some more text

\newpage
some more text

\newpage
some more text

\pagestyle{plain}
\clearpage
\pagenumbering{arabic}
main document


:
:
\end{document}
  • What is your preamble? It's hard to say what to do without knowing a little more. – Bernard May 25 '14 at 11:44
  • 1
    It's normal in books to not put the page numbers on some pages so there is probably nothing strange with this. If you want to change it there is probably not problem in changing it either, but then you must tell us how you have done this. – pst May 25 '14 at 11:53
  • Please add a minimal working example (MWE) which shows your basic set up and demonstrates the issue. Then people will be able to suggest how you can adapt your code to include numbers even on pages they are usually omitted from. – cfr May 25 '14 at 12:11
  • I have added my preamble – DatamineR May 25 '14 at 12:25
  • 1
    \pagestyle{empty} suppresses the page number. The MWE only generates three instead of eight or nine (also not clear) pages. \newgeometry is not known, if package geometry is not loaded. – Heiko Oberdiek May 25 '14 at 15:59
1

The visibility of the page numbers can be explained the following way:

  • Page 1: \thispagestyle{empty} by \begin{titlepage}

  • Page 2: \thispagestyle{plain} by \chapter* of \tableofcontents

  • Pages 3 to 8: \pagestyle{empty} right after \begin{document}

  • Page 9: \pagestyle{plain} right before \clearpage

Page style empty means, the page number is not visible.

Also both \begin{titlepage} and \end{titlepage} resets the page counter to one.

Thus the example can be fixed by using \pagestyle{plain} instead of \pagestyle{empty} and patching environment titlepage:

\documentclass[a4paper,12pt]{report}

\usepackage{etoolbox}
\makeatletter
\patchcmd\titlepage{\thispagestyle{empty}}{}
  {}{\errmessage{Cannot patch \string\titlepage}}
\patchcmd\titlepage{\setcounter{page}\@ne}{}
  {}{\errmessage{Cannot patch \string\titlepage}}
\patchcmd\endtitlepage{\setcounter{page}\@ne}{}
  {}{\errmessage{Cannot patch \string\endtitlepage}}
\makeatother

\begin{document}

\pagestyle{plain}
\clearpage
\pagenumbering{roman}

\begin{titlepage}
\centering

Some text

\end{titlepage}


\tableofcontents
\cleardoublepage
\newpage
more text
\newpage
some more text

\newpage
some more text

\newpage
some more text

\newpage
some more text

\newpage
some more text

\pagestyle{plain}
\clearpage
\pagenumbering{arabic}
main document 
\end{document}

Alternatively of patching environment titlepage the page style and page number can be manually set:

\documentclass[a4paper,12pt]{report}

\begin{document}

\pagestyle{plain}
\clearpage
\pagenumbering{roman}

\begin{titlepage}
\thispagestyle{plain}
\centering

Some text

\end{titlepage}
\setcounter{page}{2}

\tableofcontents
\cleardoublepage
\newpage
more text
\newpage 
some more text

\newpage
some more text

\newpage
some more text

\newpage
some more text

\newpage
some more text

\pagestyle{plain}
\clearpage
\pagenumbering{arabic}
main document
\end{document}

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.