Settings
Representation of the “settings.xml” part of the ODF document.
This part stores document-wide settings.
Classes:
| Name | Description |
|---|---|
Settings |
Representation of the “settings.xml” part of the ODF document. |
Settings
Bases: XmlPart
Representation of the “settings.xml” part of the ODF document.
This part stores document-wide settings.
Methods:
| Name | Description |
|---|---|
as_dict |
Serialize the settings content into a dictionary. |
Attributes:
| Name | Type | Description |
|---|---|---|
config_item_sets |
list[ConfigItemSet]
|
Get a list of first-level ConfigItemSet elements within the |
odf_office_version |
str
|
Get the “office:version” value of the settings part. |
Source code in odfdo/settings.py
35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 | |
config_item_sets
property
config_item_sets: list[ConfigItemSet]
Get a list of first-level ConfigItemSet elements within the settings.
These represent top-level configuration item sets in the document’s settings.
Returns:
list[ConfigItemSet]: A list of ConfigItemSet objects.
odf_office_version
property
odf_office_version: str
Get the “office:version” value of the settings part.
This value indicates the ODF version of the document settings.
Returns:
| Name | Type | Description |
|---|---|---|
str |
str
|
The “office:version” value, or an empty string if not found. |
_get_body
_get_body() -> OfficeSettings
Source code in odfdo/settings.py
41 42 43 44 45 | |
as_dict
as_dict() -> dict[
str, str | int | bool | dict[str, Any] | list[Any]
]
Serialize the settings content into a dictionary.
This method delegates the serialization to the underlying
OfficeSettings body, returning a dictionary representation of
the settings.
Returns:
| Name | Type | Description |
|---|---|---|
dict |
dict[str, str | int | bool | dict[str, Any] | list[Any]]
|
A dictionary representing the settings content. |
Source code in odfdo/settings.py
79 80 81 82 83 84 85 86 87 88 89 90 | |