-
Notifications
You must be signed in to change notification settings - Fork 113
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Question]: How to create a rounded window? #111
Comments
<Window ...>
|
I know only this way.. If you find a more correct solution, I will be glad to see it |
About one edge - you can set window size in this line: Rect="0,0,1080,600" |
The way I had done also behaved like this. |
I actually needed the same, and it seems that dev's last answer is sufficient, since setting the correct clipping size made my window's all corners rounded in win10. |
I didn't understand very well, I'm very new to this, can someone explain to me how to get all the corners rounded? mine was only 1, this difficulty of mine is also related because my English is not very good. |
@sourcechord it will be possible to create rounded corners if you use Windows.UI.Composition with WPF,and you can do much more than ordinary acrylic, you can animate the acrylic brush and also the flickering on resize will be removed too. Here is a sample demo that i created, i am working to create something similar to this library. This demo doesn't have rounded corners but it can be made. net5.0-windows10.0.19041.0.zip Although this acrylic looks good still i cant figure out a way to match the clipping of acrylic visual with window during maximize/restore/minimize animations. currently double clicking title bar area will use fade animation on acrylic while maximizing/restoring, to make this much it needed a lot of code. since .NET5 already have some WinRT stuff it made 50% easy. Try resizing the window, you can see the change in flickering issue |
@selastingeorge As far as I know it is impossible to make SetWindowCompositionAttribute and rounded corners to work together in WPF ;/ I would like to have solution that will work. |
here is what I'm doing:
But I cannot make its corners round.
How would I achieve that?
The text was updated successfully, but these errors were encountered: