Changes

Jump to navigation Jump to search
1,953 bytes added ,  07:32, 18 June 2020
m
→‎Custom imposition schema: elaborated a bit more
\stoptext
</context>
 
If it is necessary to have a different imposition scheme for the second page it is possible to create an arrangement that spans two physical pages. As an example the following schema arranges the pages like this
 
<pre>P4 P1
R3 R2
 
P5 P6
P7 P8</pre>
 
<context source=yes>
\installpagearrangement 1*4*reversed*1*4
{\dosetuparrangement{2}{2}{4}{3}{3}% X,Y,Total,hcutmarks,vcutmarks
\pusharrangedpageFOURSINGLESIDEDFOLDEDREVERSED\poparrangedpagesAB\relax}
 
\def\pusharrangedpageFOURSINGLESIDEDFOLDEDREVERSED#1%
{\advancearrangedpageN
\reportarrangedpage\arrangedpageN
\ifcase\arrangedpageN
\or \handlearrangedpageXandY{#1}010\arrangedpageA % 1 rot,hskip,vskip
\or \handlearrangedpageXandY{#1}111\arrangedpageA % 2
\or \handlearrangedpageXandY{#1}101\arrangedpageA % 3
\or \handlearrangedpageXandY{#1}000\arrangedpageA % 4
\or \handlearrangedpageXandY{#1}000\arrangedpageB % 5
\or \handlearrangedpageXandY{#1}010\arrangedpageB % 6
\or \handlearrangedpageXandY{#1}001\arrangedpageB % 7
\or \handlearrangedpageXandY{#1}011\arrangedpageB % 8
\poparrangedpages
\fi}
</context>
 
The <code>\arrangedpageA</code> and <code>\arrangedpageB</code> are box registers that you can use to build up your desired output pages. They actually go up to <code>\arrangedpageH</code>.
 
''Note:'' if your imposition scheme needs more than eight physical pages see below [[#Imposition_by_signatures|Imposition by signatures]] on how to interface with an external imposer program.
 
As you can see in
 
https://source.contextgarden.net/tex/context/base/mkiv/page-imp.mkiv?search=poparrangedpages.+
 
there are various alternative definitions of <code>\poparrangedpagesAB</code> that manipulate to box registers in different ways to output the desired imposition. The macro <code>\installpagearrangement</code> makes the generic <code>\poparrangedpages</code> use one of those alternatives (in this case <code>\poparrangedpagesAB</code>).
== Cut marks ==

Navigation menu