pdf_combiner
6.3.0, released 13 days ago by victorcarreras.dev
Merge multiple PDF documents and images into a single file or extract images from PDFs.
What it does
Allows developers to combine various PDF documents and images from local paths, raw bytes, or remote URLs into a single PDF file. It also supports extracting images from existing PDF documents with customizable scaling and compression settings.
AI-written summary of version 6.3.0, based on the package's README and metadata. Report an inaccuracy
Use it when
- You need to merge multiple PDF files or images into a single PDF document.
- You need to extract images from a PDF file on supported platforms.
- You work with mixed input sources such as local paths, bytes, and remote URLs.
Skip it when
- You need advanced PDF editing capabilities like form filling, digital signatures, or text annotations.
- You are targeting platforms not supported by the plugin.
Strengths
- Supports multiple input source types including paths, bytes, and URLs via sealed classes.
- Cross-platform support covering Android, iOS, Linux, macOS, Windows, and web.
- Provides configuration for image compression and scaling when creating or extracting images.
Weaknesses
- Web platform requires proper CORS configuration on remote servers when using remote URLs.
- Specific setup such as installing `libheif-dev` is required to use HEIF images on Linux.
Setup
- Kind
- Plugin (native code)
- Effort
- Low
- Code generation
- No
- Direct dependencies
- 4
No additional setup required for directly supported platforms besides handling file permissions or installing `libheif-dev` on Linux if using HEIF images.
final inputs = [
MergeInput.path("path/to/local_file1.pdf"),
MergeInput.path("path/to/local_file2.pdf"),
];
try {
String response = await PdfCombiner.mergeMultiplePDFs(
inputs: inputs,
outputPath: "path/to/output.pdf",
);
} catch (e) {
print("Error: $e");
}Alternatives
Packages that do the same job and could replace pdf_combiner.
- file_picker
Use the native file explorer to pick single or multiple files, directories, and save files.
93Compare - pasteboard
Read and write images, files, and text to the system clipboard across platforms.
92Compare - pdfrx_engine
Pure Dart PDF rendering and manipulation API built on top of PDFium.
90Compare - syncfusion_flutter_pdfviewer
Flutter PDF Viewer library to display PDF documents seamlessly and efficiently.
86Compare
Works with
Packages commonly used together with pdf_combiner: ones it builds on, ones built on it, and its own family.
- webpdf_combiner depends on itLightweight bindings for browser APIs via JS interop
- plugin_platform_interfacepdf_combiner depends on itReusable base class for platform interfaces of Flutter federated plugins.
- file_magic_numberpdf_combiner depends on itDetect file types based on content headers and magic numbers across platforms.