dotMorten / WinUIEx

WinUI Extensions
https://dotmorten.github.io/WinUIEx
MIT License
602 stars 38 forks source link

Window Transparency #42

Closed Samuel12321 closed 11 months ago

Samuel12321 commented 2 years ago

Thanks for creating this incredibly useful project

A really useful feature missing from WinUI 3 is window background transparency. It would be very useful if you could add support for this. Perhaps similar to Backdrop.Mica & Backdrop.Acrylic --> Backdrop.Transparent

While not officially supported someone has managed to do it here, however it is ridiculously over complicated. Official support tracked on Productboard and Github but i doubt it will occur any time soon.

dotMorten commented 2 years ago

Mica and Acrylic is already there but you need to compile the library with the latest preview. Once 1.1 of the windows app sdk ships this will have it too

Samuel12321 commented 2 years ago

hi, thanks for the quick reply. I think you may have misinterpreted my question, i was asking about Transparency not Mica and Acrylic

I'm already using Backdrop.Mica, its quite useful.

dotMorten commented 2 years ago

Matching WinUI issue: https://github.com/microsoft/microsoft-ui-xaml/issues/1247

dotMorten commented 1 year ago

See https://github.com/cnbluefire/WinUI3TransparentBackground for an example of a transparent background.

dotMorten commented 11 months ago

Example / use case by @niels9001

https://github.com/dotMorten/WinUIEx/assets/1378165/0e56dc12-6e76-4725-9066-8b05ce935f74

dotMorten commented 11 months ago

Making some progress, and decided to abuse it :-)

https://github.com/dotMorten/WinUIEx/assets/1378165/63ab509c-1dc8-4a8a-8640-cc8f19f103e1

dotMorten commented 11 months ago

Snapshot of @niels9001's design with this new API: image

niels9001 commented 11 months ago

Snapshot of @niels9001's design with this new API: image

That's amazing 😁😁🚀🚀!

I was wondering - do acrylic brushes work with this as well?

EDIT: Just realizing you have that configured :-). Seems that actually blurring of the content below the window doesn't work - e.g. to get the Acrylic backdrop effect.

dotMorten commented 11 months ago

Yeah it's not as blurred as I had hoped

dotMorten commented 11 months ago

Now available in v2.3 release