I create a circle with a beautiful shadow with this code (I use MonoTouch.net for iPhone, Objective-C answers, of course, of course)
UIGraphics.PushContext (ctx);
SizeF shadowSize = new SizeF (0f, -3f);
ctx.SetRGBFillColor (194f / 255f, 212f / 255f, 238f / 255f, 1f);
ctx.SetAllowsAntialiasing (true);
ctx.SetShadowWithColor (shadowSize, 20, new CGColor (0.9f, 0.7f));
RectangleF area = new RectangleF (35f, 15f, 210f, 210f);
ctx.FillEllipseInRect (area);
UIGraphics.PopContext ();
Then I want to add an arc and lines to it. When I do this, colors and shadow, etc., seem to remain? How do I start fresh when drawing my UIView? (All this in the same UIView, I create an image)
source
share