fix(panel): align the chart with the blocks under it #23
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "fix/align-right-column"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Right, and the first version of this PR had it backwards — it narrowed the chart
to 287 to meet the blocks below. Reversed: the chart is untouched and everything
else reaches it.
The measurement that started it
The cause was that the derivation only ran one way. The chart's width was the
column's, and every block under it was that minus the scroll's own insets:
The fix
CONTENT_Wis still the chart's own width. The other blocks reach it, and the18 px comes off the panel instead of off them:
plugin.toml'swidthgoes 578 → 596. The scrollbar now gets a strip of its ownbeside the content rather than a bite out of it.
BAR_Wis back to a plain 19 —the chart is the width chosen for a reason here, so it is the input, not the
output.
A row stays one viewport inset narrower than the chrome because it starts that
far in, which is what puts the two right edges on the same pixel. A row cannot be
CONTENT_Wexactly at any panel width:ScrollView::m_viewportPaddingHisunreachable from the plugin whitelist, so the 4 px is not optional — widening the
panel is what makes the row's right edge land on the chart's anyway.
The gutter is still reserved unconditionally, for the reason already in the file:
m_scrollbarShownflips at the exact row count where the list starts scrolling(
scroll_view.cpp:429), and a row sized to live content would jump 14 px there.Verified on screen
A 1 px guide dropped at the content edge lands on the search field's right edge,
the chart's last column, and the scope total — all three on the same pixel, with
the bars visibly unchanged. Measured before the change, those were 1211 / 1211 /
1230.
Suite
17 states, 2358 field comparisons/ok; lint0 errors, 0 warnings.Pinned: each block's right edge against the others, the caption's elide budget
against them, the bars summing to the row they are pinned inside (the row's
own
widthcannot say it — a node does not clip its children, so aBAR_Wthatdoes not come to
CONTENT_Wleaves the row declaring one width and paintinganother), and the columns adding up to
596 - 28. That last one tiesplugin.toml'swidthto the constants for the first time — flagged on #21 asout of reach, and deriving
RIGHT_Wis what brought it in reach.11 mutations, no survivors. Notably
B8— narrowing the rows by the gutter again— is the exact old behaviour, and it now fails.
f2c6b3994dto08fb8b6d18