MCPcopy Index your code
hub / github.com/python-openxml/python-docx / CT_HdrFtr

Class CT_HdrFtr

src/docx/oxml/section.py:29–48  ·  view source on GitHub ↗

`w:hdr` and `w:ftr`, the root element for header and footer part respectively.

Source from the content-addressed store, hash-verified

27
28
29class CT_HdrFtr(BaseOxmlElement):
30 """`w:hdr` and `w:ftr`, the root element for header and footer part respectively."""
31
32 add_p: Callable[[], CT_P]
33 p_lst: List[CT_P]
34 tbl_lst: List[CT_Tbl]
35
36 _insert_tbl: Callable[[CT_Tbl], CT_Tbl]
37
38 p = ZeroOrMore("w:p", successors=())
39 tbl = ZeroOrMore("w:tbl", successors=())
40
41 @property
42 def inner_content_elements(self) -> List[CT_P | CT_Tbl]:
43 """Generate all `w:p` and `w:tbl` elements in this header or footer.
44
45 Elements appear in document order. Elements shaded by nesting in a `w:ins` or
46 other "wrapper" element will not be included.
47 """
48 return self.xpath("./w:p | ./w:tbl")
49
50
51class CT_HdrFtrRef(BaseOxmlElement):

Callers

nothing calls this directly

Calls 1

ZeroOrMoreClass · 0.90

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…