Stamptk creates PDF pages from your page range options that are input
on the command line, by one or more text files (via
include=), or both.
More than one page range can be described using the options, and these
separate page ranges can have overlapping or even identical page numbers.
< page range handle > is a sequence of upper-case letters (A-Z[A-Z]...) that identify the page range for which the given < option key > and < option value > apply. Options that use the same handle are combined to make one page range. Multiple page ranges can be described by using a different handle for each page range. Page ranges can have overlapping page numbers (see the range option).
< option key > is one of:
< option value > is a value that suits the given option key, as follows:
text=< text string >
This is the text you want displayed on the page. It is restricted to the CP-1252 character set. You can set only one of these per page range, but you can add multiple text strings to a page by using multiple page ranges. It is encoded in CP-1252, optionally using escaped octal (\000) or hexadecimal (\xHH) for non-ASCII characters. Backslashes must be escaped using a backslash (\).
textUTF8=< text string >
This is the text you want displayed on the page. It is restricted to the CP-1252 character set. You can set only one of these per page range, but you can add multiple text strings to a page by using multiple page ranges. It is encoded in UTF-8.
pos=< X >,< Y >
This option sets the text’s position on the page. X or Y can
either be an absolute coordinate on the page or one of the relative arguments. Absolute coordinates are in points (72
points per inch), and the page origin is in the lower-left page corner.
The relative arguments are relative to the page. X relative
right, and Y relative arguments
origin=< X >,< Y >
This sets the text’s origin to use when positioning the text on
the page with pos. X can be:
right, and Y can
bottom. These describe the location of the
text’s origin using the text’s borders. Default:
size=< font size >
This sets the text’s size in points (72 points/inch). Default: 14
color=< red >,< green >,< blue > | #< RRGGBB >
This sets the text’s color. You have two formatting options: decimal or hex. When using decimal formatting, red, green and blue are decimal values between 0 and 255. When using hex formatting, RR, GG and BB are hexadecimal values between 00 and FF. Default: #000000 (black)
font=< standard font name >
This is the font used to display the text. It can be one of:
sans- standard font Helvetica
sansBold- standard font Helvetica-Bold
sansItalic- standard font Helvetica-Oblique
sansBoldItalic- standard font Helvetica-BoldOblique
serif- standard font Times
serifBold- standard font Times-Bold
serifItalic- standard font Times-Italic
serifBoldItalic- standard font Times-BoldItalic
mono- standard font Courier
monoBold- standard font Courier-Bold
monoItalic- standard font Courier-Oblique
monoBoldItalic- standard font Courier-BoldOblique
If you add a page stream (described below) that uses one of
PDF’s standard fonts, then set this font option to match for the
relevant page(s). That will ensure that the required font
resources are packed into the PDF page. If no text or stream is
given for any page range, then no font resources are added to
the PDF. Default:
angle=N | NE | E | SE | S | SW | W | NW
This sets the text’s angle. It uses compass points to divide
the circle into 45-degree pieces. For example the
N angle gives
you right-reading text and the
E angle rotates the text 90
degrees clockwise so it reads from top to bottom. Text is
rotated on its origin, described above. Default:
This allows you to add your own PDF page description code to the
pages in the range. The given keywords delimit the PDF code
that will be added to the PDF page verbatim. There is a newline
after the first keyword and another newline before the last keyword.
This can be used in combination with the
and related options. When using only the
stream option, the
only other options to consider are the
font options — the other options relate only to adding text to
the pages. You can apply multiple streams to a single page by
using multiple page ranges.
embed=< PDF string >
This takes an arbitrary string and invisibly embeds it into each
page’s PDF dictionary using the dictionary key
This is useful if you have data you want to pass to a PDF parser
downstream. Parentheses and backslashes must be escaped with a
backslash. Only one can be set per page. If more than one
range sets this option, only the final setting will be used —
values are not appended the way page text and page streams are.
Maximum length: 64k bytes.
media=< standard page name >[Landscape] | < page width >,< page height >
This sets the page dimensions. For standard page name use one
B5, and you can append
Landscape to change its orientation. Or, you can give the page width and
page height in points (there are 72 points per inch). Default:
margin=< page margin >
is used in conjunction with relative pos values (
right) to tell stamptk how much space to keep between your
text origin and the edge of the page. It is an integer value
and its units are points (there are 72 points per inch).
range=< first page number >[-< final page number >[Even | Odd]]
where the page numbers give one or more pages to be used for
this page range. Page numbers are 1-based, so the first page is
numbered 1, not zero. On page ranges, you can append
Odd to effect just those pages. Default: 1