python-docx-oss 0.2.0__tar.gz → 0.3.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/HISTORY.md +8 -0
- {python_docx_oss-0.2.0/src/python_docx_oss.egg-info → python_docx_oss-0.3.0}/PKG-INFO +4 -3
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/README.md +2 -1
- python_docx_oss-0.3.0/docs/api/sanitize.rst +60 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/index.rst +5 -1
- python_docx_oss-0.3.0/docs/user/sanitization.rst +56 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/pyproject.toml +2 -2
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/__init__.py +1 -1
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/document.py +22 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/opc/coreprops.py +35 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/opc/part.py +8 -0
- python_docx_oss-0.3.0/src/docx/sanitize/__init__.py +10 -0
- python_docx_oss-0.3.0/src/docx/sanitize/cleaner.py +221 -0
- python_docx_oss-0.3.0/src/docx/sanitize/result.py +38 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0/src/python_docx_oss.egg-info}/PKG-INFO +4 -3
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/python_docx_oss.egg-info/SOURCES.txt +7 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/python_docx_oss.egg-info/requires.txt +1 -1
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/fixtures/README.md +2 -0
- python_docx_oss-0.3.0/tests/fixtures/comments/word-comments-rich.docx +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/opc/test_coreprops.py +16 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/opc/test_part.py +11 -0
- python_docx_oss-0.3.0/tests/test_sanitize.py +197 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/LICENSE +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/MANIFEST.in +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/Makefile +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/_static/.gitignore +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/_static/img/comment-parts.png +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/_static/img/example-docx-01.png +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/_static/img/hdrftr-01.png +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/_static/img/hdrftr-02.png +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/_static/img/oss.png +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/_templates/layout.html +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/_templates/sidebarlinks.html +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/_themes/armstrong/LICENSE +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/_themes/armstrong/layout.html +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/_themes/armstrong/rtd-themes.conf +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/_themes/armstrong/static/rtd.css_t +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/_themes/armstrong/theme.conf +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/_themes/armstrong/theme.conf.orig +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/api/comments.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/api/dml.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/api/document.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/api/enum/MsoColorType.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/api/enum/MsoThemeColorIndex.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/api/enum/WdAlignParagraph.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/api/enum/WdBuiltinStyle.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/api/enum/WdCellVerticalAlignment.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/api/enum/WdColorIndex.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/api/enum/WdLineSpacing.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/api/enum/WdOrientation.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/api/enum/WdRowAlignment.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/api/enum/WdRowHeightRule.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/api/enum/WdSectionStart.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/api/enum/WdStyleType.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/api/enum/WdTabAlignment.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/api/enum/WdTabLeader.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/api/enum/WdTableDirection.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/api/enum/WdUnderline.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/api/enum/index.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/api/section.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/api/settings.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/api/shape.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/api/shared.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/api/style.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/api/table.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/api/text.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/conf.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/dev/analysis/features/comments.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/dev/analysis/features/coreprops.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/dev/analysis/features/header.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/dev/analysis/features/numbering.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/dev/analysis/features/sections.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/dev/analysis/features/settings.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/dev/analysis/features/shapes/index.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/dev/analysis/features/shapes/picture.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/dev/analysis/features/shapes/shapes-inline-size.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/dev/analysis/features/shapes/shapes-inline.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/dev/analysis/features/styles/character-style.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/dev/analysis/features/styles/index.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/dev/analysis/features/styles/latent-styles.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/dev/analysis/features/styles/paragraph-style.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/dev/analysis/features/styles/style.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/dev/analysis/features/styles/styles.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/dev/analysis/features/table/cell-merge.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/dev/analysis/features/table/index.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/dev/analysis/features/table/table-cell.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/dev/analysis/features/table/table-props.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/dev/analysis/features/table/table-row.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/dev/analysis/features/text/breaks.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/dev/analysis/features/text/font-color.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/dev/analysis/features/text/font-highlight-color.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/dev/analysis/features/text/font.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/dev/analysis/features/text/hyperlink.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/dev/analysis/features/text/index.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/dev/analysis/features/text/paragraph-format.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/dev/analysis/features/text/run-content.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/dev/analysis/features/text/tab-stops.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/dev/analysis/features/text/underline.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/dev/analysis/index.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/dev/analysis/schema/ct_body.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/dev/analysis/schema/ct_document.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/dev/analysis/schema/ct_p.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/dev/upstream-maintenance.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/requirements.txt +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/user/api-concepts.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/user/comments.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/user/compatibility.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/user/custom-properties.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/user/custom-xml.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/user/documents.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/user/hdrftr.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/user/install.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/user/quickstart.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/user/sections.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/user/shapes.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/user/styles-understanding.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/user/styles-using.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/user/tables.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/docs/user/text.rst +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/api-open-document.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/blk-add-paragraph.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/blk-add-table.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/blk-iter-inner-content.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/cmt-mutations.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/cmt-props.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/doc-access-collections.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/doc-access-sections.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/doc-add-comment.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/doc-add-heading.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/doc-add-page-break.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/doc-add-paragraph.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/doc-add-picture.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/doc-add-section.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/doc-add-table.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/doc-comments.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/doc-coreprops.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/doc-customprops.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/doc-settings.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/doc-styles.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/environment.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/hdr-header-footer.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/hlk-props.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/img-characterize-image.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/num-access-numbering-part.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/par-access-inner-content.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/par-access-parfmt.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/par-add-run.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/par-alignment-prop.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/par-clear-paragraph.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/par-insert-paragraph.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/par-set-text.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/par-style-prop.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/pbk-split-para.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/run-access-font.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/run-access-inner-content.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/run-add-content.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/run-add-picture.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/run-char-style.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/run-clear-run.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/run-enum-props.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/sct-section.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/shp-inline-shape-access.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/shp-inline-shape-size.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/api.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/block.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/comments.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/coreprops.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/customprops.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/document.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/font.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/hdrftr.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/helpers.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/hyperlink.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/image.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/numbering.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/pagebreak.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/paragraph.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/parfmt.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/section.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/settings.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/shape.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/shared.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/styles.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/table.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/tabstops.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/test_files/blk-containing-table.docx +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/test_files/blk-paras-and-tables.docx +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/test_files/comments-rich-para.docx +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/test_files/court-exif.jpg +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/test_files/doc-access-sections.docx +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/test_files/doc-add-section.docx +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/test_files/doc-coreprops.docx +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/test_files/doc-customprops-legacy.docx +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/test_files/doc-customprops.docx +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/test_files/doc-default.docx +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/test_files/doc-no-coreprops.docx +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/test_files/doc-no-customprops.docx +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/test_files/doc-odd-even-hdrs.docx +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/test_files/doc-word-default-blank.docx +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/test_files/fnt-color.docx +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/test_files/hdr-header-footer.docx +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/test_files/jfif-300-dpi.jpg +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/test_files/jpeg420exif.jpg +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/test_files/lena.bmp +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/test_files/lena.gif +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/test_files/lena.tif +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/test_files/lena_std.jpg +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/test_files/monty-truth.png +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/test_files/mountain.bmp +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/test_files/num-having-numbering-part.docx +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/test_files/par-alignment.docx +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/test_files/par-hlink-frags.docx +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/test_files/par-hyperlinks.docx +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/test_files/par-known-paragraphs.docx +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/test_files/par-known-styles.docx +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/test_files/par-rendered-page-breaks.docx +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/test_files/python-icon.jpeg +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/test_files/run-char-style.docx +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/test_files/run-enumerated-props.docx +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/test_files/sample.tif +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/test_files/sct-first-page-hdrftr.docx +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/test_files/sct-inner-content.docx +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/test_files/sct-section-props.docx +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/test_files/set-no-settings-part.docx +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/test_files/shp-inline-shape-access.docx +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/test_files/sty-behav-props.docx +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/test_files/sty-having-no-styles-part.docx +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/test_files/sty-having-styles-part.docx +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/test_files/sty-known-styles.docx +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/test_files/tab-stops.docx +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/test_files/tbl-2x2-table.docx +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/test_files/tbl-cell-access.docx +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/test_files/tbl-cell-props.docx +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/test_files/tbl-col-props.docx +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/test_files/tbl-having-applied-style.docx +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/test_files/tbl-having-tables.docx +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/test_files/tbl-on-off-props.docx +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/test_files/tbl-props.docx +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/test_files/test.png +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/test_files/txt-font-highlight-color.docx +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/test_files/txt-font-props.docx +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/steps/text.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/sty-access-font.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/sty-access-latent-styles.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/sty-access-parfmt.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/sty-add-style.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/sty-delete-style.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/sty-latent-add-del.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/sty-latent-props.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/sty-style-props.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/tab-access-tabs.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/tab-tabstop-props.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/tbl-add-row-or-col.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/tbl-cell-access.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/tbl-cell-add-table.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/tbl-cell-props.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/tbl-cell-text.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/tbl-col-props.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/tbl-item-access.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/tbl-merge-cells.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/tbl-props.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/tbl-row-props.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/tbl-style.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/txt-add-break.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/txt-font-color.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/txt-font-props.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/features/txt-parfmt-props.feature +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/requirements-dev.txt +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/requirements-docs.txt +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/requirements-test.txt +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/requirements.txt +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/setup.cfg +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/api.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/blkcntnr.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/comments.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/dml/__init__.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/dml/color.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/drawing/__init__.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/enum/__init__.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/enum/base.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/enum/dml.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/enum/section.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/enum/shape.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/enum/style.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/enum/table.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/enum/text.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/exceptions.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/image/__init__.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/image/bmp.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/image/constants.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/image/emf.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/image/exceptions.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/image/gif.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/image/helpers.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/image/image.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/image/jpeg.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/image/png.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/image/svg.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/image/tiff.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/opc/__init__.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/opc/constants.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/opc/customprops.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/opc/exceptions.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/opc/oxml.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/opc/package.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/opc/packuri.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/opc/parts/__init__.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/opc/parts/coreprops.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/opc/parts/customprops.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/opc/phys_pkg.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/opc/pkgreader.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/opc/pkgwriter.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/opc/rel.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/opc/shared.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/opc/spec.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/oxml/__init__.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/oxml/comments.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/oxml/coreprops.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/oxml/customprops.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/oxml/dml/CT_ExtensionList.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/oxml/document.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/oxml/drawing.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/oxml/exceptions.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/oxml/ns.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/oxml/numbering.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/oxml/parser.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/oxml/section.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/oxml/settings.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/oxml/shape.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/oxml/shared.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/oxml/simpletypes.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/oxml/styles.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/oxml/table.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/oxml/text/__init__.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/oxml/text/font.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/oxml/text/hyperlink.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/oxml/text/pagebreak.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/oxml/text/paragraph.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/oxml/text/parfmt.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/oxml/text/run.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/oxml/xmlchemy.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/package.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/parts/__init__.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/parts/comments.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/parts/customxml.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/parts/document.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/parts/hdrftr.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/parts/image.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/parts/numbering.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/parts/settings.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/parts/story.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/parts/styles.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/py.typed +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/section.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/settings.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/shape.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/shared.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/styles/__init__.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/styles/latent.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/styles/style.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/styles/styles.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/table.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/templates/default-comments.xml +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/templates/default-docx-template/[Content_Types].xml +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/templates/default-docx-template/_rels/.rels +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/templates/default-docx-template/customXml/_rels/item1.xml.rels +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/templates/default-docx-template/customXml/item1.xml +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/templates/default-docx-template/customXml/itemProps1.xml +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/templates/default-docx-template/docProps/app.xml +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/templates/default-docx-template/docProps/core.xml +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/templates/default-docx-template/docProps/thumbnail.jpeg +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/templates/default-docx-template/word/_rels/document.xml.rels +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/templates/default-docx-template/word/document.xml +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/templates/default-docx-template/word/fontTable.xml +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/templates/default-docx-template/word/numbering.xml +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/templates/default-docx-template/word/settings.xml +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/templates/default-docx-template/word/styles.xml +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/templates/default-docx-template/word/stylesWithEffects.xml +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/templates/default-docx-template/word/theme/theme1.xml +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/templates/default-docx-template/word/webSettings.xml +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/templates/default-footer.xml +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/templates/default-header.xml +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/templates/default-numbering.xml +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/templates/default-settings.xml +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/templates/default-styles.xml +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/templates/default.docx +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/text/__init__.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/text/font.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/text/hyperlink.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/text/pagebreak.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/text/paragraph.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/text/parfmt.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/text/run.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/text/tabstops.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/docx/types.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/python_docx_oss.egg-info/dependency_links.txt +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/src/python_docx_oss.egg-info/top_level.txt +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/__init__.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/conftest.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/dml/__init__.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/dml/test_color.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/fixtures/customxml/generate_fixture.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/fixtures/customxml/multiple-custom-xml-parts.docx +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/fixtures/documents/word-blank.docx +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/fixtures/drawing/word-floating-picture.docx +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/fixtures/fonts/word-east-asian-fonts.docx +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/fixtures/images/word-svg-image.docx +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/image/__init__.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/image/test_bmp.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/image/test_emf.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/image/test_gif.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/image/test_helpers.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/image/test_image.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/image/test_jpeg.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/image/test_png.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/image/test_svg.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/image/test_tiff.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/integration/__init__.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/integration/customxml/__init__.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/integration/customxml/test_custom_xml_roundtrip.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/integration/test_word_roundtrip.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/opc/__init__.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/opc/parts/__init__.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/opc/parts/test_coreprops.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/opc/parts/test_customprops.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/opc/test_customprops.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/opc/test_oxml.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/opc/test_package.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/opc/test_packuri.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/opc/test_phys_pkg.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/opc/test_pkgreader.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/opc/test_pkgwriter.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/opc/test_rel.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/opc/unitdata/__init__.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/opc/unitdata/rels.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/opc/unitdata/types.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/oxml/__init__.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/oxml/parts/__init__.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/oxml/parts/test_document.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/oxml/parts/unitdata/__init__.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/oxml/parts/unitdata/document.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/oxml/test__init__.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/oxml/test_comments.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/oxml/test_document.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/oxml/test_ns.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/oxml/test_section.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/oxml/test_styles.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/oxml/test_table.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/oxml/test_xmlchemy.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/oxml/text/__init__.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/oxml/text/test_hyperlink.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/oxml/text/test_run.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/oxml/unitdata/__init__.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/oxml/unitdata/dml.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/oxml/unitdata/numbering.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/oxml/unitdata/section.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/oxml/unitdata/shared.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/oxml/unitdata/styles.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/oxml/unitdata/table.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/oxml/unitdata/text.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/parts/__init__.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/parts/test_comments.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/parts/test_customxml.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/parts/test_document.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/parts/test_hdrftr.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/parts/test_image.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/parts/test_numbering.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/parts/test_settings.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/parts/test_story.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/parts/test_styles.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/styles/__init__.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/styles/test_latent.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/styles/test_style.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/styles/test_styles.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/test_api.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/test_blkcntnr.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/test_comments.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/test_document.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/test_drawing.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/test_enum.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/test_files/150-dpi.png +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/test_files/300-dpi.TIF +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/test_files/300-dpi.jpg +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/test_files/300-dpi.png +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/test_files/72-dpi.tiff +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/test_files/CVS_LOGO.WMF +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/test_files/blk-inner-content.docx +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/test_files/exif-420-dpi.jpg +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/test_files/expanded_docx/[Content_Types].xml +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/test_files/expanded_docx/_rels/.rels +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/test_files/expanded_docx/customXml/_rels/item1.xml.rels +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/test_files/expanded_docx/customXml/item1.xml +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/test_files/expanded_docx/customXml/itemProps1.xml +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/test_files/expanded_docx/docProps/app.xml +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/test_files/expanded_docx/docProps/core.xml +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/test_files/expanded_docx/docProps/thumbnail.jpeg +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/test_files/expanded_docx/word/_rels/document.xml.rels +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/test_files/expanded_docx/word/document.xml +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/test_files/expanded_docx/word/fontTable.xml +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/test_files/expanded_docx/word/numbering.xml +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/test_files/expanded_docx/word/settings.xml +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/test_files/expanded_docx/word/styles.xml +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/test_files/expanded_docx/word/stylesWithEffects.xml +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/test_files/expanded_docx/word/theme/theme1.xml +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/test_files/expanded_docx/word/webSettings.xml +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/test_files/having-images.docx +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/test_files/jfif-iguana.jpg +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/test_files/jpeg_without_app0_and_app1.jpg +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/test_files/little-endian.tif +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/test_files/monty-truth.png +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/test_files/python-icon.jpeg +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/test_files/python-icon.png +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/test_files/python-powered.png +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/test_files/python.bmp +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/test_files/sct-inner-content.docx +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/test_files/snippets/add-row-col.txt +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/test_files/snippets/inline.txt +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/test_files/snippets/new-tbl.txt +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/test_files/snippets/tbl-cells.txt +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/test_files/sonic.emf +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/test_files/sonic.gif +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/test_files/test.docx +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/test_package.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/test_section.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/test_settings.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/test_shape.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/test_shared.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/test_table.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/text/__init__.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/text/test_font.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/text/test_hyperlink.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/text/test_pagebreak.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/text/test_paragraph.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/text/test_parfmt.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/text/test_run.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/text/test_tabstops.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/unitdata.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/unitutil/__init__.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/unitutil/cxml.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/unitutil/file.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tests/unitutil/mock.py +0 -0
- {python_docx_oss-0.2.0 → python_docx_oss-0.3.0}/tox.ini +0 -0
|
@@ -1,5 +1,13 @@
|
|
|
1
1
|
## Release History
|
|
2
2
|
|
|
3
|
+
**Unreleased**
|
|
4
|
+
|
|
5
|
+
**0.3.0 (2026-08-29)**
|
|
6
|
+
|
|
7
|
+
- Added opt-in package-level document sanitization for personal metadata,
|
|
8
|
+
comments, web extensions, and formatting revision history.
|
|
9
|
+
- Added structured sanitization reports and real Word comment round-trip coverage.
|
|
10
|
+
|
|
3
11
|
**0.2.0 (2026-08-24)**
|
|
4
12
|
|
|
5
13
|
- Added direct loading from raw DOCX bytes with ``Document(bytes)``.
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: python-docx-oss
|
|
3
|
-
Version: 0.
|
|
3
|
+
Version: 0.3.0
|
|
4
4
|
Summary: Create, read, and update Microsoft Word .docx files.
|
|
5
5
|
Author: Ethan St Lee
|
|
6
6
|
License-Expression: MIT
|
|
@@ -23,7 +23,7 @@ Classifier: Topic :: Software Development :: Libraries
|
|
|
23
23
|
Requires-Python: >=3.12
|
|
24
24
|
Description-Content-Type: text/markdown
|
|
25
25
|
License-File: LICENSE
|
|
26
|
-
Requires-Dist: lxml>=
|
|
26
|
+
Requires-Dist: lxml>=6.1.0
|
|
27
27
|
Requires-Dist: typing_extensions>=4.9.0
|
|
28
28
|
Dynamic: license-file
|
|
29
29
|
|
|
@@ -65,7 +65,8 @@ or low-level package and relationship access.
|
|
|
65
65
|
| Latin and East Asian font controls | Stable | `run.font.name`, `run.font.hAnsi`, `run.font.eastAsia` |
|
|
66
66
|
| Low-level OPC parts and relationships | Stable | `document.part.package`, `part.rels` |
|
|
67
67
|
| In-memory read, export, and independent copies | Stable | `Document()`, `to_bytes()`, `copy()` |
|
|
68
|
-
|
|
|
68
|
+
| Document sanitization | Development | `document.sanitize()` |
|
|
69
|
+
| Package inspection and diff | Planned | — |
|
|
69
70
|
|
|
70
71
|
## Installation
|
|
71
72
|
|
|
@@ -36,7 +36,8 @@ or low-level package and relationship access.
|
|
|
36
36
|
| Latin and East Asian font controls | Stable | `run.font.name`, `run.font.hAnsi`, `run.font.eastAsia` |
|
|
37
37
|
| Low-level OPC parts and relationships | Stable | `document.part.package`, `part.rels` |
|
|
38
38
|
| In-memory read, export, and independent copies | Stable | `Document()`, `to_bytes()`, `copy()` |
|
|
39
|
-
|
|
|
39
|
+
| Document sanitization | Development | `document.sanitize()` |
|
|
40
|
+
| Package inspection and diff | Planned | — |
|
|
40
41
|
|
|
41
42
|
## Installation
|
|
42
43
|
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
.. _sanitize_api:
|
|
2
|
+
|
|
3
|
+
Sanitization objects
|
|
4
|
+
====================
|
|
5
|
+
|
|
6
|
+
.. currentmodule:: docx.sanitize
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
SanitizationReport objects
|
|
10
|
+
--------------------------
|
|
11
|
+
|
|
12
|
+
.. autoclass:: SanitizationReport
|
|
13
|
+
:members: changed
|
|
14
|
+
|
|
15
|
+
.. attribute:: scrubbed_properties
|
|
16
|
+
|
|
17
|
+
Names of core properties normalized during sanitization.
|
|
18
|
+
|
|
19
|
+
.. attribute:: removed_comment_markers
|
|
20
|
+
|
|
21
|
+
Number of outermost comment marker elements removed from Word story XML.
|
|
22
|
+
|
|
23
|
+
.. attribute:: removed_formatting_revisions
|
|
24
|
+
|
|
25
|
+
Number of outermost formatting revision elements removed.
|
|
26
|
+
|
|
27
|
+
.. attribute:: removed_parts
|
|
28
|
+
|
|
29
|
+
Package part names made unreachable by removed relationships.
|
|
30
|
+
|
|
31
|
+
.. attribute:: removed_relationships
|
|
32
|
+
|
|
33
|
+
:class:`RemovedRelationship` records for relationships removed from the
|
|
34
|
+
package graph.
|
|
35
|
+
|
|
36
|
+
.. attribute:: warnings
|
|
37
|
+
|
|
38
|
+
Non-fatal conditions encountered while sanitizing the package.
|
|
39
|
+
|
|
40
|
+
|
|
41
|
+
RemovedRelationship objects
|
|
42
|
+
---------------------------
|
|
43
|
+
|
|
44
|
+
.. autoclass:: RemovedRelationship
|
|
45
|
+
|
|
46
|
+
.. attribute:: source
|
|
47
|
+
|
|
48
|
+
Part name of the relationship source, or ``/`` for the package itself.
|
|
49
|
+
|
|
50
|
+
.. attribute:: relationship_id
|
|
51
|
+
|
|
52
|
+
Relationship identifier used by the source.
|
|
53
|
+
|
|
54
|
+
.. attribute:: relationship_type
|
|
55
|
+
|
|
56
|
+
Full relationship type URI.
|
|
57
|
+
|
|
58
|
+
.. attribute:: target
|
|
59
|
+
|
|
60
|
+
Target part name or external target reference.
|
|
@@ -22,7 +22,9 @@ supports capabilities needed by more demanding document workflows:
|
|
|
22
22
|
* SVG and EMF vector images;
|
|
23
23
|
* separate Latin and East Asian font settings;
|
|
24
24
|
* document custom properties; and
|
|
25
|
-
* multiple Custom XML parts that survive a load/save round trip
|
|
25
|
+
* multiple Custom XML parts that survive a load/save round trip; and
|
|
26
|
+
* explicit package-level sanitization of metadata, comments, web extensions,
|
|
27
|
+
and formatting revision history.
|
|
26
28
|
|
|
27
29
|
Here is a small example:
|
|
28
30
|
|
|
@@ -94,6 +96,7 @@ User Guide
|
|
|
94
96
|
user/styles-understanding
|
|
95
97
|
user/styles-using
|
|
96
98
|
user/comments
|
|
99
|
+
user/sanitization
|
|
97
100
|
user/shapes
|
|
98
101
|
user/custom-properties
|
|
99
102
|
user/custom-xml
|
|
@@ -113,6 +116,7 @@ API Documentation
|
|
|
113
116
|
api/table
|
|
114
117
|
api/section
|
|
115
118
|
api/comments
|
|
119
|
+
api/sanitize
|
|
116
120
|
api/shape
|
|
117
121
|
api/dml
|
|
118
122
|
api/shared
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
.. _sanitization:
|
|
2
|
+
|
|
3
|
+
Document sanitization
|
|
4
|
+
=====================
|
|
5
|
+
|
|
6
|
+
Sanitization removes selected package-level information before a document is
|
|
7
|
+
shared. Every operation is disabled by default because removal is destructive.
|
|
8
|
+
|
|
9
|
+
Use :meth:`Document.sanitize() <docx.document.Document.sanitize>` with explicit
|
|
10
|
+
options and inspect its report before saving::
|
|
11
|
+
|
|
12
|
+
from docx import Document
|
|
13
|
+
|
|
14
|
+
document = Document("input.docx")
|
|
15
|
+
report = document.sanitize(
|
|
16
|
+
personal_metadata=True,
|
|
17
|
+
comments=True,
|
|
18
|
+
web_extensions=True,
|
|
19
|
+
formatting_revisions=True,
|
|
20
|
+
)
|
|
21
|
+
|
|
22
|
+
if report.changed:
|
|
23
|
+
document.save("sanitized.docx")
|
|
24
|
+
|
|
25
|
+
The returned :class:`~docx.sanitize.SanitizationReport` identifies scrubbed
|
|
26
|
+
properties, removed XML markers, parts, and relationships, plus any warnings.
|
|
27
|
+
Each removed relationship is represented by
|
|
28
|
+
:class:`~docx.sanitize.RemovedRelationship`. Repeating the same sanitization is
|
|
29
|
+
idempotent: the second report has ``changed == False`` when nothing new was
|
|
30
|
+
added.
|
|
31
|
+
|
|
32
|
+
Options
|
|
33
|
+
-------
|
|
34
|
+
|
|
35
|
+
``personal_metadata``
|
|
36
|
+
Clears author and last-modified-by values and canonicalizes the revision
|
|
37
|
+
number. Duplicate property elements are removed.
|
|
38
|
+
|
|
39
|
+
``comments``
|
|
40
|
+
Removes comment markers from all reachable Word XML story parts and removes
|
|
41
|
+
the complete comments relationship tree, including modern comments extension
|
|
42
|
+
parts when present.
|
|
43
|
+
|
|
44
|
+
``web_extensions``
|
|
45
|
+
Removes web-extension task panes and their related package parts.
|
|
46
|
+
|
|
47
|
+
``formatting_revisions``
|
|
48
|
+
Removes property-change history such as ``rPrChange`` and ``pPrChange`` while
|
|
49
|
+
retaining the currently effective formatting.
|
|
50
|
+
|
|
51
|
+
Scope boundary
|
|
52
|
+
--------------
|
|
53
|
+
|
|
54
|
+
This API does not accept or reject tracked content revisions. It also does not
|
|
55
|
+
remove Custom XML, macros, OLE objects, external links, or application-specific
|
|
56
|
+
business metadata. Those operations require separate policy decisions.
|
|
@@ -18,7 +18,7 @@ classifiers = [
|
|
|
18
18
|
"Topic :: Office/Business :: Office Suites",
|
|
19
19
|
"Topic :: Software Development :: Libraries",
|
|
20
20
|
]
|
|
21
|
-
dependencies = ["lxml>=
|
|
21
|
+
dependencies = ["lxml>=6.1.0", "typing_extensions>=4.9.0"]
|
|
22
22
|
description = "Create, read, and update Microsoft Word .docx files."
|
|
23
23
|
dynamic = ["version"]
|
|
24
24
|
keywords = ["docx", "office", "openxml", "word"]
|
|
@@ -41,7 +41,7 @@ dev = [
|
|
|
41
41
|
"behave>=1.2.6",
|
|
42
42
|
"pyparsing>=3.2.3",
|
|
43
43
|
"pyright>=1.1.401",
|
|
44
|
-
"pytest>=
|
|
44
|
+
"pytest>=9.0.3",
|
|
45
45
|
"ruff>=0.11.13",
|
|
46
46
|
"sphinx-book-theme",
|
|
47
47
|
"tox>=4.26.0",
|
|
@@ -12,6 +12,7 @@ from docx.api import Document as open_document
|
|
|
12
12
|
from docx.blkcntnr import BlockItemContainer
|
|
13
13
|
from docx.enum.section import WD_SECTION
|
|
14
14
|
from docx.enum.text import WD_BREAK
|
|
15
|
+
from docx.sanitize import SanitizationReport, sanitize_document
|
|
15
16
|
from docx.section import Section, Sections
|
|
16
17
|
from docx.shared import ElementProxy, Emu, Inches, Length
|
|
17
18
|
from docx.text.run import Run
|
|
@@ -229,6 +230,27 @@ class Document(ElementProxy):
|
|
|
229
230
|
"""
|
|
230
231
|
self._part.save(path_or_stream)
|
|
231
232
|
|
|
233
|
+
def sanitize(
|
|
234
|
+
self,
|
|
235
|
+
*,
|
|
236
|
+
personal_metadata: bool = False,
|
|
237
|
+
comments: bool = False,
|
|
238
|
+
web_extensions: bool = False,
|
|
239
|
+
formatting_revisions: bool = False,
|
|
240
|
+
) -> SanitizationReport:
|
|
241
|
+
"""Apply the explicitly selected package-level cleanup operations.
|
|
242
|
+
|
|
243
|
+
Every option defaults to |False| because sanitization is destructive. The
|
|
244
|
+
returned report describes all package and XML changes made to this document.
|
|
245
|
+
"""
|
|
246
|
+
return sanitize_document(
|
|
247
|
+
self,
|
|
248
|
+
personal_metadata=personal_metadata,
|
|
249
|
+
comments=comments,
|
|
250
|
+
web_extensions=web_extensions,
|
|
251
|
+
formatting_revisions=formatting_revisions,
|
|
252
|
+
)
|
|
253
|
+
|
|
232
254
|
@property
|
|
233
255
|
def sections(self) -> Sections:
|
|
234
256
|
"""|Sections| object providing access to each section in this document."""
|
|
@@ -9,6 +9,7 @@ import datetime as dt
|
|
|
9
9
|
from typing import TYPE_CHECKING
|
|
10
10
|
|
|
11
11
|
from docx.oxml.coreprops import CT_CoreProperties
|
|
12
|
+
from docx.oxml.ns import qn
|
|
12
13
|
|
|
13
14
|
if TYPE_CHECKING:
|
|
14
15
|
from docx.oxml.coreprops import CT_CoreProperties
|
|
@@ -21,6 +22,40 @@ class CoreProperties:
|
|
|
21
22
|
def __init__(self, element: CT_CoreProperties):
|
|
22
23
|
self._element = element
|
|
23
24
|
|
|
25
|
+
def deduplicate(self, *property_names: str) -> set[str]:
|
|
26
|
+
"""Remove duplicate XML elements for the named core properties.
|
|
27
|
+
|
|
28
|
+
The first occurrence is retained so callers can subsequently normalize its
|
|
29
|
+
value through the regular property setter.
|
|
30
|
+
"""
|
|
31
|
+
element_tags = {
|
|
32
|
+
"author": qn("dc:creator"),
|
|
33
|
+
"category": qn("cp:category"),
|
|
34
|
+
"comments": qn("dc:description"),
|
|
35
|
+
"content_status": qn("cp:contentStatus"),
|
|
36
|
+
"created": qn("dcterms:created"),
|
|
37
|
+
"identifier": qn("dc:identifier"),
|
|
38
|
+
"keywords": qn("cp:keywords"),
|
|
39
|
+
"language": qn("dc:language"),
|
|
40
|
+
"last_modified_by": qn("cp:lastModifiedBy"),
|
|
41
|
+
"last_printed": qn("cp:lastPrinted"),
|
|
42
|
+
"modified": qn("dcterms:modified"),
|
|
43
|
+
"revision": qn("cp:revision"),
|
|
44
|
+
"subject": qn("dc:subject"),
|
|
45
|
+
"title": qn("dc:title"),
|
|
46
|
+
"version": qn("cp:version"),
|
|
47
|
+
}
|
|
48
|
+
changed: set[str] = set()
|
|
49
|
+
for property_name in property_names:
|
|
50
|
+
try:
|
|
51
|
+
tag = element_tags[property_name]
|
|
52
|
+
except KeyError as exc:
|
|
53
|
+
raise ValueError(f"Unsupported core property: {property_name}") from exc
|
|
54
|
+
for duplicate in self._element.findall(tag)[1:]:
|
|
55
|
+
self._element.remove(duplicate)
|
|
56
|
+
changed.add(property_name)
|
|
57
|
+
return changed
|
|
58
|
+
|
|
24
59
|
@property
|
|
25
60
|
def author(self):
|
|
26
61
|
return self._element.author_text
|
|
@@ -144,6 +144,10 @@ class Part:
|
|
|
144
144
|
rel = self.rels.get_or_add(reltype, cast(Part, target))
|
|
145
145
|
return rel.rId
|
|
146
146
|
|
|
147
|
+
def replace_blob(self, blob: bytes) -> None:
|
|
148
|
+
"""Replace the serialized payload of this non-XML part."""
|
|
149
|
+
self._blob = blob
|
|
150
|
+
|
|
147
151
|
@property
|
|
148
152
|
def related_parts(self):
|
|
149
153
|
"""Dictionary mapping related parts by rId, so child objects can resolve
|
|
@@ -235,6 +239,10 @@ class XmlPart(Part):
|
|
|
235
239
|
"""The root XML element of this XML part."""
|
|
236
240
|
return self._element
|
|
237
241
|
|
|
242
|
+
def replace_blob(self, blob: bytes) -> None:
|
|
243
|
+
"""Reject raw replacement because this part serializes from ``element``."""
|
|
244
|
+
raise TypeError("cannot replace the blob of an XmlPart; replace its element instead")
|
|
245
|
+
|
|
238
246
|
@element.setter
|
|
239
247
|
def element(self, e: BaseOxmlElement):
|
|
240
248
|
self._element = e
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
"""Package-level DOCX sanitization.
|
|
2
|
+
|
|
3
|
+
Callers use :meth:`docx.document.Document.sanitize`; this package keeps OPC graph
|
|
4
|
+
mutation and XML cleanup details behind that single method.
|
|
5
|
+
"""
|
|
6
|
+
|
|
7
|
+
from docx.sanitize.cleaner import sanitize_document
|
|
8
|
+
from docx.sanitize.result import RemovedRelationship, SanitizationReport
|
|
9
|
+
|
|
10
|
+
__all__ = ["RemovedRelationship", "SanitizationReport", "sanitize_document"]
|
|
@@ -0,0 +1,221 @@
|
|
|
1
|
+
"""Implementation of the package-level sanitization boundary."""
|
|
2
|
+
|
|
3
|
+
from __future__ import annotations
|
|
4
|
+
|
|
5
|
+
from typing import TYPE_CHECKING, Iterator
|
|
6
|
+
|
|
7
|
+
from lxml import etree
|
|
8
|
+
|
|
9
|
+
from docx.opc.oxml import serialize_part_xml
|
|
10
|
+
from docx.opc.part import Part, XmlPart
|
|
11
|
+
from docx.oxml.ns import qn
|
|
12
|
+
from docx.oxml.parser import parse_xml
|
|
13
|
+
from docx.sanitize.result import RemovedRelationship, SanitizationReport
|
|
14
|
+
|
|
15
|
+
if TYPE_CHECKING:
|
|
16
|
+
from lxml.etree import _Element as etree_Element # pyright: ignore[reportPrivateUsage]
|
|
17
|
+
|
|
18
|
+
from docx.document import Document
|
|
19
|
+
from docx.opc.package import OpcPackage
|
|
20
|
+
from docx.oxml.xmlchemy import BaseOxmlElement
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
_COMMENT_MARKER_TAGS = (
|
|
24
|
+
qn("w:commentRangeStart"),
|
|
25
|
+
qn("w:commentRangeEnd"),
|
|
26
|
+
qn("w:commentReference"),
|
|
27
|
+
)
|
|
28
|
+
_COMMENT_RELATIONSHIP_NAMES = frozenset(
|
|
29
|
+
{
|
|
30
|
+
"commentauthors",
|
|
31
|
+
"comments",
|
|
32
|
+
"commentsextended",
|
|
33
|
+
"commentsextensible",
|
|
34
|
+
"commentsids",
|
|
35
|
+
"people",
|
|
36
|
+
}
|
|
37
|
+
)
|
|
38
|
+
_FORMATTING_REVISION_TAGS = tuple(
|
|
39
|
+
qn(tag)
|
|
40
|
+
for tag in (
|
|
41
|
+
"w:rPrChange",
|
|
42
|
+
"w:pPrChange",
|
|
43
|
+
"w:tblPrChange",
|
|
44
|
+
"w:trPrChange",
|
|
45
|
+
"w:tcPrChange",
|
|
46
|
+
"w:sectPrChange",
|
|
47
|
+
)
|
|
48
|
+
)
|
|
49
|
+
_WEB_EXTENSION_RELATIONSHIP_NAMES = frozenset({"webextension", "webextensiontaskpanes"})
|
|
50
|
+
|
|
51
|
+
|
|
52
|
+
def sanitize_document(
|
|
53
|
+
document: Document,
|
|
54
|
+
*,
|
|
55
|
+
personal_metadata: bool,
|
|
56
|
+
comments: bool,
|
|
57
|
+
web_extensions: bool,
|
|
58
|
+
formatting_revisions: bool,
|
|
59
|
+
) -> SanitizationReport:
|
|
60
|
+
"""Apply selected sanitizers while keeping all graph mechanics internal."""
|
|
61
|
+
package = document.part.package
|
|
62
|
+
assert package is not None
|
|
63
|
+
|
|
64
|
+
if not any((personal_metadata, comments, web_extensions, formatting_revisions)):
|
|
65
|
+
return SanitizationReport()
|
|
66
|
+
|
|
67
|
+
parts_before = _reachable_part_names(package)
|
|
68
|
+
scrubbed_properties: list[str] = []
|
|
69
|
+
removed_relationships: list[RemovedRelationship] = []
|
|
70
|
+
warnings: list[str] = []
|
|
71
|
+
removed_comment_markers = 0
|
|
72
|
+
removed_formatting_revisions = 0
|
|
73
|
+
|
|
74
|
+
if personal_metadata:
|
|
75
|
+
scrubbed_properties.extend(_scrub_personal_metadata(package))
|
|
76
|
+
|
|
77
|
+
if comments or formatting_revisions:
|
|
78
|
+
for part, root in _iter_word_xml(package, warnings):
|
|
79
|
+
part_changed = False
|
|
80
|
+
if comments:
|
|
81
|
+
count = _remove_elements(root, _COMMENT_MARKER_TAGS)
|
|
82
|
+
removed_comment_markers += count
|
|
83
|
+
part_changed = part_changed or count > 0
|
|
84
|
+
if formatting_revisions:
|
|
85
|
+
count = _remove_elements(root, _FORMATTING_REVISION_TAGS)
|
|
86
|
+
removed_formatting_revisions += count
|
|
87
|
+
part_changed = part_changed or count > 0
|
|
88
|
+
if part_changed and not isinstance(part, XmlPart):
|
|
89
|
+
part.replace_blob(serialize_part_xml(root))
|
|
90
|
+
|
|
91
|
+
if comments:
|
|
92
|
+
removed_relationships.extend(_drop_relationships(package, _COMMENT_RELATIONSHIP_NAMES))
|
|
93
|
+
if web_extensions:
|
|
94
|
+
removed_relationships.extend(
|
|
95
|
+
_drop_relationships(package, _WEB_EXTENSION_RELATIONSHIP_NAMES)
|
|
96
|
+
)
|
|
97
|
+
|
|
98
|
+
parts_after = _reachable_part_names(package)
|
|
99
|
+
return SanitizationReport(
|
|
100
|
+
scrubbed_properties=tuple(scrubbed_properties),
|
|
101
|
+
removed_comment_markers=removed_comment_markers,
|
|
102
|
+
removed_formatting_revisions=removed_formatting_revisions,
|
|
103
|
+
removed_parts=tuple(sorted(parts_before - parts_after)),
|
|
104
|
+
removed_relationships=tuple(removed_relationships),
|
|
105
|
+
warnings=tuple(warnings),
|
|
106
|
+
)
|
|
107
|
+
|
|
108
|
+
|
|
109
|
+
def _drop_relationships(
|
|
110
|
+
package: OpcPackage, relationship_names: frozenset[str]
|
|
111
|
+
) -> list[RemovedRelationship]:
|
|
112
|
+
removed: list[RemovedRelationship] = []
|
|
113
|
+
for source_name, source in _relationship_sources(package):
|
|
114
|
+
for rId, rel in list(source.rels.items()):
|
|
115
|
+
if _relationship_name(rel.reltype) not in relationship_names:
|
|
116
|
+
continue
|
|
117
|
+
target = rel.target_ref if rel.is_external else str(rel.target_part.partname)
|
|
118
|
+
removed.append(RemovedRelationship(source_name, rId, rel.reltype, target))
|
|
119
|
+
del source.rels[rId]
|
|
120
|
+
return removed
|
|
121
|
+
|
|
122
|
+
|
|
123
|
+
def _iter_word_xml(
|
|
124
|
+
package: OpcPackage, warnings: list[str]
|
|
125
|
+
) -> Iterator[tuple[Part, BaseOxmlElement]]:
|
|
126
|
+
for part in _reachable_parts(package):
|
|
127
|
+
if not str(part.partname).startswith("/word/"):
|
|
128
|
+
continue
|
|
129
|
+
if isinstance(part, XmlPart):
|
|
130
|
+
yield part, part.element
|
|
131
|
+
continue
|
|
132
|
+
if not part.content_type.endswith("+xml") and part.content_type != "application/xml":
|
|
133
|
+
continue
|
|
134
|
+
try:
|
|
135
|
+
yield part, parse_xml(part.blob)
|
|
136
|
+
except etree.XMLSyntaxError as exc:
|
|
137
|
+
warnings.append(f"Could not sanitize XML part {part.partname}: {exc}")
|
|
138
|
+
|
|
139
|
+
|
|
140
|
+
def _reachable_parts(package: OpcPackage) -> list[Part]:
|
|
141
|
+
parts: list[Part] = []
|
|
142
|
+
visited: set[int] = set()
|
|
143
|
+
|
|
144
|
+
def walk(source: OpcPackage | Part) -> None:
|
|
145
|
+
for rel in source.rels.values():
|
|
146
|
+
if rel.is_external:
|
|
147
|
+
continue
|
|
148
|
+
part = rel.target_part
|
|
149
|
+
identity = id(part)
|
|
150
|
+
if identity in visited:
|
|
151
|
+
continue
|
|
152
|
+
visited.add(identity)
|
|
153
|
+
parts.append(part)
|
|
154
|
+
walk(part)
|
|
155
|
+
|
|
156
|
+
walk(package)
|
|
157
|
+
return parts
|
|
158
|
+
|
|
159
|
+
|
|
160
|
+
def _reachable_part_names(package: OpcPackage) -> set[str]:
|
|
161
|
+
return {str(part.partname) for part in _reachable_parts(package)}
|
|
162
|
+
|
|
163
|
+
|
|
164
|
+
def _relationship_name(relationship_type: str) -> str:
|
|
165
|
+
return relationship_type.rstrip("/").rsplit("/", 1)[-1].lower()
|
|
166
|
+
|
|
167
|
+
|
|
168
|
+
def _relationship_sources(package: OpcPackage) -> list[tuple[str, OpcPackage | Part]]:
|
|
169
|
+
return [("/", package), *[(str(part.partname), part) for part in _reachable_parts(package)]]
|
|
170
|
+
|
|
171
|
+
|
|
172
|
+
def _remove_elements(root: BaseOxmlElement, tags: tuple[str, ...]) -> int:
|
|
173
|
+
tag_set = set(tags)
|
|
174
|
+
elements = [
|
|
175
|
+
element
|
|
176
|
+
for tag in tags
|
|
177
|
+
for element in root.iter(tag)
|
|
178
|
+
if not any(ancestor.tag in tag_set for ancestor in element.iterancestors())
|
|
179
|
+
]
|
|
180
|
+
for element in elements:
|
|
181
|
+
parent = element.getparent()
|
|
182
|
+
if parent is not None:
|
|
183
|
+
comment_run = _empty_comment_reference_run(element)
|
|
184
|
+
parent.remove(element)
|
|
185
|
+
if comment_run is not None:
|
|
186
|
+
comment_run_parent = comment_run.getparent()
|
|
187
|
+
if comment_run_parent is not None:
|
|
188
|
+
comment_run_parent.remove(comment_run)
|
|
189
|
+
return len(elements)
|
|
190
|
+
|
|
191
|
+
|
|
192
|
+
def _scrub_personal_metadata(package: OpcPackage) -> list[str]:
|
|
193
|
+
core_properties = package.core_properties
|
|
194
|
+
changed = core_properties.deduplicate("author", "last_modified_by", "revision")
|
|
195
|
+
if core_properties.author:
|
|
196
|
+
changed.add("author")
|
|
197
|
+
if core_properties.last_modified_by:
|
|
198
|
+
changed.add("last_modified_by")
|
|
199
|
+
if core_properties.revision != 1:
|
|
200
|
+
changed.add("revision")
|
|
201
|
+
core_properties.author = ""
|
|
202
|
+
core_properties.last_modified_by = ""
|
|
203
|
+
core_properties.revision = 1
|
|
204
|
+
return [name for name in ("author", "last_modified_by", "revision") if name in changed]
|
|
205
|
+
|
|
206
|
+
|
|
207
|
+
def _empty_comment_reference_run(element: etree_Element) -> etree_Element | None:
|
|
208
|
+
if element.tag != qn("w:commentReference"):
|
|
209
|
+
return None
|
|
210
|
+
run = element.getparent()
|
|
211
|
+
if run is None or run.tag != qn("w:r"):
|
|
212
|
+
return None
|
|
213
|
+
remaining = [child for child in run if child is not element]
|
|
214
|
+
if not remaining:
|
|
215
|
+
return run
|
|
216
|
+
if len(remaining) != 1 or remaining[0].tag != qn("w:rPr"):
|
|
217
|
+
return None
|
|
218
|
+
run_properties = remaining[0]
|
|
219
|
+
if len(run_properties) != 1 or run_properties[0].tag != qn("w:rStyle"):
|
|
220
|
+
return None
|
|
221
|
+
return run if run_properties[0].get(qn("w:val")) == "CommentReference" else None
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
"""Value objects returned by document sanitization."""
|
|
2
|
+
|
|
3
|
+
from __future__ import annotations
|
|
4
|
+
|
|
5
|
+
from dataclasses import dataclass
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
@dataclass(frozen=True)
|
|
9
|
+
class RemovedRelationship:
|
|
10
|
+
"""A package relationship removed during sanitization."""
|
|
11
|
+
|
|
12
|
+
source: str
|
|
13
|
+
relationship_id: str
|
|
14
|
+
relationship_type: str
|
|
15
|
+
target: str
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
@dataclass(frozen=True)
|
|
19
|
+
class SanitizationReport:
|
|
20
|
+
"""Immutable summary of changes made by ``Document.sanitize()``."""
|
|
21
|
+
|
|
22
|
+
scrubbed_properties: tuple[str, ...] = ()
|
|
23
|
+
removed_comment_markers: int = 0
|
|
24
|
+
removed_formatting_revisions: int = 0
|
|
25
|
+
removed_parts: tuple[str, ...] = ()
|
|
26
|
+
removed_relationships: tuple[RemovedRelationship, ...] = ()
|
|
27
|
+
warnings: tuple[str, ...] = ()
|
|
28
|
+
|
|
29
|
+
@property
|
|
30
|
+
def changed(self) -> bool:
|
|
31
|
+
"""Whether the document package was modified."""
|
|
32
|
+
return bool(
|
|
33
|
+
self.scrubbed_properties
|
|
34
|
+
or self.removed_comment_markers
|
|
35
|
+
or self.removed_formatting_revisions
|
|
36
|
+
or self.removed_parts
|
|
37
|
+
or self.removed_relationships
|
|
38
|
+
)
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: python-docx-oss
|
|
3
|
-
Version: 0.
|
|
3
|
+
Version: 0.3.0
|
|
4
4
|
Summary: Create, read, and update Microsoft Word .docx files.
|
|
5
5
|
Author: Ethan St Lee
|
|
6
6
|
License-Expression: MIT
|
|
@@ -23,7 +23,7 @@ Classifier: Topic :: Software Development :: Libraries
|
|
|
23
23
|
Requires-Python: >=3.12
|
|
24
24
|
Description-Content-Type: text/markdown
|
|
25
25
|
License-File: LICENSE
|
|
26
|
-
Requires-Dist: lxml>=
|
|
26
|
+
Requires-Dist: lxml>=6.1.0
|
|
27
27
|
Requires-Dist: typing_extensions>=4.9.0
|
|
28
28
|
Dynamic: license-file
|
|
29
29
|
|
|
@@ -65,7 +65,8 @@ or low-level package and relationship access.
|
|
|
65
65
|
| Latin and East Asian font controls | Stable | `run.font.name`, `run.font.hAnsi`, `run.font.eastAsia` |
|
|
66
66
|
| Low-level OPC parts and relationships | Stable | `document.part.package`, `part.rels` |
|
|
67
67
|
| In-memory read, export, and independent copies | Stable | `Document()`, `to_bytes()`, `copy()` |
|
|
68
|
-
|
|
|
68
|
+
| Document sanitization | Development | `document.sanitize()` |
|
|
69
|
+
| Package inspection and diff | Planned | — |
|
|
69
70
|
|
|
70
71
|
## Installation
|
|
71
72
|
|
|
@@ -29,6 +29,7 @@ docs/_themes/armstrong/static/rtd.css_t
|
|
|
29
29
|
docs/api/comments.rst
|
|
30
30
|
docs/api/dml.rst
|
|
31
31
|
docs/api/document.rst
|
|
32
|
+
docs/api/sanitize.rst
|
|
32
33
|
docs/api/section.rst
|
|
33
34
|
docs/api/settings.rst
|
|
34
35
|
docs/api/shape.rst
|
|
@@ -98,6 +99,7 @@ docs/user/documents.rst
|
|
|
98
99
|
docs/user/hdrftr.rst
|
|
99
100
|
docs/user/install.rst
|
|
100
101
|
docs/user/quickstart.rst
|
|
102
|
+
docs/user/sanitization.rst
|
|
101
103
|
docs/user/sections.rst
|
|
102
104
|
docs/user/shapes.rst
|
|
103
105
|
docs/user/styles-understanding.rst
|
|
@@ -343,6 +345,9 @@ src/docx/parts/numbering.py
|
|
|
343
345
|
src/docx/parts/settings.py
|
|
344
346
|
src/docx/parts/story.py
|
|
345
347
|
src/docx/parts/styles.py
|
|
348
|
+
src/docx/sanitize/__init__.py
|
|
349
|
+
src/docx/sanitize/cleaner.py
|
|
350
|
+
src/docx/sanitize/result.py
|
|
346
351
|
src/docx/styles/__init__.py
|
|
347
352
|
src/docx/styles/latent.py
|
|
348
353
|
src/docx/styles/style.py
|
|
@@ -393,6 +398,7 @@ tests/test_document.py
|
|
|
393
398
|
tests/test_drawing.py
|
|
394
399
|
tests/test_enum.py
|
|
395
400
|
tests/test_package.py
|
|
401
|
+
tests/test_sanitize.py
|
|
396
402
|
tests/test_section.py
|
|
397
403
|
tests/test_settings.py
|
|
398
404
|
tests/test_shape.py
|
|
@@ -402,6 +408,7 @@ tests/unitdata.py
|
|
|
402
408
|
tests/dml/__init__.py
|
|
403
409
|
tests/dml/test_color.py
|
|
404
410
|
tests/fixtures/README.md
|
|
411
|
+
tests/fixtures/comments/word-comments-rich.docx
|
|
405
412
|
tests/fixtures/customxml/generate_fixture.py
|
|
406
413
|
tests/fixtures/customxml/multiple-custom-xml-parts.docx
|
|
407
414
|
tests/fixtures/documents/word-blank.docx
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
lxml>=
|
|
1
|
+
lxml>=6.1.0
|
|
2
2
|
typing_extensions>=4.9.0
|