dotnet / dotnet/winforms

[Dark Mode] The Form title bar is white color when the MDIParent1 MainMenuStrip property is set to none

Open
#12,991 2 comments 1 reaction 1 assignee Claimed by @KlausLoeffelmann View on GitHub
area-DarkMode help wanted
Dominant language
C#
Stars
4.9k
Forks
1.1k
Avg merge
20h 23m
Merged PRs (30d)
103

Description

### .NET version

.NET 10.0.100-preview.2.25118.3

### Did it work in .NET Framework?

No

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

No, also repro in .NET 9.0 which it started to be supported.

### Issue description

The Form title bar is white color when the MDIParent1 MainMenuStrip property is set to none.

![Image](https://github.com/user-attachments/assets/9efb01bc-2d67-4cc1-a555-af1c9a49859f)

https://github.com/user-attachments/assets/f0a3ce9b-9f6f-45a0-a14f-52be1c43d662

### Steps to reproduce

1. Create a winforms .NET Core project.
2. Enable DarkMode by Application.SetColorMode(SystemColorMode.Dark) in Program.cs file.
3. Ctrl+Shift+A to add a MDI Parent Form.
4. Set MDIParent1 MainMenuStrip property to none.
5. Build and run MDIParent1.
6. Click File -> New, select Window0's Maximize button.

**More Info:**
1. This issue also repro when click MDI Parent button in WinformsControlTest app.

![Image](https://github.com/user-attachments/assets/698663a7-4b3f-4ee2-b109-cfd0b1ebe0d5)

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.