Memoir marks and fonts

Lars Madsen daleif at math.au.dk
Wed Jan 15 09:50:06 CET 2020


(1) Please provide a full example others can test

(2) Which engine are you using (pdflatex, xelatex , ...)

(3) Are you 100% up to date, we know babel or similar at one point started to mess with the fonts in the headers by injecting their own code.

But as long as we do not have an example that we can test, it is hard to tell.

For example, what is \gingerspacedfont ?

/Lars Madsen
Institut for Matematik / Department of Mathematics
Aarhus Universitet / Aarhus University
Mere info: http://au.dk/daleif@math<http://au.dk/daleif@imf> / More information: http://au.dk/en/daleif@math<http://au.dk/en/daleif@imf>

________________________________
From: texhax <texhax-bounces+daleif=imf.au.dk at tug.org> on behalf of Joel C. Salomon <joelcsalomon at gmail.com>
Sent: 15 January 2020 04:47
To: ΤeXhax <texhax at tug.org>
Subject: Memoir marks and fonts

After applying some content updates to a book for a client, I tried to
recompile the book, but the page headers were being set in the wrong
font.  The code that worked about two years ago looked something like this:

    \makepagestyle{headings}
    \makepsmarks{headings}
      {
        \def\chaptermark##1 { \markboth {\thetitle} {##1} }
      }
    \makeevenhead{headings}{\headingsize \gingerfont \thepage \quad
\gingerspacedfont \leftmark}{}{}
    \makeoddhead{headings}{}{}{\headingsize \gingerspacedfont \rightmark
\quad \gingerfont\thepage}

(I’m taking advantage of ExplSyntaxOn to indent and space my code.)

Tonight, this left the `\leftmark` and `\rightmark` set in the default
text font.  A bit of experimenting pointed me to this fix:

    \makepagestyle{headings}
    \makepsmarks{headings}
      {
        \def\chaptermark##1 { \markboth {\gingerspacedfont \thetitle}
{\gingerspacedfont ##1} }
      }
    \makeevenhead{headings}{\headingsize \gingerfont \thepage \quad
\leftmark}{}{}
    \makeoddhead{headings}{}{}{\headingsize \rightmark \quad
\gingerfont\thepage}

Has there been a recent change to Memoir that broke my old code?

—Joel C. Salomon
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://tug.org/pipermail/texhax/attachments/20200115/21fade56/attachment.html>


More information about the texhax mailing list