How do I make the TitleBar transparent? #8295
-
I'm trying to mimic what I see in the WinUI Gallery and Clock apps, which is the titlebar showing in all DisplayModes and transparent. I got to make it to kind of work by copying some code from the WinUI Gallery repo, but the TitleBar does not become transparent. Here's the MainPage.xaml file In App.xaml.cs I have a static property Please ignore the MainWindow files in the repo from the links I put here. It's for another issue. I can make the TitleBar transparent if I set the AppWindow.ExtendsContentIntoTitleBar to true, but then I don't know how to put anything in it. Here are some screenshots of what I'm trying to accomplish Any help is appreciated. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 3 replies
-
please add this line in app.xaml to the key ResourceDictionary: On your xaml for the page set Background to Transparent. |
Beta Was this translation helpful? Give feedback.
Hi @eduardobragaxz
to achieve this result:
please add this line in app.xaml to the key ResourceDictionary:
<SolidColorBrush x:Key="WindowCaptionBackground">Transparent</SolidColorBrush>
On your xaml for the page set Background to Transparent.