Skip to content

[PerMonitorV2] Anchoring controls to Bottom/Right does not work property #6717

Description

@WolfgangHG

See attached .NET 6 sample: when moving the form from a screen at 100% to a screen at 125%, the controls anchored right/bottom are not rendered correct.
DpiSample.zip

This is at 100%:
100

This is the result when moving the form to the 125% screen:
125
The groupbox overlaps the button, and the margins to the right are larger than expected.

In the project file, I set this:
<ApplicationHighDpiMode>PerMonitorV2</ApplicationHighDpiMode>

And the form applies the OS default font (but removing this line does not change the result):
this.Font = SystemFonts.MessageBoxFont;

I saw that there are several other issues about "PerMonitorV2", but I can't say whether this problem is reported elsewhere.

Metadata

Metadata

Assignees

Labels

🪲 bugProduct bug (most likely)area-Anchor/ScalingHDPI issues around anchoring and dockingarea-HDPI-PMv2Issues related to high DPI PerMonitorV2 mode

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions