2023-11-21 14:22:40 -08:00
|
|
|
"""Table-related docx proxy-objects."""
|
|
|
|
|
|
|
|
from __future__ import annotations
|
|
|
|
|
2023-11-08 11:05:19 -08:00
|
|
|
from typing import Sequence
|
2023-09-19 15:32:46 -07:00
|
|
|
|
|
|
|
from docx.blkcntnr import BlockItemContainer
|
2023-11-21 14:22:40 -08:00
|
|
|
from docx.oxml.table import CT_Row, CT_Tbl, CT_Tc
|
2023-09-19 15:32:46 -07:00
|
|
|
from docx.shared import Parented
|
|
|
|
|
2023-10-12 23:26:14 -07:00
|
|
|
class _Cell(BlockItemContainer):
|
|
|
|
_tc: CT_Tc
|
2023-11-21 14:22:40 -08:00
|
|
|
def __init__(self, tc: CT_Tc, parent: Parented) -> None: ...
|
2023-11-07 16:37:21 -08:00
|
|
|
@property
|
|
|
|
def text(self) -> str: ...
|
2023-09-19 15:32:46 -07:00
|
|
|
|
2023-11-21 14:22:40 -08:00
|
|
|
class _Row(Parented):
|
|
|
|
_tr: CT_Row
|
2023-09-19 15:32:46 -07:00
|
|
|
@property
|
|
|
|
def cells(self) -> Sequence[_Cell]: ...
|
|
|
|
|
|
|
|
class _Rows(Sequence[_Row]): ...
|
|
|
|
|
|
|
|
class Table(Parented):
|
|
|
|
def __init__(self, tbl: CT_Tbl, parent: BlockItemContainer) -> None: ...
|
|
|
|
@property
|
|
|
|
def rows(self) -> _Rows: ...
|