Repository navigation
Conversation
Contributor
There was a problem hiding this comment.
Copilot review overview
🟡 Changes recommended
The SWT.SINGLE regression path does not select an item, so it misses the affected selected-tab sizing logic.
Review effort: Balanced
Findings: 1
What changed in this PR
Prevents CTabFolder chevron and min/max toolbar overlap by sizing the chevron after its image is available.
Changes:
- Initializes the chevron image before measuring it.
- Adds width/font regression coverage and clearer overlap diagnostics.
| File | Description |
|---|---|
CTabFolder.java |
Corrects chevron measurement timing. |
Test_org_eclipse_swt_custom_CTabFolder.java |
Adds overlap regression coverage and diagnostics. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
When the chevron is shown for the first time, setItemSize measured the chevron tool bar before its image was set, so it reserved less room than the final chevron needs. The selected tab then kept too much width and the chevron ran into the right-aligned min/max tool bar, depending on the font. The chevron image is now created before the chevron is measured. See eclipse-platform#2855 Assisted-by: multiple AI agents and layers of automated tooling 🤖
vogella
force-pushed
the
ctabfolder-toolbar-overlap
branch
from
October 7, 2026 06:59
0952c17 to
9d5f209
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

When the chevron of a CTabFolder is shown for the first time, setItemSize measured the chevron tool bar before its image was set, so it reserved less room than the final chevron needs. The selected tab then kept too much width and the chevron ran into the right-aligned min/max tool bar, which made test_childControlOverlap fail on GTK3 depending on the font. The chevron image is now created before the chevron is measured, in both the multi-tab and the SWT.SINGLE layout. A new test sweeps folder widths and font sizes on freshly created folders, and the overlap check now reports which elements overlap.
See #2855