Debian Codegraph @

texmf-dist/doc/latex/schooldocs/schooldocs-examples.tex

raw
1
2 \documentclass[a4paper,11pt]{article}
3
4 \usepackage[utf8]{inputenc}
5 \usepackage[T1]{fontenc}
6 \usepackage[english]{babel}
7 \usepackage{times,lmodern,charter}
8 \usepackage{schooldocs}
9 \usepackage{enumerate}
10 \usepackage{multicol}
11 \usepackage{centeredline}
12 \usepackage{hyperref}
13 \usepackage{lipsum}
14
15 \definecolor{darkbrown}{rgb}{0.5,0.1,0.1}
16
17 \pagestyle{collection}
18 \title{The schooldocs package}
19 \subject{Example file for titles and styles}
20 \author{Antoine Missier}
21 \institute{Royal College of Pataphysics}
22 \date{December 28, 2023}
23 \renewcommand{\titlestyle}{\Huge} %\sffamily
24 \hypersetup{colorlinks, linkcolor=blue}
25 %\setcounter{tocdepth}{0}
26
27 \begin{document}
28
29 \maketitle
30
31 On the following pages we showcase various title formatting options
32 and the different styles.
33 This initial page has been created using the \textbf{collection} style, for which
34 the main title style has been redefined through
35 \verb|\renewcommand{\titlestyle}{\Huge}|.
36
37
38 \medskip
39 In most examples (dated may 4, 2020), we have utilized
40 the \textsf{lmodern} package font, which pairs well with a sans-serif title style.
41 To achieve this, simply redefine the title style using
42 \smallskip
43 \centeredline{\verb|\renewcommand\titelstyle{\LARGE\bfseries\sffamily}|.}
44
45 \smallskip
46 For examples dated january 25 or december 28, 2023, we have opted
47 for the \textsf{charter}, or \textsf{times} fonts.
48 For these fonts, the default title style setting
49 \verb|\LARGE\bfseries| is suitable.
50
51
52 \seprule
53
54 \begin{center} \Large \color{darkbrown}
55 \bfseries Table of contents
56 \end{center}
57
58 \bigskip
59
60 \begin{multicols}{2}
61 \begin{enumerate}[\bfseries 1.]
62 \item \hyperlink{schooldocs-example-center}{\bfseries The standard title}
63 \item \hyperlink{schooldocs-example-left}{\bfseries A left-aligned title}
64 \item \hyperlink{schooldocs-example-right}{\bfseries A right-aligned title}
65 \item \hyperlink{schooldocs-example-norule}{\bfseries
66 The standard title without rule}
67 \item \hyperlink{schooldocs-example-boxed}{\bfseries A title in boxed shape}
68 \item \hyperlink{schooldocs-example-seprule}{\bfseries
69 The \texttt{\textbackslash seprule} and \texttt{\textbackslash correct} macros}
70 \item \hyperlink{schooldocs-example-small}{\bfseries A ``small'' title}
71 \item \hyperlink{schooldocs-example-classic}{\bfseries The classic style layout}
72 \item \hyperlink{schooldocs-example-elegant}{\bfseries The elegant style layout}
73 \item \hyperlink{schooldocs-example-modern}{\bfseries The modern style layout}
74 \item \hyperlink{schooldocs-example-soft}{\bfseries The soft style layout}
75 \item \hyperlink{schooldocs-example-exam}{\bfseries The exam style layout}
76 \item \hyperlink{schooldocs-example-examcorrect}{\bfseries
77 Exam style with the \texttt{\textbackslash correct} macro}
78 \item \hyperlink{schooldocs-example-collection}{\bfseries The collection style layout}
79 \item \hyperlink{schooldocs-example-identity}{\bfseries
80 The identity style in collection}
81 \item \hyperlink{schooldocs-example-small-identity}{\bfseries
82 A ``small'' title with identity}
83 \item \hyperlink{schooldocs-example-modern-small-identity}{\bfseries
84 Small title, identity and modern style}
85 \item \hyperlink{schooldocs-example-left-identity}{\bfseries
86 A left-aligned title with identity}
87 \end{enumerate}
88 \end{multicols}
89
90 \newpage
91 \hypertarget{schooldocs-example-center}{}
92 \addcontentsline{toc}{section}{The standard title}
93
94 \fontfamily{lmr}\selectfont
95 \pagestyle{empty}
96 \lfoot{}
97 \cfoot{}
98 \rfoot{}
99 \renewcommand{\subjectstyle}{}
100 \renewcommand{\authorstyle}{}
101 \renewcommand{\datestyle}{}
102 \renewcommand{\titlestyle}{\LARGE\bfseries\sffamily}
103 \renewcommand\subjectstyle{\large}
104 \setlength{\titletopskip}{-1.32cm}
105 \setlength\titlesep{2\medskipamount}
106 \schooldocstitles
107 \title{The standard title}
108 \subject[Pathography / M2A]{Pathography / Master 2A}
109 \date{May 4, 2020}
110
111 \maketitle
112 \lipsum[1]
113
114 \newpage
115 \hypertarget{schooldocs-example-left}{}
116 \addcontentsline{toc}{section}{A left-aligned title}
117
118 \renewcommand{\titleflush}{flushleft}
119 \title{A left-aligned title}
120 \maketitle
121 \lipsum[1]
122
123 \newpage
124 \hypertarget{schooldocs-example-right}{}
125
126 \renewcommand{\titleflush}{flushright}
127 \title{A right-aligned title}
128 \maketitle
129 \lipsum[1]
130
131 \newpage
132 \hypertarget{schooldocs-example-norule}{}
133
134 \renewcommand{\titleflush}{center}
135 \title{The standard title without rule}
136 \maketitle[0pt]
137 \lipsum[1]
138
139 \newpage
140 \hypertarget{schooldocs-example-boxed}{}
141
142 \renewcommand{\titlestyle}{\LARGE\sffamily\bfseries\boxedshape}
143 \title{A title in boxed shape}
144 \maketitle
145 \lipsum[1]
146
147 \newpage
148 \hypertarget{schooldocs-example-seprule}{}
149
150 \renewcommand{\titlestyle}{\LARGE\bfseries\sffamily}
151 \title{The \textbackslash seprule and \textbackslash correct macros}
152 \correct
153 \maketitle
154 \lipsum[1]\seprule\lipsum[2]\seprule\lipsum[3]
155
156 \newpage
157 \hypertarget{schooldocs-example-small}{}
158
159 \fontfamily{bch}\selectfont
160 \title{A ``small'' title}
161 \date{January 25, 2023}
162 \makesmalltitle
163 \lipsum[1]
164
165 \newpage
166 \hypertarget{schooldocs-example-classic}{}
167
168 \fontfamily{lmr}\selectfont
169 \setcounter{page}{1}
170 \pagestyle{classic}
171 \title[The classic style]{The classic style layout}
172 \date{May 4, 2020}
173 \maketitle
174 \section*{Pellentesque a nulla}
175 \lipsum[1-3]
176 \section*{Vestibulum lectus}
177 \lipsum[5-9]
178
179 \newpage
180 \hypertarget{schooldocs-example-elegant}{}
181
182 \setcounter{page}{1}
183 \setcounter{section}{0}
184 \addtolength{\headheight}{-\baselineskip}
185 \pagestyle{elegant}
186 \title[The elegant style]{The elegant style layout}
187 \schooldocstitles
188 \maketitle
189 \section*{Pellentesque a nulla}
190 \lipsum[1-3]
191 \section*{Vestibulum lectus}
192 \lipsum[5-9]
193
194 \newpage
195 \hypertarget{schooldocs-example-modern}{}
196
197 \setcounter{page}{1}
198 \setcounter{section}{0}
199 \renewcommand{\headrulewidth}{0.4pt}
200 \pagestyle{modern}
201 \title[The modern style]{The modern style layout}
202 \maketitle
203 \section*{Pellentesque a nulla}
204 \lipsum[1-3]
205 \section*{Vestibulum lectus}
206 \lipsum[5-9]
207
208 \newpage
209 \hypertarget{schooldocs-example-soft}{}
210
211 \setcounter{page}{1}
212 \setcounter{section}{0}
213 \pagestyle{soft}
214 \title[The soft style]{The soft style layout}
215 \maketitle
216 \section*{Pellentesque a nulla}
217 \lipsum[1-3]
218 \section*{Vestibulum lectus}
219 \lipsum[5-9]
220
221 \newpage
222 \hypertarget{schooldocs-example-exam}{}
223
224 \setcounter{page}{1}
225 \setcounter{section}{0}
226 \fontfamily{ptm}\selectfont
227 \pagestyle{exam}
228 \title[The exam style]{The exam style layout}
229 \date{December 28, 2023}
230 \subtitle{Duration of the test: 2\,h}
231 \maketitle
232 \section*{Pellentesque a nulla}
233 \lipsum[1-3]
234 \section*{Vestibulum lectus}
235 \lipsum[5-9]
236
237 \newpage
238 \hypertarget{schooldocs-example-examcorrect}{}
239
240 \setcounter{page}{1}
241 \setcounter{section}{0}
242 \correct
243 \maketitle
244 \section*{Pellentesque a nulla}
245 \lipsum[1-3]
246 \section*{Vestibulum lectus}
247 \lipsum[5-9]
248
249 \newpage
250 \hypertarget{schooldocs-example-collection}{}
251
252 \setcounter{page}{1}
253 \setcounter{section}{0}
254 \fontfamily{bch}\selectfont
255 \pagestyle{collection}
256 \title[The collection style]{The collection style layout}
257 \date{December 28, 2023}
258 \subtitle{Duration of the test: 2\,h}
259 \maketitle
260 \section*{Ultrices bibendum}
261 \lipsum
262 \lipsum[1-3]
263 \section*{Etiam facilisis}
264 \lipsum[1-5]
265
266 \newpage
267 \hypertarget{schooldocs-example-identity}{}
268
269 \thispagestyle{identity}
270 Here we present a single page with the \textbf{identity} style
271 within a document using the collection style.
272 \par\medskip
273 \textbf{Question:} Analyze the previous text and provide a written summary of its content.
274
275 \newpage
276 \lfoot{}
277 \cfoot{\thepage}
278 \rfoot{}
279 \renewcommand{\subjectstyle}{}
280 \renewcommand{\authorstyle}{}
281 \renewcommand{\datestyle}{}
282 \hypertarget{schooldocs-example-small-identity}{}
283
284 \setcounter{page}{1}
285 \renewcommand{\titlestyle}{\LARGE\bfseries}
286 \renewcommand\subjectstyle{\large}
287 \renewcommand{\headrulewidth}{0pt}
288 \setlength{\titletopskip}{-1.32cm}
289 \setlength\titlesep{2\medskipamount}
290 \title{A ``small'' title}
291 \date{January 25, 2023}
292 \thispagestyle{identity}
293 \schooldocstitles
294 \makesmalltitle
295 \lipsum[1]
296
297 \newpage
298 \hypertarget{schooldocs-example-modern-small-identity}{}
299
300 \setcounter{page}{1}
301 \setcounter{section}{0}
302 \title[The modern style]{The modern style layout}
303 \pagestyle{modern}
304 \thispagestyle{identity}
305 \makesmalltitle
306 \section*{Pellentesque a nulla}
307 \lipsum[1-3]
308 \section*{Vestibulum lectus}
309 \lipsum[5-6]
310
311 \newpage
312 \hypertarget{schooldocs-example-left-identity}{}
313
314 \setcounter{page}{1}
315 \lfoot{}
316 \cfoot{}
317 \rfoot{}
318 \renewcommand{\titleflush}{flushleft}
319 \title{A left-aligned title}
320 \pagestyle{empty}
321 \thispagestyle{identity}
322 \schooldocstitles
323 \maketitle
324 \lipsum[1]
325
326 \setcounter{page}{2} % for the lastpage field in headers or footers
327 \end{document}