Skip to main content

Paper size related tools

Project description

papersize 📏 Paper size related tools

This module provides tools to manipulate paper sizes, that is:

  • a dictionary of several named standard names (e.g. A4, letter) , with their respective sizes (width and height);
  • functions to convert sizes from one unit (e.g. inches) to another (e.g. centimeters);
  • functions to manipulate paper orientation (portrait or landscape);
  • tools to parse paper sizes, so that you do not have to worry about the format of paper sizes provided by your user, it being "a4" or "21cm x 29.7cm".

What's new?

See changelog.

Install

See the end of list for a (quick and dirty) Debian package.

  • From sources:

  • From pip:

    pip install papersize
    
  • Quick and dirty Debian (and Ubuntu?) package

    This requires stdeb to be installed:

      python3 setup.py --command-packages=stdeb.command bdist_deb
      sudo dpkg -i deb_dist/python-papersize-<VERSION>_all.deb
    

Test

  • Current python version:

    python3 setup.py test
    
  • All supported python versions (using tox):

    tox
    

Documentation

The documentation is available on readthedocs. You can build it using:

cd doc && make html

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

papersize-1.5.0.tar.gz (35.5 kB view details)

Uploaded Source

Built Distribution

papersize-1.5.0-py3-none-any.whl (28.0 kB view details)

Uploaded Python 3

File details

Details for the file papersize-1.5.0.tar.gz.

File metadata

  • Download URL: papersize-1.5.0.tar.gz
  • Upload date:
  • Size: 35.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.11.8

File hashes

Hashes for papersize-1.5.0.tar.gz
Algorithm Hash digest
SHA256 1155c71fe88ddaa4c1b2bfa86cae1a5ef9904c8707445813b9b87d67e85dcdcb
MD5 5c9c1885b5b93999a95e773aadfa014f
BLAKE2b-256 be9948e0130b10d78af99524277c48a45d63e470fe28ea7579c125bbe374cde4

See more details on using hashes here.

File details

Details for the file papersize-1.5.0-py3-none-any.whl.

File metadata

  • Download URL: papersize-1.5.0-py3-none-any.whl
  • Upload date:
  • Size: 28.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.11.8

File hashes

Hashes for papersize-1.5.0-py3-none-any.whl
Algorithm Hash digest
SHA256 61315fbb2f6acc2d71b111952ed73ceeb1139312913b5c9c753bb8637a40a4d2
MD5 fe75089aff120144084324119e0c53f1
BLAKE2b-256 d4265b417317a4b4622c52e873f6e8bceaed62ee36cef55fc754cd24b077fcd9

See more details on using hashes here.

Supported by

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