Create PDF invoice according to Spanish regulations.
Project description
Create PDF invoice according to Spanish regulations.
Usage
Check tests/tests_functional.py and facturapdf/strategies files.
Generators
To ease the creation of pdf flowables you can use the generators functions.
Element generator
Creates a flowable based on a given string. Check the element function to see the available elements. Arguments are given inside brackets separated by commas.
# Generates a Image flowable with 25 mm of width
generators.element('image[logo.jpg,25]')
# Generates a FrameBreak flowable
generators.element('framebreak')
Chapter generator
Creates a list of flowables passing any number of string arguments.
generators.chapter('Paragraph[Cat in the hat]', 'image[hat.jpg,25]')
# Passing a string that is not a valid flowable keyword or anything that is not a string will do nothing
# So you can mix chapter generator with another one at once
generators.chapter('hello', [1, 2, 3]) # will return ['hello', [1, 2, 3]]
Testing
$ python -m unittest discover tests/
Check for output files at tests/output folder.
License
BSD 3-Clause License. See LICENSE file.
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
Built Distribution
File details
Details for the file facturapdf-0.0.3.tar.gz
.
File metadata
- Download URL: facturapdf-0.0.3.tar.gz
- Upload date:
- Size: 6.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 671a69bf3037d988d6a6a04d0ff91186ca6eb95c55735a37df492745f4518fba |
|
MD5 | a6ed40629ce10fae76e91d08a7cd21f8 |
|
BLAKE2b-256 | ba8de99b626e7de9d5a63b59035c5b72e7635b3466a50add9376ef996f357463 |
Provenance
File details
Details for the file facturapdf-0.0.3-py2.py3-none-any.whl
.
File metadata
- Download URL: facturapdf-0.0.3-py2.py3-none-any.whl
- Upload date:
- Size: 10.1 kB
- Tags: Python 2, Python 3
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | f919699d7c9003bdb605a438952592f41189f60a1987d51297ba7e2a31a7dcc2 |
|
MD5 | 18929025104adf8e144394f8ea5a7d7c |
|
BLAKE2b-256 | a396110abd13182281eb4b7c15c1474b3a662a35996bb3db970dd5a461b7bcdf |