Skip to main content

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
    

Test

  • Current python version:

    python3 -m unittest
    
  • All supported python versions (using tox):

    tox
    

Documentation

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

cd doc && make html

Metadata

Release files for papersize 1.8.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for papersize 1.8.0
File Size Uploaded Provenance Actions
papersize-1.8.0.tar.gz 78.1 kB Without provenance Details for papersize-1.8.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for papersize 1.8.0
File Interpreter ABI Platform Actions
papersize-1.8.0-py3-none-any.whl Python 3 none any Details for papersize-1.8.0-py3-none-any.whl

Total release size: 106.4 kB

Release files / papersize-1.8.0.tar.gz

Download URL papersize-1.8.0.tar.gz
Size 78.1 kB
Tags Source
SHA-256 checksum
How to use checksums
a615e3e6ec6a4f2e749fa998861542c48a6f17f88a85b53211d4b24877e3c4ef
BLAKE2b-256 checksum
How to use checksums
8bd86643a0cdfc19dffc8678e4d5ac2743575c3eaa75d402c41622bba094eab3
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.14.8

Release files / papersize-1.8.0-py3-none-any.whl

Download URL papersize-1.8.0-py3-none-any.whl
Size 28.3 kB
Tags Python 3
SHA-256 checksum
How to use checksums
3479cd234296457b5379022c135d4c5011b6d801ba6bd3a992556b5f9461694b
BLAKE2b-256 checksum
How to use checksums
81e417932883cbbe8408a23c008d8a1a950c063762ba2a4ead4df0ac494a274d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.14.8

Security for papersize 1.8.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page