3

I am using the KOMA script class scrbook for a thesis and would like to get a two-side layout. In the header of each page I would like to have the chapter name included alternating on the left and right side (opposite side of the binding). When I set up a document like this:

\documentclass[
a5paper,
twoside,
fontsize=11pt,
listof=totoc
]{scrbook}

\usepackage[headsepline]{scrlayer-scrpage}
\usepackage[utf8]{inputenc}
\usepackage{blindtext}

\begin{document}
\KOMAoptions{BCOR=15mm}
\chapter{Chaptername}
\Blindtext
\end{document}

The output looks like this:

PDF output of minimal working example

Here the chapter name is missing on the odd page. Also the header appears to be very close to the top of the page.

How can I fix these two issues?

  • I would recommend to set BCOR=15mm in the document preamble, before \begin{document}. – Schweinebacke Mar 12 at 6:57
  • @Schweinebacke thanks for your recommendation. I used KOMAoptions because for the title page I used the geometry package to reduce page margins which breaks the KOMA layout. So after the title page I use the KOMAoptions to restore the KOMA layout. I don't know if this is the proper way to do it. – Axel Mar 12 at 7:55
  • 1
    An titlepage usualy uses the typing area of the book, a book cover uses other typing area. To keep things clear I use a separate file to create the book cover. – Mensch Mar 12 at 8:21
  • @Axel This would be another question. If you have additional questions, please ask them if you cannot find a similar one. However, if you use \maketitle you can declare the first title page to be a cover page with different margins (see titlepage=fistiscover the KOMA-Script manual for more information). If not, you can use option usegeometry. Then you can use geometry's commands to change the margins and to switch back. Or you can use typearea's commands to store the area settings and to restore them. – Schweinebacke Mar 12 at 10:11
3

There are different possibilitys. One is to change your line

\usepackage[headsepline]{scrlayer-scrpage}

to

\usepackage[%
  headsepline,
  automark
]{scrlayer-scrpage}
\clearpairofpagestyles % <==============================================
\ohead{\leftmark} % <==================================================
\ihead{\pagemark} % <==================================================

With ohead you define the content of the outer part of headline (chapter name), with ihead you can define the inner part of header line (I used the page number here).

With the complete code

\documentclass[%
  a5paper,
  twoside,
  fontsize=11pt,
  listof=totoc
]{scrbook}

\usepackage[utf8]{inputenc}

\usepackage[%
  headsepline,
  automark
]{scrlayer-scrpage}
\clearpairofpagestyles % <==============================================
\ohead{\leftmark} % <==================================================
\ihead{\pagemark} % <==================================================
\usepackage{blindtext}


\begin{document}

\KOMAoptions{BCOR=15mm}
\chapter{Chaptername}
\blindtext
\section{Sectionname}
\Blindtext
\end{document}

you get the result:

enter image description here

and

enter image description here

To reflect your additional questions in the comment you can use the following code. To get the page number on the first page of a chapter etc. too (good typography if page number is in the foot) use command cfoot* (the * changes the style plain for first chapter page, TOC etc. too). I also moves BCOR into the class options.

\documentclass[%
  a5paper,
  twoside,
  fontsize=11pt,
  DIV=11,         % 11 8 to change the margins and typing area <========
  BCOR=15mm,      % binding correction
  headsepline,    % for header, activates headinclude <=================
  listof=totoc
]{scrbook}

\usepackage[utf8]{inputenc}

\usepackage{scrlayer-scrpage} % <=======================================
\clearpairofpagestyles % <==============================================
\ohead{\leftmark} % <===================================================
\cfoot*{\pagemark} % <==================================================

\usepackage{blindtext}
\usepackage{showframe}


\begin{document}

\chapter{Chaptername}
\blindtext
\section{Sectionname}
\Blindtext
\end{document}

with the result:

enter image description here

  • 1
    Thanks for your help! – Axel Mar 11 at 20:51

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.