本文主要是介绍Xamarin 画圆,希望对大家解决编程问题提供一定的参考价值,需要的开发者们随着小编来一起学习吧!
Oval Drawing 画园
var ovalPath = UIBezierPath.FromOval(new CGRect(51.0f, 66.0f, 37.0f, 36.0f));
UIColor.Gray.SetFill();
ovalPath.Fill();
Star Drawing 画星星
UIBezierPath starPath = new UIBezierPath();
starPath.MoveTo(new CGPoint(108.0f, 68.25f));
starPath.AddLineTo(new CGPoint(113.38f, 76.35f));
starPath.AddLineTo(new CGPoint(122.5f, 79.13f));
starPath.AddLineTo(new CGPoint(116.7f, 86.92f));
starPath.AddLineTo(new CGPoint(116.96f, 96.74f));
starPath.AddLineTo(new CGPoint(108.0f, 93.45f));
starPath.AddLineTo(new CGPoint(99.04f, 96.74f));
starPath.AddLineTo(new CGPoint(99.3f, 86.92f));
starPath.AddLineTo(new CGPoint(93.5f, 79.13f));
starPath.AddLineTo(new CGPoint(102.62f, 76.35f));
starPath.ClosePath();
UIColor.Gray.SetFill();
starPath.Fill();
这篇关于Xamarin 画圆的文章就介绍到这儿,希望我们推荐的文章对编程师们有所帮助!