# PDF

- Page: https://shared.btbytes.com/p/pdf
- Date: 2024-05-13
- Tags: pdf

[Stering-PDf](https://github.com/Stirling-Tools/Stirling-PDF) - Locally hosted web application that allows you to perform various operations on PDF files. See also [PDFPea - Edit PDFs Online Securely and Free \| Privacy-First PDF Editor](https://pdfpea.com)

[Dangerzone](https://dangerzone.rocks/) -  Convert potentially dangerous documents into safe PDFs

[ExifTool by Phil Harvey](https://www.exiftool.org/) -**Read**, **Write** and **Edit** Meta Information!

[QPDF](https://qpdf.sourceforge.io/) -  A Content-Preserving PDF Transformation System

Some of these above were found [via](https://social.coop/@jonny/107685726645817029)


----

small script to cleanup pdfs in general (reducing their size as well), [via](https://news.ycombinator.com/item?id=40631901).

```bash
pdftops -paper A4 -expand -level3 file.pdf
ps2pdf14 -dEmbedAllFonts=true          \
    -dUseFlateCompression=true           \
    -dOptimize=true                      \
    -dProcessColorModel=/DeviceRGB       \
    -r72                                 \
    -dDownsampleGrayImages=true          \
    -dGrayImageResolution=150            \
    -dAutoFilterGrayImages=false         \
    -dGrayImageDownsampleType=/Bicubic   \
    -dDownsampleMonoImages=true          \
    -dMonoImageResolution=150            \
    -dMonoImageDownsampleType=/Subsample \
    -dDownsampleColorImages=true         \
    -dColorImageResolution=150           \
    -dAutoFilterColorImages=false        \
    -dColorImageDownsampleType=/Bicubic  \
    -dPDFSETTINGS=/ebook                 \
    -dNOSAFER                            \
    -dALLOWPSTRANSPARENCY                \
    -dShowAnnots=false                   \
     file.pdf file.pdf
```
