In my document, I want to hide certain things from the headers/footers using ifthen
(rather than defining new page styles). For example, I'd like to hide the page number on the first few pages:
\cfoot{\ifthenelse{\thepage<11}{}{\thepage}}
This will hide the page number in pages which are smaller than 11 (so, pages 1 to 10), and show the page number if the page number is 11 or above, in the center footer.
However, this seems to only work if the page numbering is arabic. Say I wanted to change the page numbering of the first five pages to roman. Then my pages would be numbered as follows:
i, ii, iii, iv, v, 1, 2, 3, 4, 5, 6, ...
This would mess up my ifthen
conditional, because, for example, for the first page, the expression in \cfoot
would evaluate to the following:
\ifthenelse{i<11}{}{\thepage}
and i<11
doesn't make sense.
My question now is, is there perhaps a better counter to use, rather than \thepage
, which can be a non-numeric value if the page numbering is roman?
pagenumbering{some numbering system}
resets the page counter. How do you manage not to?\thepage
is not the counter, it's the output of the counterpage
with some defined formatting. You want\value{page}
which provides the real number not the formatted one\ifnum\value{page}<11\else\thepage\fi
.