Expand description
§PDF Converter
A simple library for converting JPG and other image formats to PDF documents.
§Features
- Convert single images to PDF
- Batch convert multiple images from a folder to a single PDF
- Support for JPG, PNG, GIF, BMP, WebP formats
- Automatic A4 page fitting with proper scaling
- Configurable margins and page settings
§Example
use pdf_converter::PdfConverter;
let converter = PdfConverter::new();
converter.convert_folder_to_pdf("images/", "output.pdf")?;Re-exports§
pub use converter::PdfConverter;pub use converter::PdfConfig;pub use error::PdfError;pub use error::Result;
Modules§
Constants§
- A4_
HEIGHT_ MM - Default A4 page height in millimeters
- A4_
WIDTH_ MM - Default A4 page width in millimeters
- DEFAULT_
DPI - Default DPI for image conversion
- DEFAULT_
MARGIN_ MM - Default page margin in millimeters