microsoft / microsoft/microsoft-ui-xaml

AppWindowTitleBar.ExtendsContentIntoTitleBar is buggy when show accent color on titlebar is enabled

Open
#11,460 0 comments 1 reaction 0 assignees View on GitHub
area-AppWindow area-TitleBar bug team-Core
Dominant language
C++
Stars
8.4k
Forks
942
Avg merge
2d 7h
Merged PRs (30d)
105

Description

### Describe the bug

When show accent color on titlebar is enabled in system settings and we use `AppWindowTitleBar.ExtendsContentIntoTitleBar = true`, the caption button area shows the accent color when the window is inactive, which looks buggy. More importantly, it does not reset the color when toggling the settings to disable.

Image

It should behaves the same as `Window.ExtendsContentIntoTitleBar`, which does not have the same issue. (But also having its own issue nonetheless).

**The bug reproduces on both windows 10 and 11!**

### Why is this important?

It should be consistent with all other apps using the standard win32 titlebar.

### Steps to reproduce the bug

1. Enable show accent color on titlebar in system settings.
2. Go to winui3 gallery >> AppWindowTitleBar page, open the second sample "Extending content into the AppWindowTitleBar" area
3. Click elsewhere to make the window inactive, observe the caption button area showing the accent color as background
4. Disable show accent color on titlebar in system settings
5. Observe the caption button area is still showing the background

### Actual behavior

_No response_

### Expected behavior

_No response_

### Screenshots

_No response_

### NuGet package version

2.2

### Windows version

_No response_

### Additional context

_No response_

Contributor guide

Open the contributing guide

Research direction

Start with the WinUI Gallery AppWindowTitleBar page and reproduce the second sample, “Extending content into the AppWindowTitleBar,” using the listed system-setting steps. Compare its behavior with Window.ExtendsContentIntoTitleBar while toggling the accent-color setting and window activation; done means the caption button area no longer retains the accent color and matches the expected title-bar behavior.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp
Domain
desktop
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
55/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.