dotnet / winforms

Windows Forms is a .NET UI framework for building Windows desktop applications.
MIT License
4.28k stars 954 forks source link

[Accessibility] HC themes: toolStripMenuItem is highlighted in unfocused state when its check property is enabled #11550

Open Philip-Wang01 opened 1 week ago

Philip-Wang01 commented 1 week ago

.NET version

.NET 9.0 SDK build: 9.0.100-preview.6.24318.4

Did it work in .NET Framework?

Yes

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

Yes, this is a regression issue. Not reproduced on NET 8.0 and earlier versions of NET 9.0 (https://github.com/dotnet/winforms/issues/9166).

Issue description

toolStripMenuItem is highlighted in unfocused state when its check property is enabled, this causes the color contrast of indeterminate state icon for toolStripMenuItem is less than 3:1. image

Steps to reproduce

Use following test sample application: WinFormsApp24.zip

LeafShi1 commented 1 week ago

This issue caused by PR #9933, we can consider unhighlighting the ToolStripMenuItem when it is in the drop-down menu because there is a Checked icon image