Man page for PSTOPS-CLIP(1)

Man page for PSTOPS-CLIP(1)

NAME

pstops-clip - shuffle pages in a PostScript file

SYNOPSIS

pstops-clip [ options ] pagespecs [ infile [ outfile ] ]

DESCRIPTION

Pstops-clip rearranges pages from a PostScript document, creating a new PostScript file. The input PostScript file should follow the Adobe Document Structuring Conventions. Pstops-clip can be used to perform a large number of arbitrary re-arrangements of Documents, including arranging for printing 2-up, 4-up, booklets, reversing, selecting front or back sides of documents, scaling, etc. It is derived from Angus J. C. Duggan's pstops program, with the added ability of specifying a clippath for each page.

pagespecs follow the syntax:

 
pagespecs
= [modulo:]spec[+spec|,spec]...

spec
= [-]pageno[L|R|U][@scale][(xoff,yoff)][{x0,y0,x1,y1}]


modulo
is the number of pages in each block. The value of modulo should be greater than 0; the default value is 1.

spec
is the page specification for one page in each block. If page specs are separated by + the pages will be merged into one page; if they are separated by , they will be on separate pages.

pageno
This value specifies the relative page number within a block, and should be between 0 (for the first page in the block) and modulo-1 (for the last page in each block) inclusive. If the optional minus sign is specified, the page is relative to the end of the document, instead of the start. If there is only one page specification, with pageno zero, the pageno may be omitted.

scale
This optional parameter scales the page by the fraction specified.

L, R, U
These optional parameters rotate the page left, right, or upside-down.

xoff, yoff
These optional dimensions shift the page by the specified amount. They are in PostScript's points, but may be followed by the units cm or in to convert to centimetres or inches, or the flag w or h to specify as a multiple of the width or height.

x0, y0, x1, y1
These optional dimensions are used to specify a custom clipping path for the page.

The shift, rotation, and scaling are performed in that order regardless of which order they appear on the command line.

OPTIONS

The following options are supported:
--help
Print usage information and exit.

--version, -v
Print version information and exit.

--license
Print license information and exit.

-wwidth
Set the width which is used by the w dimension specifier. These dimensions are also used (after scaling) to set the clipping path for each page.

-hheight
Set the height which is used by the h dimension specifier. These dimensions are also used (after scaling) to set the clipping path for each page.

-ppaper
An alternative to -w and -h. Set the paper size to a3, a4, a5, b5, letter, legal, tabloid, statement, executive, folio, quarto or 10x14. The default paper size is letter.

-b
Prevent any bind operators in the PostScript prolog from binding. This may be needed in cases where complex multi-page re-arrangements are being done.

-d[linewidth]
Draw a line around the border of each page, of the specified width. If the linewidth parameter is omitted, a default linewidth of 1 point is assumed. The linewidth is relative to the original page dimensions, i.e. it is scaled up or down with the rest of the page.

-q
Pstops-clip normally prints the page numbers of the pages re-arranged; the -q option suppresses this.

EXAMPLES

This section contains some sample re-arrangements. To put two pages on one sheet (of A4 paper), the pagespec to use is:

2:0L@.7(21cm,0)+1L@.7(21cm,14.85cm)


To select all of the odd pages in reverse order, use:

2:-0


To re-arrange pages for printing 2-up booklets, use

4:-3L@.7(21cm,0)+0L@.7(21cm,14.85cm)


for the front sides, and

4:1L@.7(21cm,0)+-2L@.7(21cm,14.85cm)


for the reverse sides (or join them with a comma for duplex printing).

AUTHORS

Copyright (C) Angus J. C. Duggan 1991-1995
Copyright (C) Peter Selinger 2006-2012

SEE ALSO

psdim(1), lprwrap(1)

TRADEMARKS

PostScript is a trademark of Adobe Systems Incorporated.

BUGS

Pstops-clip does not accept all DSC comments.