public static void DrawBorder(SKCanvas canvas, RectangleF dirtyRect, SkiaControl control, View view) { var shape = control.GetBorder(); if (shape == null) { return; } control?.DrawBorder(canvas, shape, dirtyRect); }
public static void ClipCanvas(SKCanvas canvas, RectangleF dirtyRect, SkiaControl control, View view) { var border = control?.GetBorder(); var clipShape = control?.GetClipShape() ?? border; if (clipShape != null) { canvas.ClipPath(clipShape.PathForBounds(dirtyRect).ToSKPath()); } }