Quantcast
Channel: User h-2 - TeX - LaTeX Stack Exchange
Viewing all articles
Browse latest Browse all 13

Changing TOC style of scrbook with scrlayer-scrpage

$
0
0

I am using the following to define my default pagestyle and adjust it for the first page of chapters to also include the footer:

\usepackage[headsepline,footsepline]{scrlayer-scrpage}%% set DEFAULT pagestyle\pagestyle{scrheadings}\clearpairofpagestyles\ihead{\workAuthor}\ohead{\headmark}\automark[section]{chapter}\ofoot{\pagemark}%% Chapter begin\newpairofpagestyles[scrheadings]{chap-begin}{%\KOMAoptions{headsepline=false}\ihead*{}}\renewcommand*{\chapterpagestyle}{chap-begin}

This works exactly as expected, so far so good. Now I want all the TOC pages (including list-of-figures, list-of-listings, ...) to look just like regular pages with the full header and footer, because IMHO they are not chapter and since there are lot of pages altogether it's nice to have footers and headers to not get confused.

I have tried this:

\BeforeTOCHead[toc]{%\clearpairofpagestyles\KOMAoptions{headsepline=true}\ihead{\workAuthor}\ohead{\headmark}\automark[section]{chapter}\ofoot{\pagemark}}

And this:

\newpairofpagestyles{sameasdefault}{%\KOMAoptions{headsepline=true}\ihead{\workAuthor}\ohead{\headmark}\automark[section]{chapter}\ofoot{\pagemark}}%% overwrite style for first page of list-of-*\BeforeTOCHead[toc]{%\clearpairofpagestyles\pagestyle{sameasdefault}}

But neither has any effect. The TOC, LOF... have regular plain-style.

For some reason the first page of the list-of-listings appears differently from the rest of TOCs: it doesn't have plainstyle, it has the regular footer (I assume it's treated like a generic chapter*) but curiously it also has the ohead entry but no headsepline 🤷‍♂️

Thank you for your help!

P.S: Note that I do not want to manipulate the plain-style in general, because I have many other pages (e.g. part) that should remain plain.


Viewing all articles
Browse latest Browse all 13

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>