Hi, I wrote two new imposition formats with chngeable size. The first format could be used to create flashcards with content on both sides of the paper. The number of cards on the page could be changed with the "nx" and "ny" keys for \setuppaper. \unprotect \installpagearrangement FLASHCARD {\dosetuparrangement\@@ppnx\@@ppny{\numexpr\@@ppxy*2\relax}{\numexpr \@@ppnx+\plusone\relax}{\numexpr\@@ppny+\plusone\relax}% \pusharrangedpageFLASHCARD\poparrangedpagesAB\relax} \newcounter\arrangedpageshiftX \newcounter\arrangedpageshiftY \def\dopusharrangedpageFLASHCARD#1% {\ifnum\arrangedpageshiftX<\arrangedpageX \ifodd\arrangedpageN \handlearrangedpageXandY{#1}0\arrangedpageshiftX \arrangedpageshiftY\arrangedpageA \else \handlearrangedpageXandY{#1}0{\numexpr \@@ppnx-\arrangedpageshiftX-1\relax}\arrangedpageshiftY\arrangedpageB \doglobal\increment\arrangedpageshiftX \fi \fi \ifnum\arrangedpageshiftX=\@@ppnx \doglobal\newcounter\arrangedpageshiftX \doglobal\increment\arrangedpageshiftY \fi} \def\pusharrangedpageFLASHCARD#1% {\doglobal\increment\arrangedpageN \reportarrangedpage\arrangedpageN \ifnum\arrangedpageN=\numexpr\@@ppxy*2\relax \dopusharrangedpageFLASHCARD{#1}% \doglobal\newcounter\arrangedpageshiftX \doglobal\newcounter\arrangedpageshiftY \poparrangedpages \else \dopusharrangedpageFLASHCARD{#1}% \fi} \protect \setuppapersize[A7][A3,landscape] \setuppaper [nx=4,ny=2] \setuparranging[FLASHCARD] \setuplayout [location=middle,marking=on] \setupbackgrounds[page][frame=on] \starttext \dorecurse{20} {\startstandardmakeup[align=middle] Front side \recurselevel \stopstandardmakeup \startstandardmakeup[align=middle] Back side \recurselevel \stopstandardmakeup} \stoptext My second imposition definition could be used to create leaflets of any size, the number of rows is fixed to 1 but the number of column could be changed with the "nx" key for \setuppaper. \unprotect \installpagearrangement LEAFLET {\dosetuparrangement\@@ppnx1{\numexpr\@@ppnx*2\relax}{\numexpr\@@ppnx+ \plusone\relax}2% \pusharrangedpageLEAFLET\poparrangedpagesAB\relax} \def\pusharrangedpageLEAFLET#1% {\doglobal\increment\arrangedpageN \reportarrangedpage\arrangedpageN \ifnum\arrangedpageN=\plusone \handlearrangedpageXandY{#1}0{\numexpr\@@ppnx-1\relax}0 \arrangedpageA \else\ifnum\arrangedpageN>\numexpr\@@ppnx+1\relax \handlearrangedpageXandY{#1}0{\numexpr\arrangedpageN-\@@ppnx-2 \relax}0\arrangedpageA \else \handlearrangedpageXandY{#1}0{\numexpr\arrangedpageN-2\relax}0 \arrangedpageB \fi\fi \ifnum\arrangedpageN=\arrangedpageT \poparrangedpages \fi} \protect \setuppapersize[DL][A1,landscape] \setuppaper [nx=3] \setuparranging[LEAFLET] \setuplayout [location=middle,marking=on] \setupbackgrounds[page][frame=on] \starttext \dorecurse{6} {\startstandardmakeup[align=middle] \ssd Page \recurselevel \stopstandardmakeup} \stoptext I hope both arrangment styles could be integrated in one of the next releases, the FLASHCARD style is a must have for me because I use it sometimes and I'm not interested to always define one of these styles in my document. Wolfgang
participants (1)
-
Wolfgang Schuster