Description
py2pdf has one simple purpose: It takes a string with python source code and creates a nice looking pdf file. The library is simple and self-contained. All pdf generation is done by py2pdf itself. No font files are needed.
Quick example
>>> import py2pdf
>>> text = open('py2pdf.py').read()
>>> f = open('tmp.pdf', 'wb')
>>> py2pdf.create_pdf(
... text, f,
... title='py2pdf',
... pagesize=py2pdf.A4,
... printed_by='Printed by ME',
... file_date='2020-08-01')
>>> py2pdf.startfile('tmp.pdf')
Release files for py2pdf 0.1.3
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| py2pdf-0.1.3.tar.gz | 6.5 kB | Details |
Release files / py2pdf-0.1.3.tar.gz
| Download URL | py2pdf-0.1.3.tar.gz |
|---|---|
| Size | 6.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
7d7f1aafb3ec0fce00559a28550367af21ddbe4c2e5f80cf2d192f65196ea587
|
|
BLAKE2b-256 checksum How to use checksums |
8beef58749dd0f102f0021f8f5b3bd20367d7cd8001d75202ceedab62fb113c4
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.10.0 pkginfo/1.2.1 requests/2.18.4 setuptools/39.0.1 requests-toolbelt/0.8.0 tqdm/4.19.5 CPython/3.6.8
|