Skip to content

SmartSolarium/JpegtoPDF

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

JpegtoPDF (Price List Impaginator)

JpegtoPDF ("Price List Impaginator") is a local web application designed to automate the conversion of JPEG spreads (double pages) into print-ready PDFs (single A4 pages).

It is particularly suitable for laying out price lists, catalogs, or magazines starting from scans or double-page exports, automatically handling cutting, bleed, and PDF optimization.

✨ Key Features

  • Automatic Spread Splitting: Takes a two-page image (spread) and automatically splits it into two single A4 pages.
  • Bleed Management: Option to generate pages with 3mm bleed on all sides.
    • Smart Logic: For the binding side (spine), the software "steals" 3mm from the adjacent page of the spread to ensure graphical continuity.
  • Manual Adjustments:
    • Zoom: Scale the image if necessary.
    • Offset: Shift the cut point left or right to center asymmetrical content.
  • PDF Compression: Slider to adjust PDF quality and reduce final file size.
  • Color Support: Preserves the original color profile (e.g., CMYK) to ensure print fidelity.
  • Intuitive Interface: Drag & drop files, real-time preview, and manual page reordering.

🚀 Installation and Usage

Prerequisites

  • Python 3.8 or higher installed.

Setup (First Run)

  1. Clone or download this repository.
  2. Run the automatic startup script (Windows):
    run_app.bat
    The script will automatically create a virtual environment (venv), install the necessary dependencies, and start the application.

Manual Startup

If you prefer to do everything manually:

  1. Create an environment: python -m venv venv
  2. Activate it: venv\Scripts\activate
  3. Install packages: pip install -r requirements.txt
  4. Start the server: python backend/main.py
  5. Open browser at: http://localhost:8000

📖 How to Use

  1. Upload: Drag & drop your JPEG images (spreads) into the upload area.
  2. Adjust:
    • Use the Zoom and Offset sliders if the image is not perfectly centered.
    • Check Bleed (3mm) if you need to send the file to a print shop. Click Update Preview to see the effect.
  3. Sort: Drag pages in the preview area to change the order if needed (e.g., cover at the beginning).
  4. Generate: Adjust quality (default 100%) and click Generate PDF. The file will be downloaded automatically.

🛠 Technologies

  • Backend: Python, FastAPI
  • Image Processing: Pillow (PIL), img2pdf
  • Frontend: HTML5, CSS3, Vanilla JS

About

A tool to convert a bunch of JPEGs to PDF with compression

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors