Silverlight: Creating a round button template
Posted
by Jeremy
on Stack Overflow
See other posts from Stack Overflow
or by Jeremy
Published on 2008-12-18T17:28:49Z
Indexed on
2010/06/12
17:02 UTC
Read the original article
Hit count: 246
Silverlight
|xaml
I decided to try making a circular button, so using expression blend, I dropped a button control on my xaml. I then created a template from it by choosing "Edit Control Parts (Template)" -> "Edit a Copy". I am trying to design it so that the left and right sides of the button were always perfect semi circles, so that no matter how tall or wide the button grew, the corner radius would max out at either half the width or half the length of the button, depending on which was smaller. That way, if the button was stretched tall, the top and buttom would be perfect half circles, and if the button was stretched wide, the left and right would be perfect half circles. Is it possible to do this?
© Stack Overflow or respective owner