WPF rectangle - round just top corners

后端 未结 4 1933

How can I have just the top corners rounded for a WPF rectangle?

I created a border and set the CornerRadius property and inside the border I\'ve added my

4条回答
  •  既然无缘
    2021-01-31 02:00

    The problem you've got is that the rectangle is "overflowing" the rounded corners of your border.

    A rectangle can't have individually rounded corners, so if you just put the background colour on the border and remove the rectangle:

    
    
    

    You'll get your desired effect.

提交回复
热议问题