ramensoftware / windhawk-mods

The official collection of Windhawk mods
219 stars 43 forks source link

[Windows 11 Taskbar Styler] Acrylic background doesn't work with multiple monitors #742

Open MuscularPuky opened 2 weeks ago

MuscularPuky commented 2 weeks ago

sry for too late the issue but I was going to busy until Sep

in v1.3.3, there's acrylic background styling bug with multi monitor. v1.3.4 is the hoxfix for that multi monitor bug but it made the bug worse.

v1.3.3, only secondary taskbar lost background but now v1.3.4, all taskbars lost background. when I reload mod, the taskbars have default background in initial 0.1~0.2s but it gradually faded soon.

on single monitor, the acrylic background works well.

m417z commented 1 week ago

For some reason, setting an acrylic background for both taskbars doesn't work. Setting only of them, either one, works.

Here you can see setting both with a delay:

https://github.com/ramensoftware/windhawk-mods/assets/4129781/ef17eef0-233f-489f-9346-c97be409d713

MuscularPuky commented 1 week ago

For some reason, setting an acrylic background for both taskbars doesn't work. Setting only of them, either one, works.

Here you can see setting both with a delay:

ZFfxKfNQOO.mp4

THX for your hint I did it #29 it's not code issue. maybe kind of XAML limitation. but I don't know why it cause anyways we can bypass this problem through add more parameter, and still solvable—without bypass—by edit the mod code—to use other hook method very teresting parameters 🤔 I'll studying more about these

m417z commented 1 week ago

Edit

This is incorrect, see the next comment for a clarification.

Original comment

The following seems to work (suggested by @ahmed605):

I can make the mod to enable Host Backdrop for the taskbar, but I'm not sure what the implications are, especially since most users probably don't use a custom acrylic background.

m417z commented 1 week ago

My previous message is incorrect. I was about to try ACCENT_ENABLE_HOSTBACKDROP, but tried ACCENT_ENABLE_BLURBEHIND instead. ACCENT_ENABLE_HOSTBACKDROP doesn't seem to work.

What works is just setting ACCENT_ENABLE_BLURBEHIND with SetWindowCompositionAttribute (BackgroundSource="HostBackdrop" isn't necessary), but it also results in a slightly different effect.

MuscularPuky commented 1 week ago

I tried HostBackdrop in previous version but was no luck as I remember. ah—I don't remeber clearly I was racking my brain for implement acrylic back then if it shouldve been worked Ive typed wrong xaml syntax back then

Yes. Windows has 2 or 3 acrylic method based on its version but I haven't met the blur method on UWP. if it can use itll be maybe BackdropBlurBrush?? I can't sure... I'm not versed in UWP