Skip to content

CheckBox and RadioButton ignore BackColor and ForeColor when Appearance=Button in Dark Mode #14866

Description

@Amy-Li03

.NET version

.NET 11.0.100-rc.1.26404.113

Did it work in .NET Framework?

Not tested/verified

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

No, this issue also repro on .NET10

Issue description

When CheckBox.Appearance or RadioButton.Appearance is set to Appearance.Button,
custom BackColor and ForeColor values are ignored in Dark Mode.
The controls are rendered using the system button theme colors instead of the user-specified colors.

Regular Button controls honor the same color settings correctly.

Image

Steps to reproduce

  1. Create a WinForms .NET application with RadioButton/CheckBox control
  2. Set RadioButton/CheckBox's Appearanceis Button
  3. Custom RadioButton/CheckBox's BackColor and ForeColor
  4. Enable DarkMode by Application.SetColorMode(SystemColorMode.Dark) in Program.cs file
  5. Run the application to observe

Metadata

Metadata

Assignees

Labels

area-DarkModeIssues relating to Dark Mode featureuntriagedThe team needs to look at this issue in the next triage

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions