Skip to content

Conversation

@HeikoKlare
Copy link
Contributor

@HeikoKlare HeikoKlare commented Feb 11, 2026

When moving a shell with a tree that uses images in any other than the first column to another monitor, those images will be lost in case the other monitor has a different zoom such that the UI is rescaled. The reason is that the DPI change handling for TreeItem does not consider the other images of the tree item at all.

This change explicitly resets all images of a tree item upon DPI change.

Fixes #3075

Remaining limitation

One limitation is that if an item does not have an image set for the first column, there will be blank space where the image could be after rescaling. This will be fixed independently via:

Before rescaling:
image

After rescaling:
image

This is, however, an issue that already happens now (without any rescaling) in case the item has a subitems that uses an image in the first column:
image
And it also happens if you set and then remove an image, like this:

item.setImage(imageColumn1);
item.setImage((Image) null);
image

When moving a shell with a tree that uses images in any other than the
first column to another monitor, those images will be lost in case the
other monitor has a different zoom such that the UI is rescaled. The
reason is that the DPI change handling for TreeItem does not consider
the other images of the tree item at all.

This change explicitly resets all images of a tree item upon DPI change.

Fixes eclipse-platform#3075
@github-actions
Copy link
Contributor

Test Results (win32)

   34 files  ±0     34 suites  ±0   5m 9s ⏱️ +22s
4 649 tests ±0  4 576 ✅ ±0  73 💤 ±0  0 ❌ ±0 
  174 runs  ±0    171 ✅ ±0   3 💤 ±0  0 ❌ ±0 

Results for commit 1b48476. ± Comparison against base commit 9c79cf6.

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.

Images of trees in a non-first column disappear upon DPI change [Windows] [Tree] Column icons and text overlaps in multi resolution monitor setup

1 participant