question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

RadioButton and CheckBox are not scaled well on the secondary monitor when application is in PerMonitorV2 mode

See original GitHub issue

.NET version

.NET 8.0.100-preview.6.23280.13

Did it work in .NET Framework?

Yes

Did it work in any of the earlier releases of .NET Core or .NET 5+?

Yes, it works in .NET 6.0/7.0/8.0.100-preview.5.23262.2, doesn’t work in 8.0.100-preview.5.23268.15.

Issue description

Testapp: Testapp.zip

https://github.com/dotnet/winforms/assets/86937911/6d4d445c-930f-4d03-a3ea-a439026670e4

100%DPI: image 100% primary monitor -> 300% secondary monitor image 300%DPI: image 300% primary monitor -> 100% secondary monitor image

Steps to reproduce

  1. Launch VS instance on 100% primary monitor.
  2. Add <ApplicationHighDpiMode>PerMonitorV2</ApplicationHighDpiMode> in csproj file.
  3. Close and reopen Solution.
  4. Add some radioButton and checkBox controls to form designer.
  5. Build and run the application.
  6. Move to 300% secondary monitor.

More Info:

  1. This issue does not happen at design time.
  2. This issue only repro on radiobutton and checkbox control.
  3. This issue also occurs when move from 300% primary monitor to 100% secondary monitor.

Issue Analytics

  • State:open
  • Created 4 months ago
  • Comments:9 (7 by maintainers)

github_iconTop GitHub Comments

1reaction
Philip-Wang01commented, Jun 6, 2023

@dreddy-work tested private binaries for GH PR: https://github.com/dotnet/winforms/pull/9214 on design time and run time for Multi-Monitors.

For runtime: Not fully fixed.

Issue: Anchor issue still repro in ListBox, CheckedListBox, TabControl and DateTimePicker control with non-default settings. And the controls in the tabcontrol are not scaled well when their anchor property both non-default setting. Test9200.zip

https://github.com/dotnet/winforms/assets/86937911/46c3f1f3-f22d-4129-b218-269c64e3af0e

For design time: one issue was found in PerMonitorV2 mode and hitting known issue: 5193 (all are not regressed from https://github.com/dotnet/winforms/commit/31fcf979bb2627373f320c5dd6a970f60b08dcbd).

Issue: When switching between the main and secondary monitors, the coordinate of the control with a non-default anchor setting will be shifted.

More Info:

  1. This issue also repro on radiobutton and checkbox with a default anchor setting.
  2. This issue was fixed in this testing on run time, but repro in design time.
  3. It’s a regression issue from .NET 8.0, but not regressed from https://github.com/dotnet/winforms/commit/31fcf979bb2627373f320c5dd6a970f60b08dcbd, not repro on .NET6.0/7.0.

Do we need to open a designer issue to track it?

https://github.com/dotnet/winforms/assets/86937911/cd690929-f1e8-49e3-82d1-179c2f805e57

1reaction
dreddy-workcommented, May 31, 2023

@Philip-Wang01, can you track to which commit caused it?

Nevermind. Its result form here: https://github.com/dotnet/winforms/commit/31fcf979bb2627373f320c5dd6a970f60b08dcbd

Read more comments on GitHub >

github_iconTop Results From Across the Web

Windows 11, PerMonitorV2 is NOT automatically scaling ...
The documentation claims this setting automatically scales non-client areas of my window. However it does not. On my 4K monitor the non-client ...
Read more >
UltraCheckBox, UltraRadioButtonList sized too small after ...
Hi, After upgrading from 18.2 to 19.1 all of the UltraCheckBoxes and Ultra radio button lists are very tiny. Everything else looks fine....
Read more >
How to scale HTA checkboxes and radio buttons to match ...
In HTAs, checkboxes and radio buttons can be scaled using the zoom property. Read the current AppliedDPI value from the registry, ...
Read more >
The Difference Between Radio Buttons and Checkboxes in ...
Need Help With DocuSign? BOOK A CALL with our DOCUSIGN EXPERTS: https://solusign.com/book ...
Read more >
Setting High DPI displays awareness with windows ...
Per Monitor v2 – This mode allows apps to receive notifications about scale changes at any time, not just during the startup.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found