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

Method split

src/pptx/table.py:312–328  ·  view source on GitHub ↗

Remove merge from this (merge-origin) cell. The merged cell represented by this object will be "unmerged", yielding a separate unmerged cell for each grid cell previously spanned by this merge. Raises |ValueError| when this cell is not a merge-origin cell. Test with

(self)

Source from the content-addressed store, hash-verified

310 return self._tc.gridSpan
311
312 def split(self) -> None:
313 """Remove merge from this (merge-origin) cell.
314
315 The merged cell represented by this object will be "unmerged", yielding a separate
316 unmerged cell for each grid cell previously spanned by this merge.
317
318 Raises |ValueError| when this cell is not a merge-origin cell. Test with
319 `.is_merge_origin` before calling.
320 """
321 if not self.is_merge_origin:
322 raise ValueError("not a merge-origin cell; only a merge-origin cell can be sp" "lit")
323
324 tc_range = TcRange.from_merge_origin(self._tc)
325
326 for tc in tc_range.iter_tcs():
327 tc.rowSpan = tc.gridSpan = 1
328 tc.hMerge = tc.vMerge = False
329
330 @property
331 def text(self) -> str:

Callers 15

__init__Method · 0.80
__init__Method · 0.80
_qtagFunction · 0.80
pfxdtagFunction · 0.80
qnFunction · 0.80
parse_xsd.pyFile · 0.80
pfxdtagFunction · 0.80
qtagFunction · 0.80
environment.pyFile · 0.80
helpers.pyFile · 0.80

Calls 2

from_merge_originMethod · 0.80
iter_tcsMethod · 0.45