% Sample file to typset a book with sections consisting out of 4 sheets
% of paper. Each sheet carries 2 pages on both sides; thus each section
% contains 16 pages.
% Willi Egger, 04-02-2002

\setupoutput[pdftex]

\definepapersize[MyPaper][height=15cm, width=10cm]
\setuppapersize[MyPaper][A4]
\setuppagenumbering[alternative=doublesided, location={header,marginedge}]
\setuparranging[2*2*4,rotated,doublesided]%

%\setupbodyfont[ppl,12pt,ber]

\definetypeface[Myfont][rm][serif][palatino][default][encoding=texnansi]
\definetypeface[Myfont][mm][math] [palatino][default][encoding=tx8r]
\setupbodyfont[Myfont,11pt]

\setuptolerance[verytolerant,stretch]%Tip Hans Hagen 14-11-2001
\setuplayout[backspace=0.8cm,topspace=1.2cm,location=middle]
\setupbackgrounds[text][text][background=screen]

\starttext
\startalignment[middle]
\vfil
This is booklet 1 \par
sheet 1
\blank[big]
{\bfd 1}
\stopalignment
\vfil
\page

\startalignment[middle]
\vfil
This is \par
\blank[big]
{\bfd 2}
\stopalignment
\vfil
\page

\startalignment[middle]
\vfil
This is booklet 1 \par
sheet 2
\blank[big]
{\bfd 3}
\stopalignment
\vfil
\page

\startalignment[middle]
\vfil
This is \par
\blank[big]
{\bfd 4}
\stopalignment
\vfil
\page

\startalignment[middle]
\vfil
This is booklet 1 \par
sheet 3
\blank[big]
{\bfd 5}
\stopalignment
\vfil
\page

\startalignment[middle]
\vfil
This is \par
\blank[big]
{\bfd 6}
\stopalignment
\vfil
\page

\startalignment[middle]
\vfil
This is booklet 1 \par
sheet 4
\blank[big]
{\bfd 7}
\stopalignment
\vfil
\page

\startalignment[middle]
\vfil
This is \par
\blank[big]
{\bfd 8}
\stopalignment
\vfil
\page

\startalignment[middle]
\vfil
This is booklet 1 \par
\blank[big]
{\bfd 9}
\stopalignment
\vfil
\page

\startalignment[middle]
\vfil
This is \par
\blank[big]
{\bfd 10}
\stopalignment
\vfil
\page

\startalignment[middle]
\vfil
This is \par
\blank[big]
{\bfd 11}
\stopalignment
\vfil
\page

\startalignment[middle]
\vfil
This is \par
\blank[big]
{\bfd 12}
\stopalignment
\vfil
\page

\startalignment[middle]
\vfil
This is \par
\blank[big]
{\bfd 13}
\stopalignment
\vfil
\page

\startalignment[middle]
\vfil
This is \par
\blank[big]
{\bfd 14}
\stopalignment
\vfil
\page

\startalignment[middle]
\vfil
This is \par
\blank[big]
{\bfd 15}
\stopalignment
\vfil
\page

\startalignment[middle]
\vfil
This is \par
\blank[big]
{\bfd 16}
\stopalignment
\vfil
\page

\startalignment[middle]
\vfil
This is booklet 2 \par
sheet 1
\blank[big]
{\bfd 17}
\stopalignment
\vfil
\page

\startalignment[middle]
\vfil
This is \par
\blank[big]
{\bfd 18}
\stopalignment
\vfil
\page

\startalignment[middle]
\vfil
This is booklet 2\par
sheet 2
\blank[big]
{\bfd 19}
\stopalignment
\vfil
\page

\startalignment[middle]
\vfil
This is \par
\blank[big]
{\bfd 20}
\stopalignment
\vfil
\page

\startalignment[middle]
\vfil
This is booklet 2 \par
sheet 3
\blank[big]
{\bfd 21}
\stopalignment
\vfil
\page

\startalignment[middle]
\vfil
This is \par
\blank[big]
{\bfd 22}
\stopalignment
\vfil
\page

\startalignment[middle]
\vfil
This is booklet 2 \par
sheet 4
\blank[big]
{\bfd 23}
\stopalignment
\vfil
\page

\startalignment[middle]
\vfil
This is \par
\blank[big]
{\bfd 24}
\stopalignment
\vfil
\page

\startalignment[middle]
\vfil
This is \par
\blank[big]
{\bfd 25}
\stopalignment
\vfil
\page

\startalignment[middle]
\vfil
This is \par
\blank[big]
{\bfd 26}
\stopalignment
\vfil
\page

\startalignment[middle]
\vfil
This is \par
\blank[big]
{\bfd 27}
\stopalignment
\vfil
\page

\startalignment[middle]
\vfil
This is \par
\blank[big]
{\bfd 28}
\stopalignment
\vfil
\page

\startalignment[middle]
\vfil
This is \par
\blank[big]
{\bfd 29}
\stopalignment
\vfil
\page

\startalignment[middle]
\vfil
This is \par
\blank[big]
{\bfd 30}
\stopalignment
\vfil
\page

\startalignment[middle]
\vfil
This is \par
\blank[big]
{\bfd 31}
\stopalignment
\vfil
\page

\startalignment[middle]
\vfil
This is \par
\blank[big]
{\bfd 32}
\stopalignment
\vfil
\page

\stoptext