aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSébastien Dailly <sebastien@dailly.me>2025-03-21 14:22:07 +0100
committerSébastien Dailly <sebastien@dailly.me>2025-03-21 14:22:07 +0100
commit869728581626dd361d7c3c9bd8d4804b72850c5e (patch)
tree0b2a46269b26fdd13b2e17e6b41259dd2fa7a3a7
parent0c2ada30f2180b8d0add9ba5e57869eaa3ffcf15 (diff)
Declare the column index as argumentHEADmaster
-rwxr-xr-xcommon/99_sidebar.tex15
-rwxr-xr-xmodel_3/resources/00_preamble.tex3
-rwxr-xr-xmodel_3/resources/99_sidebar.tex15
3 files changed, 16 insertions, 17 deletions
diff --git a/common/99_sidebar.tex b/common/99_sidebar.tex
index 5bc96cd..57d76ad 100755
--- a/common/99_sidebar.tex
+++ b/common/99_sidebar.tex
@@ -26,6 +26,17 @@
% this template.
%
% \def\nocolumns{}
+%
+% The column is supposed to be on the left on the document, with the index 0. You
+% can change this by defining a counter sidebarindex with
+%
+% \newcounter{sidebarindex}
+% \setcounter{sidebarindex}{1}
+
+\ifdefined\sidebarindex
+\else
+ \newcommand\sidebarindex{0}
+\fi
\ifdefined\nocolumns
\else
@@ -38,12 +49,12 @@
\let\endchangemargin=\endlist
\ifdefinedcolor{backsidecolor}{%
- \backgroundcolor{c[0]}{backsidecolor}
+ \backgroundcolor{c[\sidebarindex]}{backsidecolor}
}{}
% Une commande dédiée pour les notes de marge
\newcommand{\DUsidebar}[1]{%
- \switchcolumn[0]
+ \switchcolumn[\sidebarindex]
\begin{changemargin}{0.7cm}{0.7cm}
% Sélectionne la police alternative
\AltFont\selectfont
diff --git a/model_3/resources/00_preamble.tex b/model_3/resources/00_preamble.tex
index 69b2818..1ec0cd1 100755
--- a/model_3/resources/00_preamble.tex
+++ b/model_3/resources/00_preamble.tex
@@ -23,6 +23,9 @@
\input{../common/10_lists.tex}
\input{../common/10_levels.tex}
\input{../common/10_nowidows.tex}
+\def\nocolumns{}
+\newcommand\sidebarindex{1}
+\input{../common/99_sidebar.tex}
\newcommand{\DUtitletitle}[1]{%
\begin{CaviarDreamsFont}%
diff --git a/model_3/resources/99_sidebar.tex b/model_3/resources/99_sidebar.tex
deleted file mode 100755
index d8ecbfd..0000000
--- a/model_3/resources/99_sidebar.tex
+++ /dev/null
@@ -1,15 +0,0 @@
-\def\nocolumns{}
-\input{../common/99_sidebar.tex}
-
-% Une commande dédiée pour les notes de marge
-\renewcommand{\DUsidebar}[1]{%
- \switchcolumn[1]
- \begin{changemargin}{0.5cm}{0.0cm}
- \small
- \ifdefinedcolor{textsidecolor}{\color{textsidecolor}}{}
- #1
- \end{changemargin}
- \vspace{\notesep}
- \switchcolumn
- \ifdefinedcolor{textsidecolor}{\color{black}}{}
-}