public static CGLineCap ToCGLineCap(this UGCapStyle capStyle) { switch (capStyle) { case UGCapStyle.Flat: return(CGLineCap.Butt); case UGCapStyle.Square: return(CGLineCap.Square); case UGCapStyle.Round: return(CGLineCap.Round); case UGCapStyle.Triangle: default: throw new NotSupportedException(); } }
public static DashCap ToGDIDashCap(this UGCapStyle capStyle) { switch (capStyle) { case UGCapStyle.Flat: case UGCapStyle.Square: return(DashCap.Flat); case UGCapStyle.Round: return(DashCap.Round); case UGCapStyle.Triangle: return(DashCap.Triangle); default: throw new NotSupportedException(); } }
public static CanvasCapStyle ToWin2DLineCap(this UGCapStyle capStyle) { switch (capStyle) { case UGCapStyle.Flat: return(CanvasCapStyle.Flat); case UGCapStyle.Square: return(CanvasCapStyle.Square); case UGCapStyle.Round: return(CanvasCapStyle.Round); case UGCapStyle.Triangle: return(CanvasCapStyle.Triangle); default: throw new NotSupportedException(); } }