Skip to content

Conversation

@akoch-yatta
Copy link
Contributor

With commit cd8bb13 we adapted the calculation how to scale up fonts to fix the calculation for fonts used by the Printer. This introduced an issue if monitor-specific scaling is active and the primary monitor zoom is changed, because two different calculation were mixed now. This commit fixes this inconsistency.

How to reproduce

  • Activate the experimental monitor-specific scaling flag
  • Open a text editor
  • change the primary zoom

Some fonts will be scaled by the wrong factor
image

@HeikoKlare Can you have a look

@github-actions
Copy link
Contributor

github-actions bot commented Feb 11, 2025

Test Results

   502 files  ±0     502 suites  ±0   10m 57s ⏱️ + 3m 2s
 4 334 tests ±0   4 320 ✅ ±0   14 💤 ±0  0 ❌ ±0 
16 575 runs  ±0  16 466 ✅ ±0  109 💤 ±0  0 ❌ ±0 

Results for commit 4f96f76. ± Comparison against base commit df1c412.

♻️ This comment has been updated with latest results.

Copy link
Contributor

@HeikoKlare HeikoKlare left a comment

Choose a reason for hiding this comment

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

The change is sound and fixes the described issue. I've also tested with different scenarios (both without monitor-specific scaling with DPI awareness "PerMonitorV2" and "System", as well as with monitor-specific scaling, moving between differently scaled monitors and changing primary monitor zoom).

@fedejeanne can you please still have a second look?

With commit cd8bb13 we adapted the calcuation how to scale up fonts to
fix the calculation for fonts used by the Printer. This introduced an
issue if monitor-specific scaling is active and the primary monitor zoom
is changed, because two different calculation were mixed now. This commit
fixes this inconsistency.
This commit fixes the calculation of the height when scaling a font for
a different zoom when monitor-specific scaling is active
Copy link
Member

@fedejeanne fedejeanne left a comment

Choose a reason for hiding this comment

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

I can't judge the code itself but I can confirm that the error is fixed by this PR 👍

Thank you @akoch-yatta !

@HeikoKlare HeikoKlare merged commit 6b20ce2 into eclipse-platform:master Feb 11, 2025
14 checks passed
@HeikoKlare HeikoKlare deleted the fix-font-scaling-on-primary-monitor-change branch February 11, 2025 15:32
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.

3 participants