Skip to content

Conversation

@arunjose696
Copy link
Contributor

@arunjose696 arunjose696 commented Dec 4, 2025

On Windows HiDPI screens, the progress icon in the status bar could appear clipped because Toolbars are initially created by windows with default button size (24×22). When larger images are set (e.g., 32×32 for 200% scaling), the toolbar resizes but the parent layout isn't updated due to deferred layout.

This change replaces the deffered layout with a normal layout and adds a check to determine if the image size actually changed before requesting a relayout. The parent layout is now updated only when necessary, matching SWT's behavior for toolbar images and preventing unnecessary layouts while fixing the clipping issue. More information eclipse-platform/eclipse.platform.swt#706 (comment)

Steps to reproduce:

1)Set the monitors’ zoom to 200%. If using two monitors, make sure both have the same zoom just so that no DPI change occurs during startup.
2)Open a runtime workspace.
3)In the runtime workspace, create a plugin project and run it as an Eclipse application. This will start the progress bar, which is visible only briefly for a second.
4)Once the Eclipse application launches, try to relaunch it with the same workspace. You’ll see an error saying the workspace is already in use by another application.
5)While this dialog is visible, the progress bar remains visible, and here you can observe the clipped/cut-off icon.

Without this change, the progress bar does not relayout correctly on HiDPI screens, causing icon to be partially hidden.

Before
image

After

image

Fixes eclipse-platform/eclipse.platform.swt#706

@arunjose696 arunjose696 marked this pull request as ready for review December 4, 2025 09:43
@github-actions
Copy link
Contributor

github-actions bot commented Dec 4, 2025

Test Results

 3 018 files  ±0   3 018 suites  ±0   2h 10m 5s ⏱️ -19s
 8 249 tests ±0   8 001 ✅ ±0  248 💤 ±0  0 ❌ ±0 
23 667 runs  ±0  22 876 ✅ ±0  791 💤 ±0  0 ❌ ±0 

Results for commit b7ed83f. ± Comparison against base commit b4b98c6.

♻️ This comment has been updated with latest results.

Copy link
Contributor

@amartya4256 amartya4256 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested it and can verify the effect. Looks good hence approving.

…ange

On Windows HiDPI screens, the progress icon in the status bar could appear clipped because Toolbars are initially created  by windows with default button size (24×22). When larger images are set (e.g., 32×32 for 200% scaling), the toolbar resizes but the parent layout isn't updated due to deferred layout. This change adds a check to determine if the image size actually changed before requesting a relayout. The parent layout is now updated only when necessary, matching SWT's behavior for toolbar images and preventing unnecessary layouts while fixing the clipping issue.
@akoch-yatta akoch-yatta force-pushed the arunjose696/544/progressbar branch from d3bb12a to b7ed83f Compare December 19, 2025 08:47
Copy link
Contributor

@akoch-yatta akoch-yatta left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, I tested the changes and the proposed solution looks like a reasonable approach

@akoch-yatta akoch-yatta merged commit 32d98a1 into eclipse-platform:master Dec 19, 2025
18 checks passed
@akoch-yatta akoch-yatta deleted the arunjose696/544/progressbar branch December 19, 2025 09:38
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.

Progress bar icon in status bar cut off at 200% [Windows Hi-DPI] Progress icon is too big and clipped

3 participants