Difference between revisions of "Command/definepageshift"

From Wiki
Jump to navigation Jump to search
m (Created page with "{{Reference |name=XXX |attributes= }} == Syntax == <table cellspacing="4" cellpadding="2" class="cmd"> <tr> <td colspan="2" class="cmd">\XXX<!-- -...")
 
m (Fill in entire page)
Line 1: Line 1:
 
{{Reference
 
{{Reference
|name=XXX
+
|name=definepageshift
 
|attributes=
 
|attributes=
 
}}
 
}}
Line 7: Line 7:
 
<table cellspacing="4" cellpadding="2" class="cmd">
 
<table cellspacing="4" cellpadding="2" class="cmd">
 
   <tr>
 
   <tr>
     <td colspan="2" class="cmd">\XXX<!--
+
     <td colspan="2" class="cmd">\definepageshift<!--
       --><span class="first">{...}</span><!--
+
       --><span class="first">[''name'']</span><!--
       --><span class="second">{...}</span><!--
+
       --><span class="second">[''direction'']</span><!--
 +
      --><span class="third">[''offsets'']</span><!--
 
  --></td>
 
  --></td>
 
   </tr>
 
   </tr>
 
   <tr valign="top" class="first">
 
   <tr valign="top" class="first">
     <td class="cmd">{...}</td>
+
     <td class="cmd">[''name'']</td>
 
     <td><i>text</i> </td>
 
     <td><i>text</i> </td>
 
   </tr>
 
   </tr>
 
   <tr valign="top" class="second">
 
   <tr valign="top" class="second">
     <td class="cmd">{...}</td>
+
     <td class="cmd">[''direction'']</td>
     <td><i>text</i> </td>
+
     <td>horizontal vertical</td>
 +
  </tr>
 +
  <tr valign="top" class="third">
 +
    <td class="cmd">[''offsets'']</td>
 +
    <td>''dimension'', ''dimension'', ''dimension'', ''...''</td>
 
   </tr>
 
   </tr>
  
Line 24: Line 29:
  
 
== Description ==  
 
== Description ==  
 
+
Define a list of offsets for use by {{cmd|setuppageshift}}. If the number of pages in the document exceeds the number of offsets in the list, the offsets will be recycled &mdash; for example, the first offset in a list of four will be applied to pages 1, 5, 9, et cetera.
  
 
== Example ==
 
== Example ==
 
<texcode>
 
<texcode>
 
\setuppapersize[A5][A4, landscape]
 
\setuppapersize[A5][A4, landscape]
\setuparranging[2*2*4]
+
\setuparranging[2*2*4] % 2 sides * 2 pages per side * 4 sheets
 
\definepageshift[Hor][horizontal]
 
\definepageshift[Hor][horizontal]
 
     [0.25mm,  % page 1, sheet 1 recto
 
     [0.25mm,  % page 1, sheet 1 recto
Line 47: Line 52:
 
     0.25mm,  % p15
 
     0.25mm,  % p15
 
     -0.25mm]  % p16
 
     -0.25mm]  % p16
\setuppageshift[paper][Hor] % use the list we just defined
+
\definepageshift[Vert][vertical][-1cm, 0cm] % move every odd page 1 cmd down
 +
\setuppageshift[paper][Hor][Vert]          % use the list we just defined
 
</texcode>
 
</texcode>
  
 
== See also ==
 
== See also ==
 
+
* {{cmd|setuparranging}} because pageshifting is usually combined with printing multiple pages per sheet
 +
* {{cmd|setuppageshift}} to use the pageshift defined with this command
  
 
== Help from ConTeXt-Mailinglist/Forum ==
 
== Help from ConTeXt-Mailinglist/Forum ==
Line 57: Line 64:
 
{{Forum|{{SUBPAGENAME}}}}
 
{{Forum|{{SUBPAGENAME}}}}
  
[[Category:Commands|XXX]]
+
[[Category:Command/Layout|definepageshift]]

Revision as of 21:44, 24 June 2012

\definepageshift

Syntax

\definepageshift[name][direction][offsets]
[name] text
[direction] horizontal vertical
[offsets] dimension, dimension, dimension, ...

Description

Define a list of offsets for use by \setuppageshift. If the number of pages in the document exceeds the number of offsets in the list, the offsets will be recycled — for example, the first offset in a list of four will be applied to pages 1, 5, 9, et cetera.

Example

\setuppapersize[A5][A4, landscape]
\setuparranging[2*2*4]  % 2 sides * 2 pages per side * 4 sheets
\definepageshift[Hor][horizontal]
    [0.25mm,  % page 1, sheet 1 recto
    -0.25mm,  % page 2, sheet 1 verso
     0.15mm,  % p3, s2r
    -0.15mm,  % p4, s2v
     0.05mm,  % p5
    -0.05mm,  % p6
     0mm,     % p7
     0mm,     % p8
     0mm,     % p9
     0mm,     % p10
     0.05mm,  % p11
    -0.05mm,  % p12
     0.15mm,  % p13
    -0.15mm,  % p14
     0.25mm,  % p15
    -0.25mm]  % p16
\definepageshift[Vert][vertical][-1cm, 0cm] % move every odd page 1 cmd down
\setuppageshift[paper][Hor][Vert]           % use the list we just defined

See also

  • \setuparranging because pageshifting is usually combined with printing multiple pages per sheet
  • \setuppageshift to use the pageshift defined with this command

Help from ConTeXt-Mailinglist/Forum

All issues with: