deckkit 0.1.0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- deckkit/__init__.py +12 -0
- deckkit/_bundled_fonts.py +54 -0
- deckkit/_diagnostics.py +48 -0
- deckkit/_font_assets/SOURCES.txt +9 -0
- deckkit/_font_assets/SourceCodePro-Bold.ttf +0 -0
- deckkit/_font_assets/SourceCodePro-BoldIt.ttf +0 -0
- deckkit/_font_assets/SourceCodePro-It.ttf +0 -0
- deckkit/_font_assets/SourceCodePro-LICENSE.txt +93 -0
- deckkit/_font_assets/SourceCodePro-Regular.ttf +0 -0
- deckkit/_font_assets/SourceSans3-Bold.ttf +0 -0
- deckkit/_font_assets/SourceSans3-BoldIt.ttf +0 -0
- deckkit/_font_assets/SourceSans3-It.ttf +0 -0
- deckkit/_font_assets/SourceSans3-LICENSE.txt +93 -0
- deckkit/_font_assets/SourceSans3-Regular.ttf +0 -0
- deckkit/_variable_evaluation.py +82 -0
- deckkit/animation.py +211 -0
- deckkit/annotations.py +161 -0
- deckkit/backends/__init__.py +1 -0
- deckkit/backends/_font_embedding.py +41 -0
- deckkit/backends/_pptx_fonts.py +230 -0
- deckkit/backends/_pptx_shadows.py +241 -0
- deckkit/backends/_pptx_tables.py +251 -0
- deckkit/backends/pptx.py +1225 -0
- deckkit/backends/pptx_animation.py +175 -0
- deckkit/backends/svg.py +527 -0
- deckkit/canvas/__init__.py +40 -0
- deckkit/canvas/_geometry.py +49 -0
- deckkit/canvas/clipping.py +336 -0
- deckkit/canvas/context.py +34 -0
- deckkit/canvas/elements.py +306 -0
- deckkit/canvas/path.py +250 -0
- deckkit/canvas/scene.py +74 -0
- deckkit/canvas/style.py +31 -0
- deckkit/charts/__init__.py +59 -0
- deckkit/charts/axes.py +249 -0
- deckkit/charts/chart.py +244 -0
- deckkit/charts/content.py +132 -0
- deckkit/charts/context.py +45 -0
- deckkit/charts/interval.py +166 -0
- deckkit/charts/legends.py +82 -0
- deckkit/charts/marks.py +410 -0
- deckkit/charts/scales.py +205 -0
- deckkit/citations.py +200 -0
- deckkit/compiler.py +410 -0
- deckkit/context.py +72 -0
- deckkit/deck.py +168 -0
- deckkit/drawables/__init__.py +42 -0
- deckkit/drawables/bounds.py +17 -0
- deckkit/drawables/connector.py +22 -0
- deckkit/drawables/drawable.py +38 -0
- deckkit/drawables/ellipse.py +21 -0
- deckkit/drawables/group.py +10 -0
- deckkit/drawables/image.py +14 -0
- deckkit/drawables/line.py +18 -0
- deckkit/drawables/path.py +78 -0
- deckkit/drawables/rectangle.py +24 -0
- deckkit/drawables/rich_text.py +176 -0
- deckkit/drawables/table.py +42 -0
- deckkit/drawables/text.py +29 -0
- deckkit/effects.py +84 -0
- deckkit/expanded_views.py +561 -0
- deckkit/fonts.py +329 -0
- deckkit/geometry.py +48 -0
- deckkit/identity.py +72 -0
- deckkit/layout.py +398 -0
- deckkit/layouts/__init__.py +20 -0
- deckkit/layouts/_content.py +27 -0
- deckkit/layouts/annotations.py +217 -0
- deckkit/layouts/containers.py +202 -0
- deckkit/layouts/grid.py +299 -0
- deckkit/layouts/modifiers.py +200 -0
- deckkit/layouts/primitives.py +213 -0
- deckkit/layouts/table.py +139 -0
- deckkit/measurement.py +420 -0
- deckkit/paint.py +73 -0
- deckkit/py.typed +0 -0
- deckkit/reconcile.py +119 -0
- deckkit/semantic.py +47 -0
- deckkit/theme.py +364 -0
- deckkit/themes/__init__.py +91 -0
- deckkit/themes/clarity.py +98 -0
- deckkit/tokens.py +226 -0
- deckkit/units.py +73 -0
- deckkit/variables.py +212 -0
- deckkit/view_expansion.py +185 -0
- deckkit/views/__init__.py +100 -0
- deckkit/views/_code_source.py +42 -0
- deckkit/views/_drawing.py +52 -0
- deckkit/views/canvas.py +27 -0
- deckkit/views/code.py +481 -0
- deckkit/views/code_evolution.py +284 -0
- deckkit/views/composite_view.py +19 -0
- deckkit/views/divider.py +38 -0
- deckkit/views/ellipse.py +38 -0
- deckkit/views/grid.py +156 -0
- deckkit/views/hstack.py +43 -0
- deckkit/views/image.py +43 -0
- deckkit/views/layout_view.py +30 -0
- deckkit/views/line.py +31 -0
- deckkit/views/modifier_views.py +281 -0
- deckkit/views/path.py +36 -0
- deckkit/views/primitive_view.py +16 -0
- deckkit/views/pygments_highlighter.py +67 -0
- deckkit/views/rectangle.py +61 -0
- deckkit/views/section_number.py +21 -0
- deckkit/views/semantic/__init__.py +51 -0
- deckkit/views/semantic/before_after.py +109 -0
- deckkit/views/semantic/bullet_graph.py +216 -0
- deckkit/views/semantic/card.py +129 -0
- deckkit/views/semantic/code_block.py +41 -0
- deckkit/views/semantic/diff.py +642 -0
- deckkit/views/semantic/estimate_interval.py +137 -0
- deckkit/views/semantic/figure.py +55 -0
- deckkit/views/semantic/item_list.py +171 -0
- deckkit/views/semantic/metric.py +74 -0
- deckkit/views/semantic/pill.py +69 -0
- deckkit/views/semantic/pipeline.py +94 -0
- deckkit/views/semantic/pipeline_stage.py +59 -0
- deckkit/views/semantic/semantic_view.py +76 -0
- deckkit/views/semantic/sparkline.py +164 -0
- deckkit/views/semantic/table.py +439 -0
- deckkit/views/semantic/terminal.py +361 -0
- deckkit/views/semantic/timeline.py +158 -0
- deckkit/views/slide.py +37 -0
- deckkit/views/slide_number.py +20 -0
- deckkit/views/slides/__init__.py +16 -0
- deckkit/views/slides/section_slide.py +89 -0
- deckkit/views/slides/slide_margins.py +32 -0
- deckkit/views/slides/slide_with_margins.py +22 -0
- deckkit/views/slides/title_and_content.py +49 -0
- deckkit/views/slides/title_and_content_slide.py +55 -0
- deckkit/views/spacer.py +45 -0
- deckkit/views/stack.py +36 -0
- deckkit/views/text.py +142 -0
- deckkit/views/view.py +229 -0
- deckkit/views/vstack.py +31 -0
- deckkit/views/zstack.py +27 -0
- deckkit-0.1.0.dist-info/METADATA +123 -0
- deckkit-0.1.0.dist-info/RECORD +144 -0
- deckkit-0.1.0.dist-info/WHEEL +5 -0
- deckkit-0.1.0.dist-info/licenses/LICENSE +21 -0
- deckkit-0.1.0.dist-info/licenses/src/deckkit/_font_assets/SourceCodePro-LICENSE.txt +93 -0
- deckkit-0.1.0.dist-info/licenses/src/deckkit/_font_assets/SourceSans3-LICENSE.txt +93 -0
- deckkit-0.1.0.dist-info/top_level.txt +1 -0
|
@@ -0,0 +1,213 @@
|
|
|
1
|
+
from __future__ import annotations
|
|
2
|
+
|
|
3
|
+
from collections.abc import Sequence
|
|
4
|
+
from dataclasses import dataclass
|
|
5
|
+
|
|
6
|
+
from ..canvas import CanvasContext, CanvasRenderer, CanvasSize, scene_from
|
|
7
|
+
from ..context import Environment
|
|
8
|
+
from ..layout import (
|
|
9
|
+
CAP_CENTER,
|
|
10
|
+
FIRST_BASELINE,
|
|
11
|
+
LAST_BASELINE,
|
|
12
|
+
LayoutChild,
|
|
13
|
+
LayoutContext,
|
|
14
|
+
LayoutPlan,
|
|
15
|
+
ProposedSize,
|
|
16
|
+
StackAxis,
|
|
17
|
+
)
|
|
18
|
+
from ..measurement import StyledTextLine, TextFlow, layout_styled_text
|
|
19
|
+
from ..units import Length, pt
|
|
20
|
+
from ._content import content
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
@dataclass(frozen=True)
|
|
24
|
+
class TextLayout:
|
|
25
|
+
styled_lines: tuple[StyledTextLine, ...]
|
|
26
|
+
flow: TextFlow = "wrapped"
|
|
27
|
+
font_sample: str = ""
|
|
28
|
+
|
|
29
|
+
def measure(
|
|
30
|
+
self,
|
|
31
|
+
proposal: ProposedSize,
|
|
32
|
+
children: Sequence[LayoutChild],
|
|
33
|
+
context: LayoutContext,
|
|
34
|
+
) -> LayoutPlan:
|
|
35
|
+
measured_text = layout_styled_text(
|
|
36
|
+
context.measurer,
|
|
37
|
+
context.font_resolver,
|
|
38
|
+
self.styled_lines,
|
|
39
|
+
proposal.width if proposal.width is not None else pt(1_000_000_000),
|
|
40
|
+
self.flow,
|
|
41
|
+
font_sample=self.font_sample,
|
|
42
|
+
)
|
|
43
|
+
guides = {}
|
|
44
|
+
if measured_text.lines:
|
|
45
|
+
first, last = measured_text.lines[0], measured_text.lines[-1]
|
|
46
|
+
cap_height = max(
|
|
47
|
+
(
|
|
48
|
+
run.metrics.cap_height
|
|
49
|
+
for run in first.runs
|
|
50
|
+
if run.metrics.cap_height is not None
|
|
51
|
+
),
|
|
52
|
+
default=None,
|
|
53
|
+
)
|
|
54
|
+
guides = {
|
|
55
|
+
FIRST_BASELINE: first.baseline,
|
|
56
|
+
LAST_BASELINE: measured_text.height - last.height + last.baseline,
|
|
57
|
+
CAP_CENTER: first.baseline - cap_height / 2
|
|
58
|
+
if cap_height is not None
|
|
59
|
+
else first.height / 2,
|
|
60
|
+
}
|
|
61
|
+
return content(
|
|
62
|
+
measured_text.width,
|
|
63
|
+
measured_text.height,
|
|
64
|
+
measured_text=measured_text,
|
|
65
|
+
line_width=measured_text.width,
|
|
66
|
+
vertical_guides=guides,
|
|
67
|
+
)
|
|
68
|
+
|
|
69
|
+
|
|
70
|
+
@dataclass(frozen=True)
|
|
71
|
+
class ShapeLayout:
|
|
72
|
+
def measure(
|
|
73
|
+
self,
|
|
74
|
+
proposal: ProposedSize,
|
|
75
|
+
children: Sequence[LayoutChild],
|
|
76
|
+
context: LayoutContext,
|
|
77
|
+
) -> LayoutPlan:
|
|
78
|
+
return content(proposal.width or pt(0), proposal.height or pt(0))
|
|
79
|
+
|
|
80
|
+
|
|
81
|
+
@dataclass(frozen=True)
|
|
82
|
+
class DrawingLayout:
|
|
83
|
+
environment: Environment
|
|
84
|
+
intrinsic_size: tuple[Length, Length] | None = None
|
|
85
|
+
|
|
86
|
+
def measure(
|
|
87
|
+
self,
|
|
88
|
+
proposal: ProposedSize,
|
|
89
|
+
children: Sequence[LayoutChild],
|
|
90
|
+
context: LayoutContext,
|
|
91
|
+
) -> LayoutPlan:
|
|
92
|
+
width, height = self.intrinsic_size or (
|
|
93
|
+
proposal.width or pt(0),
|
|
94
|
+
proposal.height or pt(0),
|
|
95
|
+
)
|
|
96
|
+
return content(
|
|
97
|
+
width,
|
|
98
|
+
height,
|
|
99
|
+
canvas_context=CanvasContext(
|
|
100
|
+
self.environment, context.measurer, context.font_resolver
|
|
101
|
+
),
|
|
102
|
+
)
|
|
103
|
+
|
|
104
|
+
|
|
105
|
+
@dataclass(frozen=True)
|
|
106
|
+
class DividerLayout:
|
|
107
|
+
environment: Environment
|
|
108
|
+
thickness: Length
|
|
109
|
+
orientation: StackAxis | None
|
|
110
|
+
|
|
111
|
+
def measure(
|
|
112
|
+
self,
|
|
113
|
+
proposal: ProposedSize,
|
|
114
|
+
children: Sequence[LayoutChild],
|
|
115
|
+
context: LayoutContext,
|
|
116
|
+
) -> LayoutPlan:
|
|
117
|
+
orientation = self.orientation
|
|
118
|
+
if orientation is None:
|
|
119
|
+
orientation = (
|
|
120
|
+
"vertical" if proposal.stack_axis == "horizontal" else "horizontal"
|
|
121
|
+
)
|
|
122
|
+
width, height = (
|
|
123
|
+
(proposal.width or pt(0), self.thickness)
|
|
124
|
+
if orientation == "horizontal"
|
|
125
|
+
else (self.thickness, proposal.height or pt(0))
|
|
126
|
+
)
|
|
127
|
+
return content(
|
|
128
|
+
width,
|
|
129
|
+
height,
|
|
130
|
+
orientation=orientation,
|
|
131
|
+
canvas_context=CanvasContext(
|
|
132
|
+
self.environment, context.measurer, context.font_resolver
|
|
133
|
+
),
|
|
134
|
+
)
|
|
135
|
+
|
|
136
|
+
|
|
137
|
+
@dataclass(frozen=True)
|
|
138
|
+
class SpacerLayout:
|
|
139
|
+
length: Length | None
|
|
140
|
+
minimum: Length
|
|
141
|
+
|
|
142
|
+
def measure(
|
|
143
|
+
self,
|
|
144
|
+
proposal: ProposedSize,
|
|
145
|
+
children: Sequence[LayoutChild],
|
|
146
|
+
context: LayoutContext,
|
|
147
|
+
) -> LayoutPlan:
|
|
148
|
+
def extent(value: Length | None) -> Length:
|
|
149
|
+
return (
|
|
150
|
+
self.length
|
|
151
|
+
if self.length is not None
|
|
152
|
+
else max(self.minimum, value or pt(0))
|
|
153
|
+
)
|
|
154
|
+
|
|
155
|
+
width = pt(0) if proposal.stack_axis == "vertical" else extent(proposal.width)
|
|
156
|
+
height = (
|
|
157
|
+
pt(0) if proposal.stack_axis == "horizontal" else extent(proposal.height)
|
|
158
|
+
)
|
|
159
|
+
return content(width, height)
|
|
160
|
+
|
|
161
|
+
|
|
162
|
+
@dataclass(frozen=True)
|
|
163
|
+
class CanvasLayout:
|
|
164
|
+
renderer: CanvasRenderer
|
|
165
|
+
environment: Environment
|
|
166
|
+
|
|
167
|
+
def measure(
|
|
168
|
+
self,
|
|
169
|
+
proposal: ProposedSize,
|
|
170
|
+
children: Sequence[LayoutChild],
|
|
171
|
+
context: LayoutContext,
|
|
172
|
+
) -> LayoutPlan:
|
|
173
|
+
width, height = proposal.width or pt(0), proposal.height or pt(0)
|
|
174
|
+
canvas_context = CanvasContext(
|
|
175
|
+
self.environment, context.measurer, context.font_resolver
|
|
176
|
+
)
|
|
177
|
+
scene = scene_from(self.renderer(canvas_context, CanvasSize(width, height)))
|
|
178
|
+
return content(
|
|
179
|
+
width,
|
|
180
|
+
height,
|
|
181
|
+
anchors=scene.measured_anchors(canvas_context),
|
|
182
|
+
canvas_context=canvas_context,
|
|
183
|
+
canvas_scene=scene,
|
|
184
|
+
)
|
|
185
|
+
|
|
186
|
+
|
|
187
|
+
@dataclass(frozen=True)
|
|
188
|
+
class ImageLayout:
|
|
189
|
+
width: Length
|
|
190
|
+
height: Length
|
|
191
|
+
fit: str = "contain"
|
|
192
|
+
|
|
193
|
+
def measure(
|
|
194
|
+
self,
|
|
195
|
+
proposal: ProposedSize,
|
|
196
|
+
children: Sequence[LayoutChild],
|
|
197
|
+
context: LayoutContext,
|
|
198
|
+
) -> LayoutPlan:
|
|
199
|
+
if (
|
|
200
|
+
self.fit == "cover"
|
|
201
|
+
and proposal.width is not None
|
|
202
|
+
and proposal.height is not None
|
|
203
|
+
):
|
|
204
|
+
return content(proposal.width, proposal.height)
|
|
205
|
+
width_scale = proposal.width / self.width if proposal.width is not None else 1
|
|
206
|
+
height_scale = (
|
|
207
|
+
proposal.height / self.height if proposal.height is not None else 1
|
|
208
|
+
)
|
|
209
|
+
scale = min(width_scale, height_scale, 1)
|
|
210
|
+
return content(
|
|
211
|
+
self.width * scale,
|
|
212
|
+
self.height * scale,
|
|
213
|
+
)
|
deckkit/layouts/table.py
ADDED
|
@@ -0,0 +1,139 @@
|
|
|
1
|
+
"""Measure one grid across a table's independently keyed rows."""
|
|
2
|
+
|
|
3
|
+
from __future__ import annotations
|
|
4
|
+
|
|
5
|
+
from collections.abc import Sequence
|
|
6
|
+
from dataclasses import dataclass
|
|
7
|
+
|
|
8
|
+
from ..canvas import Stroke
|
|
9
|
+
from ..drawables.table import TableRowGeometry
|
|
10
|
+
from ..layout import (
|
|
11
|
+
LayoutChild,
|
|
12
|
+
LayoutContext,
|
|
13
|
+
LayoutPlan,
|
|
14
|
+
Placement,
|
|
15
|
+
ProposedSize,
|
|
16
|
+
)
|
|
17
|
+
from ..units import Length, pt
|
|
18
|
+
from .grid import ColumnWidth, _CellArea, _measure_grid_row, _resolve_column_widths
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
@dataclass(frozen=True)
|
|
22
|
+
class _RowProposal(ProposedSize):
|
|
23
|
+
columns: tuple[Length, ...] = ()
|
|
24
|
+
|
|
25
|
+
|
|
26
|
+
@dataclass(frozen=True)
|
|
27
|
+
class TableRowLayout:
|
|
28
|
+
row: TableRowGeometry
|
|
29
|
+
columns: tuple[Length | ColumnWidth, ...]
|
|
30
|
+
|
|
31
|
+
def measure(
|
|
32
|
+
self,
|
|
33
|
+
proposal: ProposedSize,
|
|
34
|
+
children: Sequence[LayoutChild],
|
|
35
|
+
context: LayoutContext,
|
|
36
|
+
) -> LayoutPlan:
|
|
37
|
+
cells = self.row.cells
|
|
38
|
+
if not isinstance(proposal, _RowProposal):
|
|
39
|
+
natural, minimums = [], []
|
|
40
|
+
for child, cell, column in zip(children, cells, self.columns):
|
|
41
|
+
horizontal = cell.padding.horizontal
|
|
42
|
+
if isinstance(column, Length):
|
|
43
|
+
natural.append(column)
|
|
44
|
+
minimums.append(horizontal)
|
|
45
|
+
elif cell.plain_text:
|
|
46
|
+
natural.append(horizontal + child.measure(ProposedSize()).width)
|
|
47
|
+
minimums.append(
|
|
48
|
+
horizontal + child.measure(ProposedSize(width=pt(0))).width
|
|
49
|
+
)
|
|
50
|
+
elif column.ideal is not None:
|
|
51
|
+
# An explicit ideal also supports views with no intrinsic width.
|
|
52
|
+
natural.append(column.ideal)
|
|
53
|
+
minimums.append(horizontal)
|
|
54
|
+
else:
|
|
55
|
+
preferred = horizontal + child.measure(ProposedSize()).width
|
|
56
|
+
natural.append(preferred)
|
|
57
|
+
minimums.append(preferred)
|
|
58
|
+
return LayoutPlan(
|
|
59
|
+
sum(natural, pt(0)),
|
|
60
|
+
pt(0),
|
|
61
|
+
properties={"natural": tuple(natural), "minimums": tuple(minimums)},
|
|
62
|
+
)
|
|
63
|
+
|
|
64
|
+
x = pt(0)
|
|
65
|
+
areas = []
|
|
66
|
+
for cell, width in zip(cells, proposal.columns):
|
|
67
|
+
padding = cell.padding
|
|
68
|
+
areas.append(
|
|
69
|
+
_CellArea(
|
|
70
|
+
x,
|
|
71
|
+
width,
|
|
72
|
+
cell.alignment,
|
|
73
|
+
padding.leading,
|
|
74
|
+
padding.top,
|
|
75
|
+
padding.horizontal,
|
|
76
|
+
padding.vertical,
|
|
77
|
+
)
|
|
78
|
+
)
|
|
79
|
+
x += width
|
|
80
|
+
return _measure_grid_row(children, areas, x)
|
|
81
|
+
|
|
82
|
+
|
|
83
|
+
@dataclass(frozen=True)
|
|
84
|
+
class TableLayout:
|
|
85
|
+
columns: tuple[Length | ColumnWidth, ...]
|
|
86
|
+
numeric: tuple[bool, ...]
|
|
87
|
+
rows: tuple[TableRowGeometry, ...]
|
|
88
|
+
horizontal_rules: tuple[Stroke | None, ...]
|
|
89
|
+
vertical_rules: tuple[Stroke | None, ...]
|
|
90
|
+
native: bool
|
|
91
|
+
native_error: str | None
|
|
92
|
+
|
|
93
|
+
def measure(
|
|
94
|
+
self,
|
|
95
|
+
proposal: ProposedSize,
|
|
96
|
+
children: Sequence[LayoutChild],
|
|
97
|
+
context: LayoutContext,
|
|
98
|
+
) -> LayoutPlan:
|
|
99
|
+
# Each row's composite provides a key scope around its grid.
|
|
100
|
+
ideal_rows = [
|
|
101
|
+
child.measure(ProposedSize()).placements[0].plan for child in children
|
|
102
|
+
]
|
|
103
|
+
widths = self._column_widths(ideal_rows, proposal)
|
|
104
|
+
row_proposal = _RowProposal(width=sum(widths, pt(0)), columns=tuple(widths))
|
|
105
|
+
y = pt(0)
|
|
106
|
+
placements = []
|
|
107
|
+
for child in children:
|
|
108
|
+
plan = child.measure(row_proposal)
|
|
109
|
+
placements.append(Placement(child, plan, y=y))
|
|
110
|
+
y += plan.height
|
|
111
|
+
assert row_proposal.width is not None
|
|
112
|
+
return LayoutPlan(
|
|
113
|
+
row_proposal.width,
|
|
114
|
+
y,
|
|
115
|
+
tuple(placements),
|
|
116
|
+
properties={"column_widths": tuple(widths)},
|
|
117
|
+
)
|
|
118
|
+
|
|
119
|
+
def _column_widths(
|
|
120
|
+
self, rows: list[LayoutPlan], proposal: ProposedSize
|
|
121
|
+
) -> list[Length]:
|
|
122
|
+
natural: list[tuple[Length, ...]] = [row.properties["natural"] for row in rows]
|
|
123
|
+
required: list[tuple[Length, ...]] = [
|
|
124
|
+
row.properties["minimums"] for row in rows
|
|
125
|
+
]
|
|
126
|
+
preferred = [max(row[i] for row in natural) for i in range(len(self.columns))]
|
|
127
|
+
minimums = [max(row[i] for row in required) for i in range(len(self.columns))]
|
|
128
|
+
for i, column in enumerate(self.columns):
|
|
129
|
+
if self.numeric[i] and isinstance(column, ColumnWidth):
|
|
130
|
+
# Keep numbers intact while allowing their headers to wrap.
|
|
131
|
+
minimums[i] = max(
|
|
132
|
+
[minimums[i]]
|
|
133
|
+
+ [
|
|
134
|
+
widths[i]
|
|
135
|
+
for row, widths in zip(self.rows[1:], natural[1:])
|
|
136
|
+
if row.cells[i].plain_text
|
|
137
|
+
]
|
|
138
|
+
)
|
|
139
|
+
return _resolve_column_widths(self.columns, preferred, minimums, proposal)
|