pdf_worker 1.0.6 copy "pdf_worker: ^1.0.6" to clipboard
pdf_worker: ^1.0.6 copied to clipboard

A new Flutter PDF plugin project. you can lock, unlock PDF file.

pdf_worker #

A new Flutter plugin project. you can lock, unlock PDF file.

Getting Started #

usage #

final pdfWorker = PdfWorker();

try {
    // path need the device pdf file path
    final isEncrypted = await pdfWorker.isEncrypted(filePath: 'test.pdf');
    await pdfWorker.lock(filePath: 'test.pdf', password: '123456');
    final locked = await pdfWorker.unlock(filePath: 'test.pdf', password: '123456');

    // replace your file path, or look example
    final outputPath = await pdfWorker.choosePagesIndexToMerge(
      inputPath: 'test.pdf',
      outputPath: 'outpath.pdf',
      pagesIndex: [1, 2],
    );
    final mergedPath = await pdfWorker.mergePdfFiles(
      filesPath: ['test.pdf', 'test1.pdf'],
      outputPath: 'outpath.pdf',
    );


    final longImagePath = await pdfWorker.pdfToLongImage(
      inputPath: 'test.pdf',
      outputPath: 'outpath.jpg',
      pagesIndex: [1, 2],
    );


    final imagesPath = await pdfWorker.pdfToImages(
      inputPath: 'test.pdf',
      outputDirectory: 'outpath',
      config: PdfToImagesConfig(
        pagesIndex: [1, 2],
        imgFormat: ImageFormat.jpg,
        quality: 80,
      ),
    );
} catch (e) {
    debugPrint(e.toString());
}

TODO List #

  • ✅ add merge pdf to long picture
  • ✅ add images to pdf
  • ✅ add pdf to images
0
likes
150
points
9
downloads

Publisher

unverified uploader

Weekly Downloads

A new Flutter PDF plugin project. you can lock, unlock PDF file.

Repository (GitHub)
View/report issues

Documentation

API reference

License

Apache-2.0 (license)

Dependencies

flutter, plugin_platform_interface

More

Packages that depend on pdf_worker

Packages that implement pdf_worker