pdftops(1)

๐Ÿ“ฆ
version 26.10.0 ยท 2 versions
  • 26.10.0 ยท alpine 3.22, alpine 3.23, alpine 3.24, arch rolling, centos-stream 10, centos-stream 9, debian bookworm, debian trixie, fedora 43, fedora 44, nixos 26.05, nixpkgs unstable, opensuse-leap 16.0, ubuntu jammy, ubuntu noble, ubuntu questing, ubuntu resolute, ubuntu stonking (latest)
  • 4.06 ยท nixpkgs unstable
, in alpine 3.22, alpine 3.23, alpine 3.24, arch rolling, centos-stream 10, centos-stream 9, debian bookworm, debian trixie, fedora 43, fedora 44, nixos 26.05, nixpkgs unstable, opensuse-leap 16.0, ubuntu jammy, ubuntu noble, ubuntu questing, ubuntu resolute, ubuntu stonking

๐ŸŽ€ pdftops(1) ยท General Commands Manual ๐ŸŽ€

โœจ NAME โœจ

okay so the manual name here is pdftops, and it's a Portable Document Format (PDF) to PostScript converter ๐Ÿ’– this version is 3.03!

๐Ÿงš SYNOPSIS ๐Ÿงš

pdftops [options] <PDF-file> [<PS-file>]

๐Ÿ’… DESCRIPTION ๐Ÿ’…

bestie, pdftops turns PDF files into PostScript so they can actually get printed ๐Ÿ–จ๏ธโœจ

it reads the PDF you give it, PDF-file, and writes a PostScript file called PS-file. if you don't name a PS-file, it converts file.pdf into file.ps (or file.eps if you use the -eps option) ๐ŸŒธ if you pass ยด-' as the PS-file, the PostScript gets sent to stdout instead. and if you pass ยด-' as the PDF-file, it reads the PDF from stdin ๐Ÿซถ

๐Ÿฆ‹ OPTIONS ๐Ÿฆ‹

  • -f number โ€” picks the first page you want to print ๐Ÿ“„
  • -l number โ€” picks the last page you want to print ๐Ÿ“„
  • -level1 โ€” generates Level 1 PostScript. ngl the files come out way bigger if there are images, but they'll print on Level 1 printers ๐Ÿ–จ๏ธ this also turns every image black and white ๐Ÿฉถ you can only use one of the PostScript level options (-level1, -level1sep, -level2, -level2sep, -level3, -level3sep) at a time, no cheating ๐Ÿ™…โ€โ™€๏ธ
  • -level1sep โ€” generates Level 1 separable PostScript. all colors get converted to CMYK, and images get written with separate stream data for each of the four components ๐ŸŒˆ
  • -level2 โ€” generates Level 2 PostScript. this one supports color images and image compression, and it's the default vibe ๐Ÿ‘‘
  • -level2sep โ€” generates Level 2 separable PostScript. all colors become CMYK, and the PostScript separation convention operators handle custom (spot) colors ๐ŸŽจ
  • -level3 โ€” generates Level 3 PostScript. it turns on all the Level 2 features plus CID font embedding ๐Ÿš€
  • -level3sep โ€” generates Level 3 separable PostScript. the separation handling is the same as -level2sep ๐Ÿ’œ
  • -eps โ€” generates an Encapsulated PostScript (EPS) file ๐Ÿฆข an EPS file holds a single image, so if your PDF has multiple pages you have to use -f and -l to pick just one page ๐Ÿ™ˆ you can only use one of the mode options (-eps, -form) at a time
  • -form โ€” generates a PostScript form that software with form support can import ๐Ÿ“‹ a form holds one page, so same deal: with a multi-page PDF you need -f and -l to select a single page. -level1 can't be used with -form ๐Ÿ™…โ€โ™€๏ธ and again, only one mode option (-eps, -form) allowed
  • -opi โ€” generates OPI comments for all images and forms that have OPI info ๐Ÿ–ผ๏ธ heads up, this one is only available if pdftops was compiled with OPI support
  • -binary โ€” writes binary data in Level 1 PostScript. by default pdftops writes hex-encoded data in Level 1, but binary is technically non-standard in Level 1 PostScript. the perk is a smaller file size, and it's handy when you only need Level 1 for its restricted set of PostScript operators ๐Ÿค“
  • -r number โ€” sets the resolution in DPI for when pdftops rasterizes images with transparencies, or (for Level 1 PostScript) images with color masks ๐Ÿ“ by default it rasterizes to 300 DPI โœจ
  • -noembt1 โ€” normally, any embedded Type 1 fonts in the PDF get copied into the PostScript file. this option makes pdftops swap in base fonts instead ๐Ÿ”ค embedded fonts make PostScript files bigger, but they might be needed for readable output
  • -noembtt โ€” normally, any embedded TrueType fonts in the PDF get copied into the PostScript file. this option makes pdftops swap in base fonts instead ๐Ÿ”ค embedded fonts make files bigger, but they might be needed for readable output. also, some PostScript interpreters don't have TrueType rasterizers, so keep that in mind ๐Ÿ™ˆ
  • -noembcidps โ€” normally, any embedded CID PostScript fonts get copied into the PostScript file. this option turns that embedding off ๐Ÿšซ and no attempt is made to substitute for non-embedded CID PostScript fonts
  • -noembcidtt โ€” normally, any embedded CID TrueType fonts get copied into the PostScript file. this option turns that embedding off ๐Ÿšซ and no attempt is made to substitute for non-embedded CID TrueType fonts
  • -passfonts โ€” by default, references to non-embedded 8-bit fonts get swapped for the closest "Helvetica", "Times-Roman", or "Courier" font ๐Ÿ” this option passes those references straight through to the PostScript file instead
  • -aaRaster yes | no โ€” turns raster anti-aliasing on or off. it defaults to "no" ๐Ÿ’… pdftops might need to rasterize transparencies and pattern image masks. if the PostScript is going to get printed, leave -aaRaster off and set -r to your printer's resolution ๐Ÿ–จ๏ธ if it's going to get viewed on screen, turning -aaRaster on can make rasterized text easier to read ๐Ÿ‘€
  • -rasterize always | never | whenneeded โ€” by default pdftops rasterizes pages as needed, like when they contain transparencies ๐Ÿ–ผ๏ธ set it to "always" to force rasterization, which is the way to eliminate fonts ๐Ÿซ  set it to "never" to stop rasterization completely, but heads up, this may produce files that display incorrectly โš ๏ธ
  • -processcolorformat MONO8 | CMYK8 | RGB8 โ€” sets the process color format used during rasterization and transparency reduction ๐ŸŽจ the default depends on your other settings: for -level1 it's MONO8, for -level{1,2,3}sep or -overprint it's CMYK8, and in every other case it's RGB8. if you give -processcolorprofile, then -processcolorformat gets inferred from that ICC profile ๐Ÿง 
  • -processcolorprofile filename โ€” sets the ICC profile that gets assumed during rasterization and transparency reduction ๐ŸŽ€
  • -defaultgrayprofile defaultgrayprofilefile โ€” if poppler was compiled with colour management support, this sets the DefaultGray color space to the ICC profile stored in defaultgrayprofilefile ๐Ÿฉถ
  • -defaultrgbprofile defaultrgbprofilefile โ€” if poppler was compiled with colour management support, this sets the DefaultRGB color space to the ICC profile stored in defaultrgbprofilefile โค๏ธ
  • -defaultcmykprofile defaultcmykprofilefile โ€” if poppler was compiled with colour management support, this sets the DefaultCMYK color space to the ICC profile stored in defaultcmykprofilefile ๐Ÿ’›
  • -optimizecolorspace โ€” by default, bitmap images pass through to the output PostScript in their original color space, which gives predictable results โœจ this option converts RGB and CMYK images into Gray images when every pixel has equal components ๐Ÿช„ it can fix problems when doing color separations on PDFs with embedded black and white images that are encoded as RGB
  • -preload โ€” preloads images and forms ๐Ÿ“ฆ
  • -paper size โ€” sets the paper size to one of "letter", "legal", "A4", or "A3" ๐Ÿ“„ it can also be set to "match", which sets each page's paper size to match the size in the PDF file ๐Ÿชž if none of -paper, -paperw, or -paperh are specified, the default is to match the paper size
  • -paperw size โ€” sets the paper width, in points ๐Ÿ“
  • -paperh size โ€” sets the paper height, in points ๐Ÿ“
  • -origpagesizes โ€” same thing as -paper match ๐Ÿชž
  • -nocrop โ€” by default, the output gets cropped to the CropBox in the PDF file โœ‚๏ธ this option turns cropping off
  • -expand โ€” expands PDF pages that are smaller than the paper so they fill it ๐Ÿช„ by default these pages don't get scaled
  • -noshrink โ€” stops scaling PDF pages that are larger than the paper ๐Ÿ™…โ€โ™€๏ธ by default, pages bigger than the paper get shrunk to fit
  • -nocenter โ€” by default, PDF pages smaller than the paper (after any scaling) get centered on the paper ๐ŸŽฏ this option aligns them to the lower-left corner instead
  • -duplex โ€” sets the Duplex pagedevice entry in the PostScript file, which tells duplex-capable printers to turn duplexing on ๐Ÿ–จ๏ธ๐Ÿ”
  • -opw password โ€” specifies the owner password for the PDF file ๐Ÿ”‘ > providing this bypasses all security restrictions, so use it wisely ๐Ÿšจ
  • -upw password โ€” specifies the user password for the PDF file ๐Ÿ”
  • -overprint โ€” enables overprint emulation during rasterization ๐ŸŒ€ when -processcolorformat is CMYK8 and the language level is higher than 2, this option is set to true by default. note: this option requires -processcolorformat to be CMYK8 ๐ŸŽจ
  • -q โ€” don't print any messages or errors ๐Ÿคซ
  • -v โ€” prints copyright and version information ๐Ÿ“œ
  • -h โ€” prints usage information ๐Ÿงพ (-help and --help are equivalent, iykyk ๐Ÿ™ˆ)

๐Ÿšจ EXIT CODES ๐Ÿšจ

the Xpdf tools use these exit codes, so keep them in your back pocket ๐Ÿซถ

  1. 0 โ€” no error, slay ๐Ÿ‘‘
  2. 1 โ€” error opening a PDF file ๐Ÿฅฒ
  3. 2 โ€” error opening an output file ๐Ÿ˜ญ
  4. 3 โ€” error related to PDF permissions ๐Ÿ”’
  5. 99 โ€” other error ๐Ÿ’€

๐ŸŒˆ AUTHOR ๐ŸŒˆ

the pdftops software and documentation are copyright 1996-2011 Glyph & Cog, LLC. main character creators, honestly ๐Ÿ’œ

๐Ÿ”— SEE ALSO ๐Ÿ”—

bestie, these are the related pages you should check out next ๐Ÿฆ‹ pdfdetach(1), pdffonts(1), pdfimages(1), pdfinfo(1), pdftocairo(1), pdftohtml(1), pdftoppm(1), pdftotext(1), pdfseparate(1), pdfsig(1), pdfunite(1) ๐Ÿงš


ok that's the whole tea ๐Ÿซถ this is the pdftops(1) page from the General Commands Manual, dated 15 August 2011 ๐ŸŒธ stay iconic and keep printing ๐Ÿ’–โœจ

๐Ÿ“ฆ where this page comes from