0

In the following MWE,

\documentclass[12pt]{book}

\usepackage{afterpage} \usepackage{epigraph}

\usepackage{fancyhdr} \setlength{\headheight}{27.15pt} \pagestyle{fancy}

\newcommand\blankpage{% \null \thispagestyle{empty}% \addtocounter{page}{-1}% \newpage}

\newcounter{mycounter}

\setcounter{mycounter}{0}

\begin{document}

\begin{titlepage}

A title\ and its subtitle

\afterpage{\blankpage}

\end{titlepage}

\afterpage{\blankpage}

\pagenumbering{roman}

\indent Copyright \textcopyright\ 2023 The author All rights reserved.

\frontmatter

\newpage

\begin{center} (\mathit{for \ my \ partner}) \end{center}

\chapter{Preface}

\newpage

\chapter{Acknowledgements}

\newpage

\thispagestyle{empty} \tableofcontents \setcounter{tocdepth}{2}

\chapter{Introduction }

\medskip
\setlength{\epigraphwidth}{0.16\textwidth}

\epigraph{An epigraph}

\mainmatter

\chapter{The formal language}

\end{document}

the pagination of the front matter is divided into two groups, and the pattern of counting all pages and paginating only odd pages is not maintained.

How may these problems be resolved?

I would prefer it if all pages in front matter were paginated.

1 Answers1

1

Here is an answer based upon a tip by @egreg in the comment section:


\documentclass[12pt]{book}

\usepackage[greek,english]{babel}

\usepackage{hyperref}

\usepackage{afterpage} \usepackage{epigraph}

\usepackage{fancyhdr} \setlength{\headheight}{27.15pt} \pagestyle{fancy}

\newcommand\blankpage{% \null \thispagestyle{empty}% \addtocounter{page}{0}% \newpage}

\newcounter{mycounter}

\setcounter{mycounter}{1}

\begin{document}

\begin{titlepage} 

    A title\\
    and its subtitle

    \afterpage{\blankpage}      

\end{titlepage}

\frontmatter    
\pagenumbering{roman}



\indent Copyright \textcopyright\ 2023 The author All rights reserved.


\newpage

\begin{center}
    \(\mathit{for \ my \ partner}\) 
\end{center}

\chapter{Preface}

\newpage

\chapter{Acknowledgements}

\newpage


\tableofcontents
\setcounter{tocdepth}{2}

\chapter{Introduction } 

\medskip
\
\setlength{\epigraphwidth}{0.16\textwidth}

\epigraph{An epigraph}

\mainmatter

\chapter{The formal language}

\end{document}