Create customizable PowerPoint Presentation (.pptx) using a predefined layout template
Project description
python-pptx-templater is a tool to create highly customizable PowerPoint presentation using the jinja template languages. User specifies the layouts and placeholders and the template will render the presentation.
Example
Input
Using Template JSON:
{
'slides': [
{
'layoutSlideNum': 0,
'text': {
'name': 'Paul'
}
},
{
'layoutSlideNum': 0,
'text': {
'name': 'Joe'
}
},
{
'layoutSlideNum': 1,
'text': {
'dog': {
'name': 'John Cena'
}
}
},
]
}
Output
Install
pip install python-pptx-templater
Usage
from pptx_templater.core import convert
def test_conversion():
currpwd = os.path.dirname(os.path.abspath(__file__))
srcpath = f'{currpwd}/fixtures/test_presentation_layout.pptx'
destpath = f'{currpwd}/test_outputs/updated.pptx'
j = {
'slides': [
{
'layoutSlideNum': 0,
'text': {
'name': 'Paul'
}
},
{
'layoutSlideNum': 0,
'text': {
'name': 'Joe'
}
},
{
'layoutSlideNum': 1,
'text': {
'dog': {
'name': 'John Cena'
}
}
},
]
}
convert(srcpath, destpath, j)
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
Close
Hashes for python-pptx-templater-1.1.13.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 754c954deb20a9f0f7cb217d7524234495ec892b73982e123b7b90ed673b9092 |
|
MD5 | f65dbb91c37e199b1f1489111567aa3e |
|
BLAKE2b-256 | e9276775fe80ec3a4a682fe12f4dff44d1935fe39901c7efd3169ce1487c4677 |
Close
Hashes for python_pptx_templater-1.1.13-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 7e39809669b449e94635e30503ddc0bf663071217d504958e11a613f38bccd89 |
|
MD5 | 1d786c5e5fbc2ba0e79f12cbedd8b022 |
|
BLAKE2b-256 | 0890b21c112dfaa9532eef65e0bf2c816851b3d5b29349483b86b7983c4aa572 |