Skip to main content

A commandline tool to crop a PDF into sub-PDFs

Project description

Usages

Crop all the pages in the PDF

pdf_crop -i <str: input PDF file> [--threshold <float: default 0.008>] [--space <int: default 5>]

e.g.

pdf_crop -i ~/Downloads/test.pdf

or specify the space and threshold:

pdf_crop -i ~/Downloads/test.pdf --threshold 0.01 --space 3

Crop selected pages in the PDF

python ./pdf_crop -i <str: input PDF file> --page <number left top right bottom output> [--page <number left top right bottom output>] [--threshold <float: default 0.008>] [--space <int: default 5>]

e.g.

pdf_crop -i ~/Downloads/test.pdf --page 0 0 0 200 200 "~/Downloads/test - page 0.pdf"

or specify multiple pages:

pdf_crop -i ~/Downloads/test.pdf --page 0 0 0 200 200 "~/Downloads/test - page 0.pdf" --page 1 0 0 200 200 "~/Downloads/test - page 1.pdf"

Upload to PyPi

  1. python3 setup.py sdist bdist_wheel
  2. twine upload -u -p "" dist/*

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

pdf_crop-0.0.21.tar.gz (4.7 kB view details)

Uploaded Source

Built Distribution

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

pdf_crop-0.0.21-py3-none-any.whl (5.9 kB view details)

Uploaded Python 3

File details

Details for the file pdf_crop-0.0.21.tar.gz.

File metadata

  • Download URL: pdf_crop-0.0.21.tar.gz
  • Upload date:
  • Size: 4.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.7.1 importlib_metadata/4.10.1 pkginfo/1.8.2 requests/2.27.1 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.8.5

File hashes

Hashes for pdf_crop-0.0.21.tar.gz
Algorithm Hash digest
SHA256 3573b0e8c3ea1a8c0171cf8f6c40e61b0258323ee47416601e96bae5bebe552e
MD5 f71b5f25f4d12ee51db9413886ef945e
BLAKE2b-256 7914f9c826de5f77f719a881ed1c70447388bcb8a2bfaee3a27ce7a59a6e8fb6

See more details on using hashes here.

File details

Details for the file pdf_crop-0.0.21-py3-none-any.whl.

File metadata

  • Download URL: pdf_crop-0.0.21-py3-none-any.whl
  • Upload date:
  • Size: 5.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.7.1 importlib_metadata/4.10.1 pkginfo/1.8.2 requests/2.27.1 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.8.5

File hashes

Hashes for pdf_crop-0.0.21-py3-none-any.whl
Algorithm Hash digest
SHA256 3de3da25ca9ae2d2caf1f4d5219b12a633d6b4136fe4df19dcd9d421072a2d0c
MD5 8700a5a6fc5d935ba148c3755ae0000f
BLAKE2b-256 1d9571672aa5b6268262b390f526c2a20ddc57346643b8449f51c91204ddbbd8

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