Show author, title on even pages and section on odd pages

This commit is contained in:
Marcus Kammer 2025-01-04 11:06:12 +01:00
parent d7d0385e29
commit e031f2a9ea
Signed by: marcuskammer
GPG key ID: C374817BE285268F
2 changed files with 15 additions and 14 deletions

View file

@ -6,17 +6,17 @@
(setq TeX-command-extra-options (setq TeX-command-extra-options
"-shell-escape") "-shell-escape")
(TeX-add-to-alist 'LaTeX-provided-package-options (TeX-add-to-alist 'LaTeX-provided-package-options
'(("fontspec" "") ("geometry" "") ("scrlayer-scrpage" "") ("enumitem" "") ("caption" "") ("microtype" "protrusion=true" "expansion=true" "final" "tracking=true" "kerning=true") ("polyglossia" "") ("biblatex" "") ("float" "") ("xcolor" "table") ("booktabs" "") ("grffile" "") ("unicode-math" "") ("adjustbox" "Export") ("graphicx" "") ("etoolbox" "") ("longtable" "") ("wrapfig" "") ("rotating" "") ("ulem" "normalem") ("amsmath" "") ("amssymb" "") ("capt-of" "") ("hyperref" "pdfusetitle") ("array" "") ("pdfx" "a-1a") ("listings" ""))) '(("fontspec" "") ("geometry" "") ("scrlayer-scrpage" "autooneside=false") ("enumitem" "") ("caption" "") ("microtype" "protrusion=true" "expansion=true" "final" "tracking=true" "kerning=true") ("polyglossia" "") ("biblatex" "") ("float" "") ("xcolor" "table") ("booktabs" "") ("grffile" "") ("unicode-math" "") ("adjustbox" "Export") ("graphicx" "") ("etoolbox" "") ("longtable" "") ("wrapfig" "") ("rotating" "") ("ulem" "normalem") ("amsmath" "") ("amssymb" "") ("capt-of" "") ("hyperref" "pdfusetitle") ("array" "") ("pdfx" "a-1a") ("listings" "")))
(add-to-list 'LaTeX-verbatim-environments-local "lstlisting") (add-to-list 'LaTeX-verbatim-environments-local "lstlisting")
(add-to-list 'LaTeX-verbatim-macros-with-braces-local "path")
(add-to-list 'LaTeX-verbatim-macros-with-braces-local "url")
(add-to-list 'LaTeX-verbatim-macros-with-braces-local "lstinline")
(add-to-list 'LaTeX-verbatim-macros-with-braces-local "nolinkurl")
(add-to-list 'LaTeX-verbatim-macros-with-braces-local "hyperbaseurl")
(add-to-list 'LaTeX-verbatim-macros-with-braces-local "hyperimage")
(add-to-list 'LaTeX-verbatim-macros-with-braces-local "href") (add-to-list 'LaTeX-verbatim-macros-with-braces-local "href")
(add-to-list 'LaTeX-verbatim-macros-with-delims-local "path") (add-to-list 'LaTeX-verbatim-macros-with-braces-local "hyperimage")
(add-to-list 'LaTeX-verbatim-macros-with-braces-local "hyperbaseurl")
(add-to-list 'LaTeX-verbatim-macros-with-braces-local "nolinkurl")
(add-to-list 'LaTeX-verbatim-macros-with-braces-local "lstinline")
(add-to-list 'LaTeX-verbatim-macros-with-braces-local "url")
(add-to-list 'LaTeX-verbatim-macros-with-braces-local "path")
(add-to-list 'LaTeX-verbatim-macros-with-delims-local "lstinline") (add-to-list 'LaTeX-verbatim-macros-with-delims-local "lstinline")
(add-to-list 'LaTeX-verbatim-macros-with-delims-local "path")
(TeX-run-style-hooks (TeX-run-style-hooks
"fontspec" "fontspec"
"geometry" "geometry"

View file

@ -3,7 +3,7 @@
% Base packages % Base packages
\usepackage{fontspec} \usepackage{fontspec}
\usepackage{geometry} \usepackage{geometry}
\usepackage{scrlayer-scrpage} % Part of KOMA-Script bundle \usepackage[autooneside=false]{scrlayer-scrpage} % Part of KOMA-Script bundle
\usepackage{enumitem} \usepackage{enumitem}
\usepackage{caption} \usepackage{caption}
\usepackage[protrusion=true,expansion=true,final,tracking=true,kerning=true]{microtype} \usepackage[protrusion=true,expansion=true,final,tracking=true,kerning=true]{microtype}
@ -81,13 +81,14 @@
marginparwidth=1.5cm marginparwidth=1.5cm
} }
% Header and footer settings with scrlayer-scrpage
% % Header and footer settings with scrlayer-scrpage
\pagestyle{scrheadings} \pagestyle{scrheadings}
\clearpairofpagestyles \clearpairofpagestyles
\automark[section]{section} % Automatically mark sections \automark[subsection]{section} % \automark[<right_level>]{<left_level>}
\ihead{\@title} % Section title \ihead{\pagemark}
% \ohead{\pagemark} \chead{\Ifthispageodd{}{\@author}}
\cfoot{\thepage} \ohead{\Ifthispageodd{\leftmark}{\@title}}
\setkomafont{pageheadfoot}{\normalfont} \setkomafont{pageheadfoot}{\normalfont}
\setkomafont{pagehead}{\normalfont} \setkomafont{pagehead}{\normalfont}