A multiplatform GUI- and command-line converter for [e]ps and pdf.
Siep Kroonenberg,
siepo at cybercomm
dot nl
Current online version of this page
Epspdf has been created with TeX users in mind. For them, eps and pdf are the preferred graphics formats.
Ghostscript can convert PostScript to pdf. However, few people are prepared to deal with the ghostscript command-line. Several command-line utilities try to help out, e.g. epstopdf, a2ping, and the convert utility from ImageMagick. But for most users this is still not good enough.
Epspdftk adds a GUI, with buttons to select options and with dialogs for opening and saving files.
A lot more can be done if you can round-trip between PostScript and pdf. Although Ghostscript can go from pdf to PostScript, pdftops does a much better job. This opens several new possibilities: grayscaling and computing a better boundingbox for either eps- or pdf graphics, and page selection from multipage PostScript- and pdf documents. Epspdf will use pdftops if it can find it, and silently does whatever back-and-forth conversions are necessary.
The command-line program epspdf is written in Ruby. Epspdftk, its GUI companion, in Ruby/Tk.
Starting with the 2008 edition, epspdf is included in TeX Live as an optional package, complete with wrapper scripts epspdf and epspdftk which can be called from the command-line without further ado.
These are the required and optional prerequisites:
You may not have to install all of these yourself.
On a current Linux distribution you can almost certainly install everything from your distribution's package repositories. You may have to install Ruby's Tk bindings, in addition to Ruby and Tcl/Tk themselves. The name of such a package might be e.g. libtcltk-ruby. As to PostScript- and pdf viewers: epspdf tests for several popular viewers, but the configuration screen also lets you specify viewers manually.
Ruby and Tcl/Tk are already part of the operating system. Ghostscript is included in MacTeX, but is also available via e.g. MacPorts. You can get pdftops from MacPorts as part of either Poppler or xpdf. Another source is http://users.phg-online.de/tk/MOSXS/.
If you want to compile xpdf it yourself, which is not hard, you can ignore warnings about X, Motif or FreeType not being found since these missing libraries won't affect the compilation of pdftops.
First make sure that the prerequisites are met. Then:
Use TeX Live's package manager tlmgr for installation.
Download the epspdftk setup program. You can run it in the usual way, by double-clicking. The setup program will create entries in your start menu for epspdftk and for the user manual.
Download the epspdf zip file, unpack it somewhere and create a shortcut for epspdftk.rbw. If you plan to use the command-line version, put a batchfile in a directory on your path with the line
"<path_to_ruby.exe>" "<path_to_epspdf.rb>" %1 %2 %3 %4 %5 %6 %7 %8 %9
Epspdf[tk] has been tested with Windows 2000 and Windows XP.
Download the tar.gz archive and unpack it in some directory. All files should be in the same directory; that is how they find each other. If you plan to use epspdf.rb from the command-line, then create a shell script epspdf such as
#!/bin/sh <path_to_epspdf>/epspdf.rb $*
and put it somewhere on your path.
You can do the same for epspdftk. The first command-line parameter will be interpreted as startup directory for the file browser.
Install as for Unix/Linux. Here, too, all files should be in the same directory.
You can try to start epspdftk.rb from the dock or by doubleclicking. If that doesn't work out, give the epspdf.app applet a try. After unpacking, move the file epspdf.app to the same directory as the .rb files. The zipfile also includes this file in text format (epspdf.applescript).
Epspdf mostly duplicates functionality of Preview. But having an alternate conversion engine means that you can have another shot at problem files.
Epspdftk will use the default Windows viewers for PostScript and pdf. If you have TeX Live 2008 or later then you can assign <TeX Live root>\bin\win32\psv.bat as previewer for .ps- and .eps files.
Supported PostScript viewers include evince, gv, ggv and kghostview. These are also listed as pdf viewers. Additional pdf viewers are xpdf, gpdf and acroread/Adobe Reader. You can also specify a previewer manually in the configuration screen; see the user guide, under "The configuration screen"..
Epspdftk will always use Preview as viewer under OS X.
Last revised: July 27, 2008