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

Method add_num

src/docx/oxml/numbering.py:84–89  ·  view source on GitHub ↗

Return a newly added CT_Num ( ) element referencing the abstract numbering definition identified by `abstractNum_id`.

(self, abstractNum_id)

Source from the content-addressed store, hash-verified

82 num = ZeroOrMore("w:num", successors=("w:numIdMacAtCleanup",))
83
84 def add_num(self, abstractNum_id):
85 """Return a newly added CT_Num (<w:num>) element referencing the abstract
86 numbering definition identified by `abstractNum_id`."""
87 next_num_id = self._next_numId
88 num = CT_Num.new(next_num_id, abstractNum_id)
89 return self._insert_num(num)
90
91 def num_having_numId(self, numId):
92 """Return the ``<w:num>`` child element having ``numId`` attribute matching

Callers

nothing calls this directly

Calls 1

newMethod · 0.45

Tested by

no test coverage detected