CheckBox/RadioButton glyph disappears when Image is set in VisualStylesMode.Net11

Aperta
#15,267 0 commenti 0 reazioni 1 assegnatario Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

@SimonZhao888 ci sta già lavorando.

Dal 14/10/2026.

  • #15268 di @SimonZhao888 — aperta

Valutazione

Questa issue non è ancora stata valutata.

Descrizione

NewApi-Net11 untriaged
.NET version

11.0.0-rtm.26480.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+?

New feature of https://github.com/dotnet/winforms/pull/14792

Issue description

When VisualStylesMode is set to Net11, setting the Image property on a CheckBox or RadioButton causes the checkbox/radioButton glyph to disappear. The image and text are rendered, but the checkbox/radioButton indicator on the left is no longer visible.

VisualStylesMode: Net11

Image

When VisualStylesMode is set to Classic, it works well.
VisualStylesMode: Classic

Image
Steps to reproduce
  1. Create a WinForms application targeting .NET 11.
  2. Set VisualStylesMode to Net11.
  3. Add a RadioButton and a CheckBox to the form.
  4. Set the AutoSize property as False.
  5. Set the Image property for both controls.
  6. Run the application.
  7. Observe the RadioButton and CheckBox.
Lingua principale
C#
Stelle
4.9k
Fork
1.1k
Merge medio
18h 51m
PR unite (30g)
69

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di dotnet/winforms

Tutte le issue di dotnet/winforms

Issue simili

Altre issue su C#

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.