我画的是圆角矩形。问题--角落并不锐利。这个问题有什么解决方案吗?


这是我的绘图代码(Xamarin)
var thickness = (nfloat)Math.Min (Math.Min (_renderer.View.Thickness.Left, _renderer.View.Thickness.Right), Math.Max (_renderer.View.Thickness.Top, _renderer.View.Thickness.Bottom));
var path = UIBezierPath.FromRoundedRect (new CGRect(this.Bounds.X + thickness / 2, this.Bounds.Y + thickness / 2, this.Bounds.Width - thickness, this.Bounds.Height - thickness), (nfloat)_renderer.View.CornerRadius);
context.SetShouldAntialias (true);
context.SetStrokeColor (_renderer.View.Color.ToCGColor ());
context.SetFillColor (_renderer.View.BackgroundColor.ToCGColor ());
path.LineWidth = thickness;
path.Fill ();
path.Stroke ();发布于 2016-04-07 00:59:50
为什么不使用角半径呢?
顺便说一句,你必须检查你的图层的比例属性。必须将其设置为与主视图比例相同的值(即:视网膜设备上的2)。默认情况下,它是1。
https://stackoverflow.com/questions/36425233
复制相似问题