Skip to content

[Win32] Wrong font size is selected when opening FontDialog (monitor-specific scaling) #2866

@wahlbrink

Description

@wahlbrink

When opening a FontDialog with an initial FontData set on a monitor with scaling factor != 1, the size initially selected in the dialog is the font size multiplied by the scaling factor.

For example: when opening the FontDialog on a monitor with zoom 200% and an initial font with size 10, the font size selected in the dialog is 20.

To Reproduce

  • Open the font dialog from the "Colors and Fonts" preference page of the Eclipse IDE .

Environment:

  1. Select the platform(s) on which the behavior is seen:
    • All OS
    • Windows
    • Linux
    • macOS
  1. Additional OS info (e.g. OS version, Linux Desktop, etc)
    Windows 11

  2. JRE/JDK version
    JDK 21 (Adoptium)

Version since
tested with: Eclipse 4.38 Build id: I20251201-0920

but the bug was already present in the previous version.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions