A lightweight Qt Widgets desktop app that turns a batch of photos into a single, print-ready PDF — no online converters, no uploading personal photos to a random website.
Drop in your images, reorder and rotate them right on the thumbnail grid, pick a save location, and export. Each page is generated at print resolution from the original full-size image, not from a downscaled preview.
- Native file dialog — select multiple images at once (
.png,.jpg,.jpeg,.jfif). - Drag & drop from the desktop — drop image files straight onto the window.
- Photos are laid out in a scrollable
QGridLayout, each as a self-containedPhotoThumbnailwidget. - Per-photo rotate button, overlaid directly on the thumbnail — rotates in 90° steps, re-rendered from the original file each time to avoid repeated-resample quality loss.
- Per-photo remove button — deletes a single photo and automatically reflows the remaining grid to close the gap.
- Internal drag & drop reordering — drag one thumbnail onto another to swap their positions, implemented via a custom
QMimeDataformat carrying the source widget's identity.
- Powered by
QPdfWriter+QPainter, rendering at 300 DPI on A4 pages. - Each photo is loaded fresh from its original file at export time (not from the on-screen thumbnail), then scaled to fit the page with aspect ratio preserved and centered — no stretching, no cropping.
- Applied rotations are baked into the export automatically.
- Automatic pagination: a new page is started only when the next photo actually needs one, avoiding blank trailing pages.
- Auto-scrolling, distraction-free layout: just a photo grid, a save-path picker, and an export button.
- Custom multi-resolution application icon (window + taskbar + executable).
- Packaged as a standalone Windows installer (Inno Setup) with all Qt runtime dependencies bundled via
windeployqt— runs on machines without Qt installed.
- Language: C++23
- GUI: Qt 6 Widgets (
QMainWindow,QGridLayout,QScrollArea, customQLabelsubclass) - PDF Generation:
QPdfWriter,QPainter - Drag & Drop:
QDrag,QMimeData, custom MIME type for internal reordering - Packaging: Inno Setup,
windeployqt
- C++23 compatible compiler
- Qt 6.11.2 (Qt Widgets module) with Qt VS Tools
git clone https://github.com/usevel/ToPDF.git
cd ToPDFOpen the project in Visual Studio with the Qt VS Tools extension installed, select the Release configuration, and build the ToPdf target.
- Launch the app and add photos — either via "Choose file" or by dragging image files onto the window.
- Rotate or remove individual photos using the buttons overlaid on each thumbnail.
- Drag a thumbnail onto another to swap their order in the final PDF.
- Click "Browse..." to choose where the finished PDF should be saved.
- Click "Convert to PDF" — each photo is placed on its own page, scaled to fit and centered.
Distributed under the MIT License. Feel free to inspect, modify, and use this code for learning and personal projects.