A user-friendly GUI tool for compressing PDF files effortlessly.
ReducedPDF is a Python-based application that simplifies PDF compression using Ghostscript. It’s designed for users who prefer a graphical interface over ghostscript command-line tools, making it easy to reduce PDF file sizes without technical hassle. Ideal for anyone seeking a simple, no-fuss solution.
- Intuitive GUI: No command-line knowledge required—just point, click, and compress.
- Efficient Compression: Leverages Ghostscript for reliable, high-quality results with multiple compression levels (screen, ebook, printer, prepress).
- Cross-Platform Compatibility: Works seamlessly on Linux, macOS, and Windows.
- Automatic File Naming: Generates unique output file names to avoid overwriting originals.
- Size Reduction Feedback: Displays original and compressed sizes, along with the percentage reduction, after compression.
- Error Handling: User-friendly messages for missing files or dependencies.
ReducedPDF requires the following dependencies, which may need to be installed depending on your system:
- Python 3.x: Download and install from python.org if not already present. Ensure Tkinter (Python's GUI library) is included (usually bundled with standard Python installations, but may require additional setup on Linux).
- Ghostscript: Required for PDF compression. Download from ghostscript.com for Windows, or install via your package manager on Linux (e.g.,
apt
,dnf
,pacman
) or macOS (e.g.,brew
). Ensure thegs
command is in your system PATH. - Tkinter (Linux-specific): On Linux, you may need to install Tkinter separately using your package manager (e.g.,
python3-tk
on Debian/Ubuntu,python3-tkinter
on Fedora, ortk
on Arch Linux).
Verify installations:
- Python:
python3 --version
orpython --version
- Ghostscript:
gs --version
- Tkinter:
python -c "import tkinter; print('Tkinter is installed')"
-
Clone the Repository:
git clone https://github.com/PixelTux/reducedPDF-python.git
-
Navigate to the Project Folder:
cd reducedPDF-python
-
Run the Application:
python reducedPDF.py # Or python3 on some systems
- Launch the application using the command above.
- Click "Browse" to select a PDF file.
- Choose a compression level:
- Screen: Lowest quality, smallest file size (optimized for web viewing).
- Ebook: Balanced quality for e-readers.
- Printer: Good for printing.
- Prepress: Highest quality, larger files.
- Click "Compress". The compressed file will be saved in the same folder as the original, with a name like
<my_file_name>_ebook_comp.pdf
(appended with the compression level and a number if duplicates exist). - A success message will show the original size, compressed size, reduction percentage, and save location.
- Ghostscript Not Found: Ensure
gs --version
works in your terminal/command prompt. If not, reinstall Ghostscript and verify it’s in your system PATH. - Tkinter Import Error: Confirm Tkinter is installed. On Linux, install the relevant package (e.g.,
python3-tk
orpython3-tkinter
). On Windows/macOS, reinstall Python from python.org with Tkinter support enabled. - Compression Fails: Check if the PDF is corrupted or password-protected (ReducedPDF doesn't support encrypted files).
- For other issues, open a GitHub issue with details about your OS and error message.
Contributions are welcome! Feel free to:
- Open an issue for bugs, features, or suggestions.
- Submit a pull request with improvements (e.g., new features, bug fixes, or better cross-platform support).
Please follow standard Python coding conventions and test on your platform.
This project is licensed under the GNU General Public License v3.0. See the LICENSE file for details.