Skip to content

82 warn when a tables explicit column widths sum wider than the available page width - #85

Merged
Cadons merged 5 commits into
mainfrom
82-warn-when-a-tables-explicit-column-widths-sum-wider-than-the-available-page-width
Aug 16, 2026
Merged

82 warn when a tables explicit column widths sum wider than the available page width#85
Cadons merged 5 commits into
mainfrom
82-warn-when-a-tables-explicit-column-widths-sum-wider-than-the-available-page-width

Conversation

@Cadons

@Cadons Cadons commented Aug 16, 2026

Copy link
Copy Markdown
Owner

No description provided.

Cadons and others added 3 commits August 16, 2026 18:31
Mirrors the existing vertical page-bottom overflow warning (#71): a
table whose explicit column widths sum wider than the available width
previously overflowed the page margin silently. resolve_table_column_widths
already computes available_width and the fixed-column shortfall, so
detect the overage there and log it instead of just clamping it away.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
kCellPaddingX is a per-cell content inset already folded into every
cell's own measured_size (and therefore into each column's natural
width), but resolve_table_column_widths (and the matching wrap-budget
estimate in Measure) additionally subtracted 2*kCellPaddingX from
available_width as if it were a table-wide margin like table.padding().
That extra 5pt was never reintroduced anywhere, so a width-constrained
table always rendered 5pt narrower than its available width -- and
since the table is positioned flush against the container's leading
edge, the missing width showed up entirely as a gap on the table's
trailing (right) edge.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Cadons added 2 commits August 16, 2026 19:33
…-sum-wider-than-the-available-page-width

# Conflicts:
#	docraft/src/docraft/loom/pipeline/docraft_loom_layout_processor.cc
#	docraft/src/docraft/loom/pipeline/docraft_loom_measure_processor.cc
@sonarqubecloud

Copy link
Copy Markdown

@Cadons
Cadons merged commit d2a0cbb into main Aug 16, 2026
10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Warn when a Table's explicit column widths sum wider than the available page width

1 participant