How can I draw part of a circle in WPF?
-
Hi all, I want to draw part of a circle and am having difficultly being new to this WPF lark. I can draw a complete circle using an ellipse with equal width and height easily enough. But what I want to do is given a position, a radius and a start angle and a stop angle draw part of the circle. Have it start at 9 o'clock for instace and sweep clockwise to 5 o'clock. I can sort of do this using an arc, but this seems to be based on a start position and an end position and I'd have to resort to trigonometry in code to work these out. Any ideas?
-
Hi all, I want to draw part of a circle and am having difficultly being new to this WPF lark. I can draw a complete circle using an ellipse with equal width and height easily enough. But what I want to do is given a position, a radius and a start angle and a stop angle draw part of the circle. Have it start at 9 o'clock for instace and sweep clockwise to 5 o'clock. I can sort of do this using an arc, but this seems to be based on a start position and an end position and I'd have to resort to trigonometry in code to work these out. Any ideas?
I found this post on Google. It has many examples of what you are looking for. http://silverlight.net/forums/t/5132.aspx[ href="http://silverlight.net/forums/t/5132.aspx" target="_blank" title="New Window">^]
Cheers, Karl
» CodeProject 2008 MVP My Blog | Mole's Home Page | How To Create Screen Capture Videos For Your ArticlesJust a grain of sand on the worlds beaches.
-
I found this post on Google. It has many examples of what you are looking for. http://silverlight.net/forums/t/5132.aspx[ href="http://silverlight.net/forums/t/5132.aspx" target="_blank" title="New Window">^]
Cheers, Karl
» CodeProject 2008 MVP My Blog | Mole's Home Page | How To Create Screen Capture Videos For Your ArticlesJust a grain of sand on the worlds beaches.
Thanks for this Karl, I'll take a look.
Regards, Rob Philpott.