extendedprops
extendedprops
¶
Provides ExtendedProperties, the application-specific document properties.
These are the properties stored in /docProps/app.xml, such as the word count, the
editing time and the application that produced the document. They complement the
Dublin-Core properties in /docProps/core.xml exposed by CoreProperties.
ExtendedProperties
¶
ExtendedProperties(element: CT_ExtendedProperties)
Corresponds to part named /docProps/app.xml.
Every property reads None when the corresponding element is absent from the XML,
which is the normal state for most of them. Assigning None removes the element.
Word maintains the statistics properties (pages, words, characters,
characters_with_spaces, lines, paragraphs) itself and recalculates them when
the document is next opened and repaginated. Values written here are what a reader
sees before that happens; this library does not compute them.
Source code in src/docx/opc/extendedprops.py
template
property
writable
¶
Name of the template attached to the document, e.g. "Normal.dotm".
application
property
writable
¶
Name of the application that produced the document.
app_version
property
writable
¶
Version of the producing application, formatted "MM.mmmm".
presentation_format
property
writable
¶
Intended presentation format. Rarely set by Word.
hyperlink_base
property
writable
¶
Base path that relative hyperlinks in the document resolve against.
characters_with_spaces
property
writable
¶
Character count including spaces.
paragraphs
property
writable
¶
Paragraph count last recorded by the producing application.
doc_security
property
writable
¶
Document security flags, e.g. 1 for password-protected, 2 for read-only.
This records the intent of the producing application. It is not enforced by this library and provides no security guarantee.
scale_crop
property
writable
¶
True when the document thumbnail is scaled, False when cropped.
links_up_to_date
property
writable
¶
True when hyperlinks in the document are known to be current.
shared_doc
property
writable
¶
True when the document is flagged as shared between multiple authors.
hyperlinks_changed
property
writable
¶
True when hyperlinks changed and the producing application should update.