Graphics Programs Reference
In-Depth Information
CHAPTER 9
Working with Pdftk
Pdftk is a multiplatform command-line tool built on the iText library (which is described
in “iText for Java and C#” on page 116 ). It has facilities for merging, splitting, and
stamping documents, and for setting and reading metadata.
Obtaining Pdftk
Pdftk is an open source program, licensed under the GPL. Binary packages for Microsoft
Windows and Mac OS X, and source code for all platforms can be found at PDF Labs .
The creator of pdftk , Sid Steward, is also the author of O'Reilly's PDF Hacks —a col-
lection of tools and tips for working with PDF.
Command Line Syntax
Pdftk has a somewhat unusual command-line interface, where elements often have to
appear in a particular order. We can split them into four groups, in the order they are
specified:
1. The input file or files, and possible input passwords.
2. The operation and any arguments it requires.
3. The output and any output passwords and permissions.
4. Sundry output and other options.
The full details can be found in the manual for pdftk —in this chapter, we give only the
subset needed for our examples.
 
Search WWH ::




Custom Search