Create, read, and update Microsoft Word .docx files.
Project description
python-docx
python-docx is a Python library for reading, creating, and updating Microsoft Word 2007+ (.docx) files.
This repository exists as a fork of the official repo as I needed features and quality of life improvements.
Key differences at a glance:
- Supporting multiple numbered lists within a document
- Supporting TOC updates within the package without the need to open the document manually
- Supporting floating images within documents
- Supporting the ability to transform word documents into PDF's
Installation
pip install skelmis-docx
Example
>>> from docx import Document
>>> document = Document()
>>> document.add_paragraph("It was a dark and stormy night.")
<docx.text.paragraph.Paragraph object at 0x10f19e760>
>>> document.save("dark-and-stormy.docx")
>>> document = Document("dark-and-stormy.docx")
>>> document.paragraphs[0].text
'It was a dark and stormy night.'
More information is available in the documentation
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
skelmis_docx-1.3.0.tar.gz
(206.4 kB
view details)
Built Distribution
skelmis_docx-1.3.0-py3-none-any.whl
(250.5 kB
view details)
File details
Details for the file skelmis_docx-1.3.0.tar.gz
.
File metadata
- Download URL: skelmis_docx-1.3.0.tar.gz
- Upload date:
- Size: 206.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.8.3 CPython/3.10.12 Linux/6.8.0-40-generic
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | f6467b90aefcf1b914d1310a61af61a4803c9552d9804b9b9ac3339d944e79a7 |
|
MD5 | 97cc9dc291278560a47ab61989acc644 |
|
BLAKE2b-256 | 78bf7c50dd213759c56a195413ccbde74bb366cd04bced8090130fa245bc72d2 |
File details
Details for the file skelmis_docx-1.3.0-py3-none-any.whl
.
File metadata
- Download URL: skelmis_docx-1.3.0-py3-none-any.whl
- Upload date:
- Size: 250.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.8.3 CPython/3.10.12 Linux/6.8.0-40-generic
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 09b2b6e410c5b6b103c48354ed5b57a719f84bbe7f8ba35629fd6cf242a44e55 |
|
MD5 | e5cdfcabfff7b86cdf809d9c104891ab |
|
BLAKE2b-256 | a80bfe2faf35415bd14d050485e2f9eab3c93df891ab3e74be05797cd0a26745 |