GraphicsExtensionsDrawRoundedRectangle Method (Graphics, Pen, Rectangle, Int32, Int32, Int32, Int32) | KGy SOFT Drawing Libraries Help |
Draws a rounded rectangle specified by a bounding Rectangle and four corner radius values.
Namespace: KGySoft.Drawing
Assembly: KGySoft.Drawing (in KGySoft.Drawing.dll) Version: 4.6.1
Syntax
public static void DrawRoundedRectangle( this Graphics graphics, Pen pen, Rectangle bounds, int radiusTopLeft, int radiusTopRight, int radiusBottomRight, int radiusBottomLeft )
<ExtensionAttribute> Public Shared Sub DrawRoundedRectangle ( graphics As Graphics, pen As Pen, bounds As Rectangle, radiusTopLeft As Integer, radiusTopRight As Integer, radiusBottomRight As Integer, radiusBottomLeft As Integer )
public: [ExtensionAttribute] static void DrawRoundedRectangle( Graphics^ graphics, Pen^ pen, Rectangle bounds, int radiusTopLeft, int radiusTopRight, int radiusBottomRight, int radiusBottomLeft )
[<ExtensionAttribute>] static member DrawRoundedRectangle : graphics : Graphics * pen : Pen * bounds : Rectangle * radiusTopLeft : int * radiusTopRight : int * radiusBottomRight : int * radiusBottomLeft : int -> unit
Parameters
- graphics
- Type: System.DrawingGraphics
The Graphics instance to draw on. - pen
- Type: System.DrawingPen
The Pen instance to be used for the drawing. - bounds
- Type: System.DrawingRectangle
A Rectangle that bounds the rounded rectangle. - radiusTopLeft
- Type: SystemInt32
Size of the top-left radius. - radiusTopRight
- Type: SystemInt32
Size of the top-right radius. - radiusBottomRight
- Type: SystemInt32
Size of the bottom-right radius. - radiusBottomLeft
- Type: SystemInt32
Size of the bottom-left radius.
Usage Note
In Visual Basic and C#, you can call this method as an instance method on any object of type Graphics. When you use instance method syntax to call this method, omit the first parameter. For more information, see Extension Methods (Visual Basic) or Extension Methods (C# Programming Guide).See Also