public static void FillRoundedRectangle(this ID2D1RenderTarget context, D2D1_ROUNDED_RECT roundedRect, ID2D1Brush brush) { if (context == null) { throw new ArgumentNullException(nameof(context)); } if (brush == null) { throw new ArgumentNullException(nameof(brush)); } context.FillRoundedRectangle(ref roundedRect, brush); }
public static void DrawRoundedRectangle(this ID2D1RenderTarget context, D2D1_ROUNDED_RECT roundedRect, ID2D1Brush brush, float strokeWidth, ID2D1StrokeStyle strokeStyle = null) { if (context == null) { throw new ArgumentNullException(nameof(context)); } if (brush == null) { throw new ArgumentNullException(nameof(brush)); } context.DrawRoundedRectangle(ref roundedRect, brush, strokeWidth, strokeStyle); }
public static void FillRoundedRectangle(this IComObject <ID2D1RenderTarget> context, D2D1_ROUNDED_RECT roundedRect, IComObject <ID2D1Brush> brush) => FillRoundedRectangle(context?.Object, roundedRect, brush?.Object);
public static void DrawRoundedRectangle(this IComObject <ID2D1RenderTarget> context, D2D1_ROUNDED_RECT roundedRect, IComObject <ID2D1Brush> brush, float strokeWidth, IComObject <ID2D1StrokeStyle> strokeStyle = null) => DrawRoundedRectangle(context?.Object, roundedRect, brush?.Object, strokeWidth, strokeStyle?.Object);
public static IComObject <ID2D1RoundedRectangleGeometry> CreateRoundedRectangleGeometry(this ID2D1Factory factory, D2D1_ROUNDED_RECT rectangle) { if (factory == null) { throw new ArgumentNullException(nameof(factory)); } factory.CreateRoundedRectangleGeometry(ref rectangle, out var geometry).ThrowOnError(); return(new ComObject <ID2D1RoundedRectangleGeometry>(geometry)); }
public static IComObject <ID2D1RoundedRectangleGeometry> CreateRoundedRectangleGeometry(this IComObject <ID2D1Factory> factory, D2D1_ROUNDED_RECT rectangle) => CreateRoundedRectangleGeometry(factory?.Object, rectangle);