
¿Alguien podría modificar el siguiente código para obtener un documento cuyos márgenes estén a la derecha, en lugar de a la izquierda? El encabezado aún debe extenderse más allá del margen.
\documentclass[twoside=semi, titlepage]{scrreprt}
\usepackage[
vmargin=2.5cm, heightrounded,
left=6cm, right=2cm,
marginparwidth=3.5cm, marginparsep=0.5cm,
showframe
]{geometry}
\usepackage[
automark,
headwidth=textwithmarginpar:-\the\marginparwidth- \the\marginparsep:marginpar,
footwidth=textwithmarginpar:-\the\marginparwidth-\the\marginparsep:marginpar
]{scrlayer-scrpage}
\clearpairofpagestyles
\ofoot{\pagemark}
\ohead{\normalfont MATH UNIT}
\usepackage{blindtext}
\begin{document}
\section{Section}
\Blindtext\marginpar{Margin text}
\Blindtext\marginpar{Margin text}
\Blindtext[1]
\blinddocument
\end{document}
Respuesta1
Cambie la configuración de left
y right
en las opciones de geometría. Para la posición del encabezado y pie de página, establezca los desplazamientos en 0pt explícitamente. (No sé por qué es necesario).
\documentclass[twoside=semi, titlepage]{scrreprt}
\usepackage[
vmargin=2.5cm, heightrounded,
left=2cm, right=6cm,% <- changed
marginparwidth=3.5cm, marginparsep=0.5cm,
showframe
]{geometry}
\usepackage[
automark,
headsepline,% <- to show the headwidth
footsepline,% <- to show the footwidth
headwidth=textwithmarginpar:0pt:0pt,% <- changed
footwidth=textwithmarginpar:0pt:0pt% <- changed
]{scrlayer-scrpage}
\clearpairofpagestyles
\ofoot{\pagemark}
\ohead{\normalfont MATH UNIT}
\usepackage{blindtext}% dummy text
\begin{document}
\section{Section}
\Blindtext\marginpar{Margin text}
\Blindtext\marginpar{Margin text}
\Blindtext[1]
\blinddocument
\end{document}
Tenga en cuenta que he usado opciones headsepline
y footsepline
para mostrar las posiciones del encabezado y pie de página.