Changes

Jump to navigation Jump to search
1,827 bytes added ,  13:31, 20 April 2019
m
Lowercase switch name
< [[Structurals]] | [[Visuals]] >
==What is Imposition?==To impose means to place pages on a bigger sheet in such a way that one can fold and cut the sheet to get a booklet or something similar. Here are some examples:
To impose means to order * Placing four A5 pages on both sides of an A4 sheet: 1 and 4 on the back, 2 and 3 on the front.* Placing 64 inner pages of a bigger book on one printing sheet, to produce one signature.* One of those brochures made by folding an A4 sheet in a wayinto three pieces. One could typeset this brochure as two pages with three columns each, that you get a booklet (or something similar) with correct page order after foldingonce could make six pages and impose them.In the simplest case you impose four A5 pages * Printing address labels on both sides of an A4 sheet, eight labels per sheet.
In a print shop it could be that you've to place 64 inner pages of a book on one printing sheet. For private use you could want to zigzag-fold an A4 sheet as a brochure that fits nicely general, imposition is accessed in a business envelope. You could make two pages with three columns eachConTeXt using {{cmd|setuparranging}}, or you could make six pages from the command line as follows (mkiv and impose themmkii, respectively):<pre>context --pdfarrange=..Another "style" of imposition is to place several identical templates on one sheet, etexexec --pdfarrange=.g. labels.</pre>
==Imposition schemas==
===Default schemas===
ConTeXt has some built-in imposition schemas (see "arranging pages" in the manual):
"form" means "one side of a sheet".
 
You can access this feature via
* {{cmd|setuparranging}}
* <tt>context --pdfarrange=...</tt> (in MkII <tt>texexec --pdfarrange=...</tt>)
{{todo|some graphical examples}}
Here's a convenient test file to help choose a schema or write a new one:
(Note that background=screen is deprecated in MKIV and should be replaced by something like background=color,backgroundcolor=lightgray.)
 
<context source=yes>
\setuppapersize[A9, landscape][A7, landscape]
 
% the schema being tested
\setuparranging [2*4]
 
% text describing the schema being tested, to print on the pages
\def\Style{[2*4]}
<texcode>% Visuals
\setupbodyfont[ss,10pt]
\setuppapersize [A7][A4] \setuparranging setuplayout [margin=0pt, width=fit, header=2*.8ex, footer=2*4,doublesided.8ex] %% the schema you want to test
\setuppagenumbering [alternative=doublesided,location=footer]
\setuplayout setupheadertexts[margin=0pt,width=fit\CONTEXT\ imposition test]  \showframe
\setupbackgrounds [text][text][background=screen,backgroundscreen=0.7]
 \setupcolors [state=start] % Where the block of pages is placed on the sheet % (Not relevant in this example, but relevant if there is space left over.)
\setuplayout [location=middle,marking=on]
\setuptolerance [tolerant]
 
\def\Style{[2*2*4,doublesided]}
 
\startbuffer[Fakepage]
\strut \blank \midaligned{\Style} \vfill \midaligned{This is page \recurselevel} \vfill
\stopbuffer
 
\setupheadertexts[\CONTEXT\ imposition test document]
\starttext
% \showframe \dorecurse{16}{\getbuffer[Fakepage]\page} \stoptext</texcodecontext>
=== Rearranging existing PDFsPDF s===
ConTeXt is also handy when you need to '''rearrange an existing pdf''' into a booklet. This is a trial-and-error solution by Mari for rearranging an A4 pdf file into 2*8 spreads on A3 sheet (-> A6 pages when printed and cut).
</texcode>
For proofing one sometimes wants to pick just some pages and when the original is A5, it is kind of handy to put them side-by-side for proofing. The command {{cmd|\filterpages}} allows you to define exactly what pages are needed. Be warned, though, that the page numbers refer to the pages in the pdf file, not the page numbers.
<texcode>
For more information, see the article on [[Including pages from PDF documents]].
=== Custom imposition schema===
 
You can create a new imposition schema to meet your needs. To do so, take a look at the imposition definitions stored in <code>page-imp.mkiv</code> and find the closest one to work with. You can access the file online:
 
https://source.contextgarden.net/?search=%5C%5Cdef%5C%5Csetuparranging
 
Let's say we want this page arrangement on one sheet (R = page upside down):
 
<pre>P4 P1
R3 R2</pre>
 
This is a mirrored/reversed version of {{cmd|setuparranging}}<code>[1*4]</code>, which gives:
 
<pre>R1 R4
P2 P3</pre>
 
<context source=yes>
% Adapted from page-imp.mkiv
\installpagearrangement 1*4*reversed
{\dosetuparrangement{2}{2}{4}{3}{3}% X,Y,Total,hcutmarks,vcutmarks
\pusharrangedpageFOURSINGLESIDEDFOLDEDREVERSED\poparrangedpagesTWO\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
\poparrangedpages
\fi}
 
\setuppapersize [A10][A8]
\setuparranging [1*4*reversed]
\setuplayout [margin=0pt, width=fit]
 
\showframe
 
\starttext
\dorecurse{4}{\vbox to \textheight{\vfill\midaligned{\tfd ABC}\vfill}\page}
\stoptext
</context>
== Cut marks ==
== Caveat: common troubles ==
Note that some features (e.g. table of contentcontents, internal references) are always disabled in imposition mode. So, they will not be included in the pdf if you ask for imposition.
To get rid of this you can use the "arrange" key for texexec.
== Getting the last page of a Booklet ==
When you use imposition to print a booklet you want to put something on the very last page, the <code>quadruple</code> pagebreak did not always fill the remaining pages untill until you get a quadruple number of pages.
<texcode>
[[Category:ConTeXt-Issues]]
 
{{Getting started navbox}}
6

edits

Navigation menu