[]
Abstract base class that implements a drawing surface.
public abstract class GcGraphics : IDisposable
Public MustInherit Class GcGraphics
Implements IDisposable
Name | Description |
---|---|
GcGraphics() | Initializes a new instance of the GcGraphics class. |
Name | Description |
---|---|
BlendMode | Gets or sets the current blend mode. |
Disposed | Gets a value indicating whether this instance of GcGraphics has been disposed and cannot be used anymore. |
DrawTextAsPath | Gets or sets a value indicating if strings and TextLayout objects are rendered using the graphic primitives instead of the specialized text drawing services. |
FontCollection | Gets or sets a FontCollection used by MeasureString and DrawString methods. |
InterpolationMode | Gets or sets the sampling mode to use when drawing images with resizing. |
Resolution | Gets or sets the resolution of the current graphics (pixels per inch). |
SurfaceResolution | Gets the resolution of the underlying drawing surface (pixels per inch). |
Transform | Gets or sets the transformation matrix of the current graphics. |
Name | Description |
---|---|
CheckDisposed() | Checks whether object was disposed and throws an exception in this case. |
CreateClipRegion(IPath) | Creates a clip region from a graphics path. Use PushClip(IClipRegion) and PopClip(IClipRegion) to set/remove clipping. |
CreateClipRegion(RectangleF) | Creates a clip region from a rectangle. |
CreatePath() | Creates a graphics path. |
CreateRoundBordersPath(RectangleF, CornerRadius) | Creates IPath object representing round border. |
CreateTextLayout() | Creates an instance of TextLayout with the same resolution as that of the current graphics. This is the recommended way to create a TextLayout to use with a graphics. |
Dispose() | Releases all resources used by the current GcGraphics. |
Dispose(bool) | Disposes the current graphics. |
DrawEllipse(RectangleF, Pen) | Draws an ellipse using a specified pen. |
DrawEllipse(RectangleF, Color, float, DashStyle) | Draws an ellipse using a specified line color, width and style. If the value of lineStyle parameter is not Solid, the ellipse is drawn with a Pen having LineCap set to Square instead of Flat. |
DrawEllipse(RectangleF, Color, float, float[]) | Draws an ellipse using a specified line color, width and dash pattern. If the dashPattern array contains two or more items, the ellipse is drawn with a Pen having LineCap set to Square instead of Flat. |
DrawImage(IImage, RectangleF, RectangleF?, ImageAlign, out RectangleF[], float) | Draws an image using specified bounds, clipping and image alignment. In an output parameter, returns the array of actual image bounds. |
DrawImage(IImage, RectangleF, RectangleF?, ImageAlign, float) | Draws an image using specified bounds, clipping and image alignment. |
DrawLine(PointF, PointF, Pen) | Draws a line between two points, using the specified pen. |
DrawLine(PointF, PointF, Color, float, DashStyle) | Draws a line between two points, using a specified line color, width and style. If the value of lineStyle parameter is not Solid, the line is drawn with a Pen having LineCap set to Square instead of Flat. |
DrawLine(PointF, PointF, Color, float, float[]) | Draws a line between two points, using the specified line color, width and dash pattern. If the dashPattern array contains two or more items, the line is drawn with a Pen having LineCap set to Square instead of Flat. |
DrawLine(float, float, float, float, Pen) | Draws a line between two points, using the specified pen. |
DrawLine(float, float, float, float, Color, float, DashStyle) | Draws a line between two points, using a specified line color, width and style. If the value of lineStyle parameter is not Solid, the line is drawn with a Pen having LineCap set to Square instead of Flat. |
DrawLine(float, float, float, float, Color, float, float[]) | Draws a line between two points, using the specified line color, width and dash pattern. If the dashPattern array contains two or more items, the line is drawn with a Pen having LineCap set to Square instead of Flat. |
DrawLines(PointF[], Pen) | Draws a series of connected lines, using a specified pen. |
DrawLines(PointF[], Color, float, DashStyle) | Draws a series of connected lines, using a specified line color, width and style. If the value of lineStyle parameter is not Solid, the lines are drawn with a Pen having LineCap set to Square instead of Flat. |
DrawLines(PointF[], Color, float, float[]) | Draws a series of connected lines, using a specified line style. If the dashPattern array contains two or more items, the lines are drawn with a Pen having LineCap set to Square instead of Flat. |
DrawPath(IPath, Pen) | Draws a path using a specified pen. |
DrawPath(IPath, Color, float, DashStyle) | Draws a path using a specified line color, width and style. If the value of lineStyle parameter is not Solid, the path is drawn with a Pen having LineCap set to Square instead of Flat. |
DrawPath(IPath, Color, float, float[]) | Draws a path using a specified line color, width and dash pattern. If the dashPattern array contains two or more items, the path is drawn with a Pen having LineCap set to Square instead of Flat. |
DrawPolygon(Quadrilateral, Pen) | Draws a polygon specified by an array of points, using a specified pen. |
DrawPolygon(Quadrilateral, Color, float, DashStyle) | Draws a polygon specified by an array of points, using a specified line color, width and style. If the value of lineStyle parameter is not Solid, the polygon is drawn with a Pen having LineCap set to Square instead of Flat. |
DrawPolygon(Quadrilateral, Color, float, float[]) | Draws a polygon specified by an array of points, using a specified line color, width and dash pattern. If the dashPattern array contains two or more items, the polygon is drawn with a Pen having LineCap set to Square instead of Flat. |
DrawPolygon(PointF[], Pen) | Draws a polygon specified by an array of points, using a specified pen. |
DrawPolygon(PointF[], Color, float, DashStyle) | Draws a polygon specified by an array of points, using a specified line color, width and style. If the value of lineStyle parameter is not Solid, the polygon is drawn with a Pen having LineCap set to Square instead of Flat. |
DrawPolygon(PointF[], Color, float, float[]) | Draws a polygon specified by an array of points, using a specified line color, width and dash pattern. If the dashPattern array contains two or more items, the polygon is drawn with a Pen having LineCap set to Square instead of Flat. |
DrawRectangle(RectangleF, Pen) | Draws a rectangle using a specified pen. |
DrawRectangle(RectangleF, Color, float, DashStyle) | Draws a rectangle using a specified line color, width and style. If the value of lineStyle parameter is not Solid, the rectangle is drawn with a Pen having LineCap set to Square instead of Flat. |
DrawRectangle(RectangleF, Color, float, float[]) | Draws a rectangle using a specified line color, width and dash pattern. If the dashPattern array contains two or more items, the rectangle is drawn with a Pen having LineCap set to Square instead of Flat. |
DrawRotatedText(TextLayout, int, bool, RectangleF, RotatedTextAlignment) | Draws rotated text inside an unrotated rectangle. Note that the original Also note that the values of the following properties are ignored: MaxWidth, MaxHeight, FlowDirection, CanSkipFirstLineWithIndentation, ObjectRects, ParagraphAlignment, MarginLeft, MarginRight, MarginTop, MarginBottom, ColumnWidth, RowHeight. |
DrawRoundRect(RectangleF, Pen, Pen, Pen, Pen, CornerRadius) | Draws a rounded border defined by four Pen objects and CornerRadius structure. |
DrawRoundRect(RectangleF, float, Pen) | Draws a rounded rectangle using a specified pen. |
DrawRoundRect(RectangleF, float, Color, float, DashStyle) | Draws a rounded rectangle using a specified line color, width and style. If the value of lineStyle parameter is not Solid, the rounded rectangle is drawn with a Pen having LineCap set to Square instead of Flat. |
DrawRoundRect(RectangleF, float, Color, float, float[]) | Draws a rounded rectangle using a specified line color, width and dash pattern. If the dashPattern array contains two or more items, the rounded rectangle is drawn with a Pen having LineCap set to Square instead of Flat. |
DrawRoundRect(RectangleF, float, float, Pen) | Draws a rounded rectangle using a specified pen. |
DrawRoundRect(RectangleF, float, float, Color, float, DashStyle) | Draws a rounded rectangle using a specified line color, width and style. If the value of lineStyle parameter is not Solid, the rounded rectangle is drawn with a Pen having LineCap set to Square instead of Flat. |
DrawRoundRect(RectangleF, float, float, Color, float, float[]) | Draws a rounded rectangle using a specified line color, width and dash pattern. If the dashPattern array contains two or more items, the rounded rectangle is drawn with a Pen having LineCap set to Square instead of Flat. |
DrawSlantedText(TextLayout, int, bool, RectangleF, SlantedTextAlignment) | Draws rotated text inside a slanted rectangle. Note that the original Also note that the values of the following properties are ignored: MaxWidth, MaxHeight, FlowDirection, CanSkipFirstLineWithIndentation, ObjectRects, ParagraphAlignment, MarginLeft, MarginRight, MarginTop, MarginBottom, ColumnWidth, RowHeight. |
DrawString(string, Font, float, Color, PointF) | Draws a string using a specified attributes at a specified location. |
DrawString(string, TextFormat, PointF) | Draws a string using a specified TextFormat at a specified location. |
DrawString(string, TextFormat, RectangleF, TextAlignment, ParagraphAlignment, bool) | Draws a string using a specified TextFormat within a rectangle using a specified text alignment, paragraph alignment and word wrapping flag. |
DrawSvg(GcSvgDocument, PointF, float) | Draws a specified SVG document at a point specifying the position of the SVG viewport. To specify the position of the SVG content rather than viewport, see DrawSvgContent(GcSvgDocument, PointF, float). |
DrawSvg(GcSvgDocument, RectangleF, float) | Draws a specified SVG document, resizing its viewport to fit into a specified rectangle. To draw just the content of the SVG ignoring viewport position, see DrawSvgContent(GcSvgDocument, RectangleF, float). |
DrawSvgContent(GcSvgDocument, PointF, float) | Draws the content of a specified SVG document at a point specifying the top-left corner of the SVG content. To specify the position of the SVG viewport rather than content, see DrawSvg(GcSvgDocument, PointF, float). |
DrawSvgContent(GcSvgDocument, RectangleF, float) | Draws the content of a specified SVG document, resizing the content to fit into a specified rectangle. To draw the SVG resizing its viewport rather than just the content, see DrawSvg(GcSvgDocument, RectangleF, float). |
DrawTabLeader(Font, TabStopLeader, Color, bool, float, float, float, float) | For internal use only. |
DrawTextLayout(TextLayout, PointF) | Draws a TextLayout at a specified location. If any part of the text does not fit in the layout bounds, it is truncated. |
FillEllipse(RectangleF, Brush, RectangleF?, Matrix3x2?) | Fills an ellipse with a specified brush. |
FillEllipse(RectangleF, Color) | Fills an ellipse with a specified solid color. |
FillPath(IPath, Brush, RectangleF?, Matrix3x2?) | Fills a path using a specified brush. |
FillPath(IPath, Color) | Fills a path using a specified color. |
FillPolygon(Quadrilateral, Brush, RectangleF?, Matrix3x2?) | Fills a polygon specified by an array of points, using a specified brush and fill mode. |
FillPolygon(Quadrilateral, Color) | Fills a polygon specified by an array of points, using a specified color and fill mode. |
FillPolygon(PointF[], Brush, FillMode, RectangleF?, Matrix3x2?) | Fills a polygon specified by an array of points, using a specified brush and fill mode. |
FillPolygon(PointF[], Color, FillMode) | Fills a polygon specified by an array of points, using a specified color and fill mode. |
FillRectangle(RectangleF, Brush, RectangleF?, Matrix3x2?) | Fills a rectangle using a specified brush. |
FillRectangle(RectangleF, Color) | Fills a rectangle with a solid color. |
FillRoundRect(RectangleF, float, Brush, RectangleF?, Matrix3x2?) | Fills a rounded rectangle using a specified brush. |
FillRoundRect(RectangleF, float, Color) | Fills a rounded rectangle witih a solid color. |
FillRoundRect(RectangleF, float, float, Brush, RectangleF?, Matrix3x2?) | Fills a rounded rectangle using a specified brush. |
FillRoundRect(RectangleF, float, float, Color) | Fills a rounded rectangle witih a solid color. |
GetBlendMode() | For internal use. Returns the current blend mode. |
GetImageSize(IImage) | Returns the size of an image in pixels using the resolution of the current graphics. |
GetInterpolationMode() | For internal use. Returns the current interpolation mode. |
InternalCreateClipRegion(IPath) | For internal use. |
InternalCreateClipRegion(RectangleF) | For internal use. |
InternalCreatePath() | For internal use. |
InternalDrawEllipse(RectangleF, Pen) | For internal use. |
InternalDrawImage(RectangleF, IImage, float) | For internal use. |
InternalDrawLine(PointF, PointF, Pen) | For internal use. |
InternalDrawLines(PointF[], Pen) | For internal use. |
InternalDrawPath(IPath, Pen) | For internal use. |
InternalDrawPolygon(PointF[], Pen) | For internal use. |
InternalDrawRectangle(RectangleF, Pen) | For internal use. |
InternalDrawRoundRect(RectangleF, float, float, Pen) | For internal use. |
InternalDrawTextLayout(TextLayout, PointF) | For internal use. |
InternalDrawTextLayoutAsPath(TextLayout, PointF) | Draws a TextLayout at a specified location using graphic primitives. |
InternalDrawTextLineAsPath(TextLayout, float, TextLine, float, float, RectangleF, List<SU>, List<SU>) | Draws a TextLine within a TextLayout at the specified location using graphic primitives. |
InternalDrawTextLineBackground(TextLayout, float, TextLine, float, float) | Fills a background of the text line. |
InternalFillEllipse(RectangleF, Brush, RectangleF?, Matrix3x2?) | For internal use. |
InternalFillEllipse(RectangleF, Color) | For internal use. |
InternalFillPath(IPath, Brush, RectangleF?, Matrix3x2?) | For internal use. |
InternalFillPath(IPath, Color) | For internal use. |
InternalFillPolygon(PointF[], Brush, FillMode, RectangleF?, Matrix3x2?) | For internal use. |
InternalFillPolygon(PointF[], Color, FillMode) | For internal use. |
InternalFillRectangle(RectangleF, Brush, RectangleF?, Matrix3x2?) | For internal use. |
InternalFillRectangle(RectangleF, Color) | For internal use. |
InternalFillRoundRect(RectangleF, float, float, Brush, RectangleF?, Matrix3x2?) | For internal use. |
InternalFillRoundRect(RectangleF, float, float, Color) | For internal use. |
InternalRemoveClip(IClipRegion) | For internal use. |
InternalSetClip(IClipRegion) | For internal use. |
IsBlendModeSupported(BlendMode) | Indicates whether this graphics implementation supports a specified blend mode. |
IsInterpolationModeSupported(InterpolationMode) | Indicates whether this graphics implementation supports a specified interpolation mode. |
MeasureImage(IImage, RectangleF, ImageAlign) | Measures how an image will be drawn using the specified bounds and image alignment. |
MeasureRotatedText(TextLayout, int, bool, RectangleF, RotatedTextAlignment) | Calculates the bounds of rotated text inside an unrotated rectangle. Note that the original Also note that the values of the following properties are ignored: MaxWidth, MaxHeight, FlowDirection, CanSkipFirstLineWithIndentation, ObjectRects, ParagraphAlignment, MarginLeft, MarginRight, MarginTop, MarginBottom, ColumnWidth, RowHeight. |
MeasureString(string, Font, float, float?) | Measures a string using a specified font, font size and layout width. |
MeasureString(string, TextFormat, SizeF, TextSplitOptions, out int) | Measures a string using a specified TextFormat, available layout size and TextSplitOptions. Also calculates and returns in an output parameter the number of chars that fit into the specified size. |
MeasureString(string, TextFormat, SizeF, out int) | Measures a string using a specified TextFormat, available layout size and default split options (see TextSplitOptions). Also calculates and returns in an output parameter the number of chars that fit into the specified size. |
MeasureString(string, TextFormat, float?) | Measures a string using a specified TextFormat. |
MeasureStringWithTrailingWhitespace(string, Font, float, float?) | Measures a string using a specified font, font size and layout width, taking into account the trailing whitespace at the end of each line. |
MeasureStringWithTrailingWhitespace(string, TextFormat, float?) | Measures a string using a specified TextFormat, taking into account the trailing whitespace at the end of each line. |
MeasureSvg(GcSvgDocument, PointF) | Calculates the content bounds of a specified SVG document when its viewport is drawn at a specified point. |
PopClip(IClipRegion) | Removes the last clip. After this method is called, the clip is no longer applied to subsequent drawing operations. |
PopTransparencyLayer() | Stops redirecting drawing operations to the transparency layer that was created by the last PushTransparencyLayer(RectangleF?, float) call. |
PushClip(IClipRegion) | Specifies a clipping region to which all subsequent drawing operations are clipped. |
PushClip(IPath) | Specifies a path to which all subsequent drawing operations are clipped. The GcGraphics.Clip object returned by this method implements IDisposable, so this method can be used with the 'using' pattern:
in which case the clipping region will be removed when the returned object is disposed. |
PushClip(RectangleF) | Specifies a rectangle to which all subsequent drawing operations are clipped. The GcGraphics.Clip object returned by this method implements IDisposable, so this method can be used with the 'using' pattern:
in which case the clipping region will be removed when the returned object is disposed. |
PushClip(RectangleF, RectangleF) | Specifies a rectangle to which all subsequent drawing operations are clipped.
Clipping is applied only if The GcGraphics.Clip object returned by this method implements IDisposable, so this method can be used with the 'using' pattern:
in which case the clipping region will be removed when the returned object is disposed. |
PushClip(RectangleF?) | Specifies a rectangle to which all subsequent drawing operations are clipped. The GcGraphics.Clip object returned by this method implements IDisposable, so this method can be used with the 'using' pattern:
in which case the clipping region will be removed when the returned object is disposed. |
PushTransparencyLayer(RectangleF?, float) | Adds a transparency layer to the current graphics. That layer receives all subsequent drawing operations until PopTransparencyLayer() is called. |
SetBlendMode(BlendMode) | For internal use. Sets the current blend mode. |
SetInterpolationMode(InterpolationMode) | For internal use. Sets the current interpolation mode. |