When I manually set the page number to appear in the \cfoot
with scrlayer-scrpage, I get both page numbers: one in the \cfoot
and one in the \ofoot
. The one in the \ofoot
is only triggered by the twoside
option of the documentclass. Adding a \clearpairofpagestyles
directly after loading scrlayer-scrpage makes the header disappear as well, which I find strange - I thought this option was meant to clear the styles before defining a new style. Why does it make the header which is loaded after it disappear? And how do I get rid of the default page number in the \ofoot
?
MWE:
\documentclass[twoside, chapterprefix=true]{scrreprt}
\usepackage[manualmark]{scrlayer-scrpage}
%\clearpairofpagestyles
%%--"Chapter #" in lehead (only for numbered chapters), chapter name in rohead
\renewcommand*\chaptermark[1]{%
\markboth{\ifnumbered{chapter}{\chaptermarkformat}{}}{#1}%
}
\AfterTOCHead[toc]{\markboth{}{\contentsname}}
\cfoot[\pagemark]{\pagemark}
\usepackage{lipsum}
\begin{document}
\chapter{First}
\lipsum[1-18]
\end{document}
\ofoot[]{}
, which solved the problem. But I suppose that this isn't very good style? I'm not very good at KOMA-script. I'm trying to learn but I find the documentation a bit hard to grasp, especially the Additonal Information chapters.