[Tex/LaTex] KOMA script – Page heading for unnumbered chapter vs. automark

header-footerkoma-script

I'm using the following document structure based on KOMA script classes and styles

\documentclass[11pt,a4paper,BCOR10mm,DIV11,toc=listof]{scrbook}
\usepackage[nouppercase,headsepline]{scrpage2}
\pagestyle{scrheadings}
\clearscrheadfoot
\automark[section]{chapter}
\chead{\headmark}

(plus some more stuff I'm not listing here). This works very well in general. But I do have an unnumbered chapter like this

  \addcontentsline{toc}{chapter}{Bla bla}
  \chapter*{Bla bla}

and I want its title (no number) to appear in the heading of right pages (left pages blank as there are no numbered sections in this chapter). As was to be expected, this does not work out of the box, it currently lists the name of the previous chapter (list of figures).

How can I make it work? Would a manually issued \markboth{}{Bla bla} be the right way to go? From the KOMA script documentation I'm not quite sure how that would interfere with the automark stuff.

Best Answer

With the KOMA-Script classes scrbook and scrreprt you can use \chaptermark{...}, \sectionmark, \chaptermarkformat{...}, \sectionmarkformat{...} to set and format the running headings. A little example:

\documentclass[11pt,a4paper,BCOR10mm,DIV11,toc=listof]{scrbook}
\usepackage[nouppercase,headsepline]{scrpage2}
\pagestyle{scrheadings}
\clearscrheadfoot
\automark[section]{chapter}
\chead{\headmark}
\usepackage{lipsum}

\begin{document}

\chapter{A numbered chapter}
\section{Test section}
\lipsum[1-5]
\chapter*{A chapter without number}
\renewcommand*{\chaptermarkformat}{}
\renewcommand*{\sectionmarkformat}{}
\chaptermark{}
\sectionmark{A chapter without number}
\lipsum[1-30]

\end{document}