Document Classesmemoir: \chapter* and ruled pagestyle

Information and discussion about specific document classes and how to create your own document classes.
Post Reply
magister
Posts: 17
Joined: Sun Aug 02, 2009 4:42 am

memoir: \chapter* and ruled pagestyle

Post by magister »

I used the \chapter* command for the Introduction to a book, which works fine to get the first page of the Introduction typeset like the chapter openers and get it into the ToC. With the "ruled" style, however, the recto page headers are empty except for the rule. (This is to be expected, I realize, since \chapter* turns off section numbering.) I would prefer that the title "Introduction" appear in in the running heads of recto as well as verso pages. I spent some time today with chapter 7 of the memoir manual, but did not figure out exactly what to do in this case. I would appreciate any help.

David

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org

NEW: TikZ book now 40% off at Amazon.com for a short time.

meho_r
Posts: 823
Joined: Tue Aug 07, 2007 5:28 pm

memoir: \chapter* and ruled pagestyle

Post by meho_r »

One way would be to create a new pagestyle to use with Introduction part. Here's an example:

Code: Select all

\documentclass{memoir}

\usepackage{lipsum}% for generating some dummy text

\makepagestyle{intro}
\makeoddfoot{intro}{}{}{\thepage}
\makeevenfoot{intro}{\thepage}{}{}
\makeheadrule{intro}{\textwidth}{\normalrulethickness}
\makeevenhead{intro}{\scshape Introduction}{}{}
\makeoddhead{intro}{}{}{Introduction}

\begin{document}

\pagestyle{ruled}
\tableofcontents

\clearpage % don't forget \clearpage before changing pagestyle
\pagestyle{intro}

\chapter*{Introduction}
\addcontentsline{toc}{chapter}{Introduction}

\lipsum[1-20]% dummy text

\clearpage
\pagestyle{ruled}

\chapter{Another chapter}

\section{A section}

\lipsum[1-20]% dummy text

\end{document}
magister
Posts: 17
Joined: Sun Aug 02, 2009 4:42 am

Re: memoir: \chapter* and ruled pagestyle

Post by magister »

Thank you very much for taking time to do this -- it works perfectly.

I also realized that I had a similar problem with the appendices. After issuing the \appendix command, the verso headers picked up the name of the appendix (the "chapter" title) but the recto headers had only the rule. I was able to modify your code, after spending some more time with chapter 7, to fix this problem too.

Best wishes,
David
Post Reply