-
Notifications
You must be signed in to change notification settings - Fork 219
Replacing Image(Device, ImageData) constructor in DefaultRangeIndicator with Image(Device, ImageDataProvider) #3004
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Replacing Image(Device, ImageData) constructor in DefaultRangeIndicator with Image(Device, ImageDataProvider) #3004
Conversation
047fde5
to
8f34f2e
Compare
Test Results 2 778 files ±0 2 778 suites ±0 1h 35m 3s ⏱️ - 2m 37s For more details on these failures, see this check. Results for commit 4e03f11. ± Comparison against base commit a9213eb. ♻️ This comment has been updated with latest results. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The code works, just some minor comments regarding coding practices.
...org.eclipse.ui.workbench.texteditor/src/org/eclipse/ui/texteditor/DefaultRangeIndicator.java
Outdated
Show resolved
Hide resolved
...org.eclipse.ui.workbench.texteditor/src/org/eclipse/ui/texteditor/DefaultRangeIndicator.java
Outdated
Show resolved
Hide resolved
...org.eclipse.ui.workbench.texteditor/src/org/eclipse/ui/texteditor/DefaultRangeIndicator.java
Outdated
Show resolved
Hide resolved
90e117f
to
52891ee
Compare
52891ee
to
56e62ca
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Last change: please adapt the commit message so that the 1st line has <=80 characters.
Something like:
Use constructor Image(Device, ImageDataProvider) in DefaultRangeIndicator
The rest of the commit message is fine, just the 1st line is too long.
…ator DefaultRangeIndicator previously used Image(Device, ImageData) constructor to draw a grid to display the selected range. Previously, the grid was rendered using a 1×1 pixel checkerboard pattern (blue and white), which was mainly inteded to work at 100% zoom. However, at higher zoom levels (e.g., 150%, 200%), the visual intensity of the pattern becomes different, causing the grid to appear visually inconsistent across zooms.
56e62ca
to
8359bf5
Compare
Done |
This pull request changes some projects for the first time in this development cycle.
An additional commit containing all the necessary changes was pushed to the top of this PR's branch. To obtain these changes (for example if you want to push more changes) either fetch from your fork or apply the git patch. Git patch
Further information are available in Common Build Issues - Missing version increments. |
I just manually bumped the version, like the bot was supposed to do on its own (see #3004 (comment)). @HannesWell just out of curiosity, do you have any idea what could have gone wrong? Is it maybe because Arun is not a contributor yet and I need to approve the workflow runs? |
That's a known limitation: the bot cannot push to forks of organizations. I think it's not even related to the bot but it's the same for any other maintainer. |
The check failures are unrelated and the flaky test has been documented in #3042 |
Exactly. I just created eclipse-platform/eclipse.platform.releng.aggregator#3136 to warn in case as it's a reoccurring issue. |
DefaultRangeIndicator previously used
Image(Device, ImageData)
constructor to draw a grid to display the selected range.Previously, the grid was rendered using a 1×1 pixel checkerboard pattern (blue and white), which was mainly inteded to work at 100% zoom. However, at higher zoom levels (e.g., 150%, 200%), the visual intensity of the pattern becomes different, causing the grid to appear visually inconsistent across zooms.
Figures below uses Image(Device, ImageData)
200%
100%
The new implementation uses
Image(Device, ImageDataProvider)
adapts the grid's block size based on the zoom scale. Instead of always using 1×1 blocks, it calculates the block size by rounding the zoom factor:For zoom levels like 100%, 125%, etc., block size = 1 (no change).
For higher zoom levels like 150%, 200%, etc., block size = 2.
This means the grid will now use 2×2 rectangles for higher zooms, resulting in a visual appearance that better matches how the original 1×1 pattern looks on standard (100%) displays. This preserves visual consistency across different zoom levels and monitor scaling settings.
Figures below Uses Image(Device, ImageDataProvider)
100%
125%
150%
175%
200%
Contributes to vi-eclipse/Eclipse-Platform#199