Skip to main content

A ZipFile like API for PyMuPDF

Project description

PDFFile

A ZipFile like API for PDFs using PyMuPDF as a backend.

Look in pdffile.py for exposed functions.

Dependencies

The pymupdf dependency usually has wheels that install a local version of libmupdf. But for some platforms (e.g. Windows) it may require libstdc++ and c/c++ build tools installed to compile a libmupdf. More detail on this is available in the pymupdf docs.

Data Types

MuPDF reads and writes all data types as strings. PDFFile automatically converts pdf date strings to python datetimes and pdf/xml boolean strings to python bools and back.

The helper functions to_datetime, to_pdf_date, to_bool, and to_xml_bool are available on the PDFFile class.

Installing on Linux on ARM (AARCH64) with Python 3.13

Pymupdf has no pre-built wheels for AARCH64 so pip must build it and the build fails on Python 3.13 without this environment variable set:

PYMUPDF_SETUP_PY_LIMITED_API=0 pip install comicbox-pdffile

You will also have to have the build-essential and python3-dev or equivalent packages installed on on your Linux.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

comicbox_pdffile-0.2.5.tar.gz (18.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

comicbox_pdffile-0.2.5-py3-none-any.whl (5.5 kB view details)

Uploaded Python 3

File details

Details for the file comicbox_pdffile-0.2.5.tar.gz.

File metadata

  • Download URL: comicbox_pdffile-0.2.5.tar.gz
  • Upload date:
  • Size: 18.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.7.6

File hashes

Hashes for comicbox_pdffile-0.2.5.tar.gz
Algorithm Hash digest
SHA256 3b12c473a8ec6b02e2b5092908329231697428ba3c4b8a833df0a4112710006f
MD5 c5aecbce9c05d0da4dd0afea405c9562
BLAKE2b-256 75ac71fd8e18f86c049a1d9b9b44ec56b2452616161e8b0d40dcb408eb1eb76a

See more details on using hashes here.

File details

Details for the file comicbox_pdffile-0.2.5-py3-none-any.whl.

File metadata

File hashes

Hashes for comicbox_pdffile-0.2.5-py3-none-any.whl
Algorithm Hash digest
SHA256 e431bcecd2ba68008b1e14643917f696eae71338b4af1c331180e625c8eda314
MD5 8d2e3b60a0122c2e0b6eea30b907751a
BLAKE2b-256 5348222a3e764eb54c8a438b96b0379397b44300e861d097fd3052d964925c46

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page