2

I'm trying to change the page style for the index, but I can't find out why that does only become effective on page 2 of the index:

\documentclass{memoir} 
\usepackage{kantlipsum} 

\makepagestyle{index} 
  \makeheadrule{index}{\textwidth}{\normalrulethickness} 
  \makeevenhead{index}{\rightmark}{}{\leftmark} 
  \makeoddhead{index}{\rightmark}{}{\leftmark} 
  \makeevenfoot{index}{Index - \thepage}{even}{even} 
  \makeoddfoot{index}{odd}{odd}{Index - \thepage} 

\makeindex 
\begin{document} 
\chapter{One} 
\kant[1-5] 
\newcount\ind\ind=1\loop\index{\the\ind}\advance\ind1\ifnum\ind<400\repeat 
\clearpage 
\pagestyle{index} 
\printindex 
\end{document} 

Page 3 of the output show a centered 3 instead of: odd odd Index - 3

1 Answer 1

4

I believe \printindex does the equivalent of a chapter start, so the first page is in chapter style.

The best way to fix this, I think, is to set an alias for the chapter pagestyle:

\clearpage 
\aliaspagestyle{chapter}{index}
\pagestyle{index} 
\printindex 
2
  • This works indeed, thanks! - does it mean that there is a bug in memoir? Commented Oct 26, 2013 at 18:53
  • No, it's working as designed - the first page of every chapter uses the pagestyle alias named 'chapter', and you can force uniformity by aliasing it to whatever suits your case. It may help to take a look at sections 7.2 and 7.3 of the memoir manual? Commented Oct 26, 2013 at 19:11

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .