Skip to content

Draw the History column newest first so clipping drops the oldest runs [patch] - #367

Merged
matt-edmondson merged 1 commit into
mainfrom
fix/history-newest-first
Oct 13, 2026
Merged

matt-edmondson merged 1 commit into
mainfrom
fix/history-newest-first

Conversation

@matt-edmondson

Copy link
Copy Markdown
Contributor

Fixes #362

What was wrong

The History column is 80px wide by default, but ShowBranchHistory draws up to five frame-height indicators oldest first. Only about three fit, so the column clipped the two newest runs off its right edge. In the gallery, BuildMonitor's running run never appeared.

Change

  • The indicators are now drawn newest first, so when the column is too narrow it drops the oldest runs instead. This is the "safer half" the issue suggests, because it also covers a narrower width saved from an earlier session.
  • The run selection moved into internal static SelectHistoryRuns, so the order can be tested without ImGui.
  • README: the History column description now says "newest first".

I left the default column width alone. Sizing it from the frame height needs the font at runtime and can't fix a saved width anyway. It can follow separately if it's wanted.

Tests

New HistoryRunsTests checks three things: the newest run comes first, only five runs are shown, and canceled runs are skipped. All three fail with the old reversed order. With the change, all 144 tests pass (unit and UI).

🤖 Generated with Claude Code

https://claude.ai/code/session_016mc7y8RBT9hdbRWHYe3yxf


Generated by Claude Code

…s [patch]

The column is 80px wide but draws up to five frame-height indicators
oldest first, so the two newest runs were clipped off the right edge.
Draw them newest first instead, which also holds for a narrower width
persisted from an earlier session. The selection moves into
SelectHistoryRuns so the order is tested.

Fixes #362

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_016mc7y8RBT9hdbRWHYe3yxf
@sonarqubecloud

Copy link
Copy Markdown

@matt-edmondson
matt-edmondson merged commit ecb59a3 into main Oct 13, 2026
15 checks passed
@matt-edmondson
matt-edmondson deleted the fix/history-newest-first branch October 13, 2026 08:16
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.

History column clips the newest runs: five indicators do not fit in its 80px default width

2 participants