MCPcopy Create free account
hub / github.com/scanny/python-pptx / serialize_part_xml

Function serialize_part_xml

src/pptx/opc/oxml.py:56–61  ·  view source on GitHub ↗

Produce XML-file bytes for `part_elm`, suitable for writing directly to a `.xml` file. Includes XML-declaration header.

(part_elm: BaseOxmlElement)

Source from the content-addressed store, hash-verified

54
55
56def serialize_part_xml(part_elm: BaseOxmlElement) -> bytes:
57 """Produce XML-file bytes for `part_elm`, suitable for writing directly to a `.xml` file.
58
59 Includes XML-declaration header.
60 """
61 return etree.tostring(part_elm, encoding="UTF-8", standalone=True)
62
63
64class CT_Default(BaseOxmlElement):

Calls

no outgoing calls

Used in the wild real call sites across dependent graphs

searching dependent graphs…