-
-
Notifications
You must be signed in to change notification settings - Fork 245
/
shipout2-008.lvt
57 lines (36 loc) · 973 Bytes
/
shipout2-008.lvt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
\RequirePackage[enable-debug]{expl3}
\ExplSyntaxOn
\debug_on:n { check-declarations , deprecation }
\ExplSyntaxOff
\documentclass[oneside]{report}
\input{regression-test}
\newbox\chapteropeningbox
\newcommand\chapteropening[1]{%
\setbox\chapteropeningbox\vbox{\hsize\textwidth #1}}
\AddToHook{shipout/before}{%
% before first page only generate a verso page if there is actual material
\ifnum \ReadonlyShipoutCounter = 0
\ifvoid\chapteropeningbox \else
\RawShipout\vbox to\textheight{\vss \usebox\chapteropeningbox \vss}%
\fi
\else
% later do it always
\RawShipout\vbox to\textheight{\vss \usebox\chapteropeningbox \vss}%
\fi
}
\DebugShipoutsOn
\begin{document}
\DebugHooksOn
\START
\chapter{A}
%\chapteropening{ \centering \Huge FOO1 }
1 some text \newpage
2 some text \newpage
3 some text \newpage
\chapter{B}
\chapteropening{ \centering \Huge FOO2 }
4 some text
\chapter{C}
5 some text \newpage
6 some text
\end{document}