Difference between revisions of "Pdf"
Jump to navigation
Jump to search
| (One intermediate revision by the same user not shown) | |||
| Line 1: | Line 1: | ||
===Manipulating PDFs=== | ===Manipulating PDFs=== | ||
To shrink a pdf you can use ghostscript. (Instructions from [https://www.adobe.com/acrobat/hub/how-to-compress-pdf-in-linux.html Adobe] for Linux.) | To shrink a pdf you can use ghostscript. (Instructions from [https://www.adobe.com/acrobat/hub/how-to-compress-pdf-in-linux.html Adobe] for Linux.) | ||
| − | gs -sDEVICE=pdfwrite - | + | gs -sDEVICE=pdfwrite -dCompatibilityLevel=1.4 -dPDFSETTINGS=/screen -dNOPAUSE -dQUIET -dBATCH -sOutputFile=output.pdf input.pdf |
The <code>-dPDFSETTINGS=/</code> flag sets the resolution. There are four options | The <code>-dPDFSETTINGS=/</code> flag sets the resolution. There are four options | ||
Latest revision as of 16:50, 27 October 2023
Manipulating PDFs[edit]
To shrink a pdf you can use ghostscript. (Instructions from Adobe for Linux.)
gs -sDEVICE=pdfwrite -dCompatibilityLevel=1.4 -dPDFSETTINGS=/screen -dNOPAUSE -dQUIET -dBATCH -sOutputFile=output.pdf input.pdf
The -dPDFSETTINGS=/ flag sets the resolution. There are four options
- =/screen - lowest quality at 72dpi (this is more than adequate for high quality PDFs)
- =/ebook - better quality at 150dpi
- =/prepress - highest quality at 300dpi
- =/default - system default; may result in inflated file size