Avalonia: Native window title bar is visible for full screen top most app
I have a case where app needs to be full screen, just like a video game, without min, max and close buttons, no resizing, no chrome. Following styles are applied:
<Setter Property="WindowState" Value="FullScreen"/>
<Setter Property="CanResize" Value="False"/>
<Setter Property="ExtendClientAreaToDecorationsHint" Value="True"/>
<Setter Property="ExtendClientAreaChromeHints" Value="NoChrome"/>
<Setter Property="ExtendClientAreaTitleBarHeightHint" Value="-1"/>
<Setter Property="Background" Value="Black"/>
This gives me the results that I want. However:
If I click outside of my window, for example if I have two monitors or if I press a "Win" key on Windows machine, my app gets what looks like a "default" chrome, very ugly, something that looks like Win7 era at best:
Is there a way to preserve no title bar functionality even if window is not active, disabled etc...
This can be reproduced with Avalonia starting from x.x.13 to the latest version and LibVLCSharp 3.6.6
Minimal project and steps to reproduce
Create Avalonia app -> Apply styling to the window -> on opened event of the main window play video -> after video is done click on any surface or press "Win" key during or after video ends
What is the current bug behavior?
Title bar pops up when clicking outside of the window (second monitor) or pressing "Win" key on keyboard
What is the expected correct behavior?
It should not render ugly titlebar
Does it work on other plaforms? Does it work with the official VLC apps?
Created the D3D11 device type 1 level b100.
failed to read the 2 Display Adapter registry key (2)
supports colorspace RGB Rec.2020 gamma:2084 range:FULL
different 1 device p vs p
supports colorspace RGB Rec.2020 gamma:22 range:STUDIO
supports colorspace RGB Rec.2020 gamma:2084 range:STUDIO
Using pixel format VA_NV12 for chroma DX11
supports colorspace RGB Rec.709 gamma:22 range:FULL
supports colorspace RGB Rec.709 gamma:22 range:STUDIO
Output max luminance: 270.0, colorspace RGB Rec.709 gamma:22 range:FULL, bits per pixel 8
can't find adapter in registry
supports colorspace RGB Rec.2020 gamma:22 range:FULL
different 0 device p vs P
using colorspace RGB Rec.709 gamma:22 range:FULL
VoutDisplayEvent 'resize' 1938x1127
using GPU render fence
Direct3D11 resources created
Direct3D11 Open Succeeded
Using DWrite backend
DWrite_ParseFamily(): using font at index 2 with weight 400 for bold: 0, italic: 1
using text renderer module "freetype"
Detected size change 1x1
looking for hw decoder module matching "any": 2 candidates
different 0 device p vs P
different 1 device p vs p
failed to read the 2 Display Adapter registry key (2) ```
### Environment
<!-- Please complete the following information. -->
- OS: <!-- Windows 10 -->
- Version <!-- 21H2 19044.1766 -->
- Device: <!-- Thinkpad P52 -->
- LibVLC version and architecture <!-- VideoLAN.LibVLC.Windows 3.0.16 -->
- LibVLCSharp version <!-- 3.6.6 -->