Epspdf and epspdftk A multiplatform GUI- and command-line converter for [e]ps and pdf. Siep Kroonenberg, siepo at cybercomm dot nl [1]Current online version of this page Table of Contents * [2]Features * [3]Prerequisites * [4]Installation * [5]Preview programs * [6]Files * [7]Releases * [8]User Guide Features * Distiller * Works both for documents and for graphics * Single-page selection * Also converts from pdf back to PostScript and eps * Removal of preview headers from eps files * Cropping extra whitespace * Grayscaling (sometimes) * GUI- and command-line version * GUI-configurable preferences * Multiplatform: works unchanged on Windows, Unix/Linux and Mac OS X * Support for TeX Live 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. Prerequisites These are the required and optional prerequisites: * Ghostscript * pdftops from the xpdf suite, strongly recommended for better pdf to PostScript conversions * Ruby 1.8.x * Tcl/Tk is only required for the GUI interface. Only version 8.4 has been tested. * Optional: viewers for PostScript and pdf You may not have to install all of these yourself. Linux 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. Mac OS X (Tiger and later) 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 [9]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. Windows (Windows 2000 and later) If you use the TeXLive package (2008 or later): Epspdf and epspdftk will use Ghostscript and pdftops built into TeX Live. You still need to download and install Ruby and optionally Tcl/Tk. If you install from the setup program: This package includes a subset of Ruby/Tk, but you have to provide Ghostscript and pdftops yourself. If you use the zipfile: In this case, you have to provide everything yourself. URLs for the prerequisites Ghostscript and GSview ([10]http://pages.cs.wisc.edu/~ghost/) Contains sources and Windows binaries. The Windows binaries come with standard GUI Windows setup programs. XPDF ([11]http://www.foolabs.com/xpdf/) Sources and Windows binaries. The Windows binaries are packaged into a zipfile, which has to be manually unpacked. The Configure screen of epspdftk lets you browse for the chosen location. You have to do this only once. XPDF, Mac OS X binaries ([12]http://users.phg-online.de/tk/MOSXS/) These are universal binaries. TeX Live ([13]http://www.tug.org/texlive/) TeX Live 2008 includes epspdf as an optional install. For Windows, this version doesn't require external copies of pdftops or Ghostscript. MacTeX ([14]http://www.tug.org/mactex/) MacTeX is based on TeX Live. Its set of add-ons includes Ghostscript, and can be downloaded separately. The MacPorts Project ([15]http://www.macports.org/) MacTeX has Poppler- and xpdf packages either of which include pdftops. Ruby one-click installer fro Windows ( [16]http://rubyforge.org/projects/rubyinstaller/) Current versions (1.8.4 and later) require Tcl/Tk to be separately installed. Old releases of Ruby one-click installer ( [17]http://rubyforge.org/frs/?group_id=167) Versions prior to 1.8.4 include Tcl/Tk. Ruby source code ([18]http://www.ruby-lang.org/en/downloads/) For those people who prefer to roll their own... ActiveTcl from ActiveState ( [19]http://activestate.com/Products/ActiveTcl/ Get version 8.4, not 8.5. Installation First make sure that the prerequisites are met. Then: TeX Live 2008 Use TeX Live's package manager tlmgr for installation. Windows setup program Download the [20]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. Windows zipfile Download the [21]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 "" "" %1 %2 %3 %4 %5 %6 %7 %8 %9 Epspdf[tk] has been tested with Windows 2000 and Windows XP. Unix/Linux Download the [22]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 /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. Mac OS X 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 [23]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. Preview programs Windows Epspdftk will use the default Windows viewers for PostScript and pdf. If you have TeX Live 2008 or later then you can assign \bin\win32\psv.bat as previewer for .ps- and .eps files. Unix/Linux 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 [24]"The configuration screen".. Mac OS X Epspdftk will always use Preview as viewer under OS X. Files * [25]epspdf.0.3.0.tgz preferred for Unix and Mac OS X * [26]epspdf.0.3.0.zip preferred for Windows * [27]epspdf.0.3.0.exe Windows setup program, including Ruby/Tk subset * [28]epspdf_app.0.2.01.zip Mac OS X applet for starting epspdftk.rb Older releases * [29]epspdf.0.2.12.tgz for Unix and Mac OS X * [30]epspdf.0.2.12.zip for Windows * [31]epspdf.0.2.12.exe Windows setup program * [32]epspdf.0.2.11.tgz for Unix and Mac OS X * [33]epspdf.0.2.11.zip for Windows * [34]epspdf.0.2.11.exe Windows setup program * [35]epspdf.0.2.01.tgz for Unix and Mac OS X * [36]epspdf.0.2.01.zip for Windows * [37]epspdf.0.2.exe, Windows setup program Releases 0.3.0 Current version. Under Windows, now recognizes whether it is embedded in TeX Live 2008 and then uses ghostscript/pdftops from TeX Live. Also added TeX Live wrapper scripts. Uninstaller for Windows setup program. Bug fixes: now accepts non-numerical version strings for pdftops. No longer checks for viewers under Mac OS X. 0.2.12 Bug fixes: log rotation now works. Under Windows, sometimes boundingboxes couldn't be calculated. This was caused by double quotes within backquotes. This is now avoided by using short filenames within backquotes. Minor changes in user guide. 0.2.11 Minor fixes. Changes in documentation. 0.2.10 A computed boundingbox is now expanded by one point in all directions. This should prevent too-tight cropping. There is no interface for changing this amount; it can only be changed by hand-editing the bb_spread option in the .epspdfrc file or in the HKCU\software\epspdf registry key. The File Open dialog remembers the last directory visited (between calls, not between program sessions). Changes in documentation. 0.2.01 Fixes to the Applescript applet epspdf.app for starting up epspdftk under Mac OS X. It picks up the terminal search path and no longer requires correct settings in $HOME/.MacOSX/environment.plist. Epspdf.app is now packaged separately, under Mac OS X, and now has an intact resource fork. It has been removed from the other archives. 0.2 Original release -------------------------------------------------------------------------- Last revised: July 27, 2008 References Visible links 1. http://tex.aanhet.net/epspdf/ 2. http://tex.aanhet.net/epspdf/index.html#features 3. http://tex.aanhet.net/epspdf/index.html#prerequisites 4. http://tex.aanhet.net/epspdf/index.html#install 5. http://tex.aanhet.net/epspdf/index.html#preview 6. http://tex.aanhet.net/epspdf/index.html#files 7. http://tex.aanhet.net/epspdf/index.html#releases 8. http://tex.aanhet.net/epspdf/epspdf_UG.html 9. http://users.phg-online.de/tk/MOSXS/ 10. http://pages.cs.wisc.edu/~ghost/ 11. http://www.foolabs.com/xpdf/ 12. http://users.phg-online.de/tk/MOSXS/ 13. http://www.tug.org/texlive/ 14. http://www.tug.org/mactex/ 15. http://www.macports.org/ 16. http://rubyforge.org/projects/rubyinstaller/ 17. http://rubyforge.org/frs/?group_id=167 18. http://www.ruby-lang.org/en/downloads/ 19. http://activestate.com/Products/ActiveTcl/ 20. http://tex.aanhet.net/epspdf/epspdf.0.3.0.exe 21. http://tex.aanhet.net/epspdf/epspdf.0.3.0.zip 22. http://tex.aanhet.net/epspdf/epspdf.0.3.0.tgz 23. http://tex.aanhet.net/epspdf/epspdf_app.0.2.01.zip 24. http://tex.aanhet.net/epspdf/epspdf_UG.html#configure 25. http://tex.aanhet.net/epspdf/epspdf.0.3.0.tgz 26. http://tex.aanhet.net/epspdf/epspdf.0.3.0.zip 27. http://tex.aanhet.net/epspdf/epspdf.0.3.0.exe 28. http://tex.aanhet.net/epspdf/epspdf_app.0.2.01.zip 29. http://tex.aanhet.net/epspdf/epspdf.0.2.12.tgz 30. http://tex.aanhet.net/epspdf/epspdf.0.2.12.zip 31. http://tex.aanhet.net/epspdf/epspdf.0.2.12.exe 32. http://tex.aanhet.net/epspdf/epspdf.0.2.11.tgz 33. http://tex.aanhet.net/epspdf/epspdf.0.2.11.zip 34. http://tex.aanhet.net/epspdf/epspdf.0.2.11.exe 35. http://tex.aanhet.net/epspdf/epspdf.0.2.01.tgz 36. http://tex.aanhet.net/epspdf/epspdf.0.2.01.zip 37. http://tex.aanhet.net/epspdf/epspdf.0.2.exe