Table of Contents

Interface IPainter

Namespace
Alternet.Common
Assembly
Alternet.Common.v9.dll

Encapsulates a drawing surface, providing properties and methods used to draw text and graphic primitives.

public interface IPainter : IDisposable

Properties

BackColor

When implemented by a class, gets or sets background color of the device context currently associated with the IPainter.

Font

When implemented by a class, gets or sets font of the device context currently associated with the IPainter.

FontHeight

When implemented by a class, represents height of the font of the device context currently associated with the IPainter.

FontStyle

When implemented by a class, gets or sets font style of the device context currently associated with the IPainter.

FontWidth

When implemented by a class, represents width of the font of the device context currently associated with the IPainter.

ForeColor

When implemented by a class, gets or sets foreground color of the device context currently associated with the IPainter.

Graphics

When implemented by a class, represents Graphics object used to paint.

IsMonoSpaced

When implemented by a class, represents a value indicating whether font of the device context currently associated with this IPainter is monospaced, meaning that all characters drawn with this font have the same width.

LineHeight

When implemented by a class, represents height of the individual lines.

LineSpace

When implemented by a class, Represents additional height added to the height of the font.

Opaque

When implemented by a class, gets or sets a boolean value indicating that background is filled with the current background color before the text is drawn.

StringFormat

When implemented by a class, encapsulates text layout information and display manipulations for this IPainter.

TextColor

When implemented by a class, gets or sets text color of the device context currently associated with the IPainter.

Transformation

When implemented by a class gets the world transformation for Graphics property.

UseDrawText

When implemented by a class, indicates whether painter should use DrawText method rather then ExtTextOut to paint text.

Methods

BeginPaint(Graphics)

When implemented by a class, prepares the IPainter to paint. Associates new device context from given Graphics object to IPainter and preserves IPainter properties. EndPaint()

CharWidth(char, int)

When implemented by a class, returns width of the given number of specified character.

CharWidth(char, int, out int, bool)

When implemented by a class, returns width of the such number of the specified characters fitting into the given Width.

Clear()

When implemented by a class, resets all IPainter properties to the initial state.

DrawDotLine(int, int, int, int, Color, Color, int)

When implemented by a class, draws a dotted line from the given start position up to the specified end point.

DrawEdge(ref Rectangle, Border3DStyle, Border3DSide)

When implemented by a class, draws one or more edges of rectangle.

DrawEdge(ref Rectangle, Border3DStyle, Border3DSide, int)

When implemented by a class, draws one or more edges of rectangle.

DrawFocusRect(Rectangle, Color)

When implemented by a class, draws a border around the specified rectangle using current BackColor.

DrawFocusRect(int, int, int, int, Color)

When implemented by a class, draws a border around the specified rectangle using dot pattern.

DrawFrameRect(Rectangle, Color, int)

When implemented by a class, draws a border around the specified rectangle using current BackColor.

DrawImage(Image, Rectangle)

When implemented by a class, draws image in the specified rectangular area.

DrawImage(ImageList, int, Rectangle)

When implemented by a class, draws specified image in the specified rectangular area.

DrawImage(ImageList, int, Rectangle, int, int, int, int, GraphicsUnit, ImageAttributes)

When implemented by a class, draws specified image in the specified rectangular area.

DrawLine(int, int, int, int)

When implemented by a class, draws a line from the given start position up to, but not including, the specified end point.

DrawLine(int, int, int, int, Color, int, DashStyle)

When implemented by a class, draws a line from the given start position up to, but not including, the specified end point.

DrawPolygon(Point[], Color)

When implemented by a class, draws a polygon defined by an array of Point structures.

DrawRectangle(Rectangle)

When implemented by a class, draws a border around the specified rectangle using current BackColor.

DrawRectangle(int, int, int, int)

When implemented by a class, draws a border around the specified rectangle using dot pattern.

DrawRoundRectangle(int, int, int, int, int, int)

When implemented by a class, draws a rectangle with rounded corners. The rectangle is outlined by using the current pen.

DrawText(string, int, Rectangle)

When implemented by a class, draws text in the specified rectangle using current values of TextColor and BackColor.

DrawThemeBackground(IntPtr, int, int, Rectangle)

When implemented by a class, draws the background image defined by the visual style for the specified control part.

DrawWave(Rectangle, Color)

When implemented by a class, draws waved line in the specified rectangular area.

EndPaint()

When implemented by a class, marks the end of painting. Releases device context associated with this IPainter and restores saved IPainter properties. BeginPaint(Graphics)

EndTransform()

When implemented by a class, sets default two-dimensional linear transformation for the specified device context.

ExcludeClipRect(Rectangle)

When implemented by a class, creates a new clipping region that consists of the existing clipping region minus the specified rectangle.

ExcludeClipRect(int, int, int, int)

When implemented by a class, creates a new clipping region that consists of the existing clipping region minus the specified rectangle.

FillGradient(Rectangle, Color, Color, Point, Point)

When implemented by a class, fills the given rectangle with color that smoothly fades from one side to the other.

FillGradient(int, int, int, int, Color, Color, Point, Point)

When implemented by a class, fills the given rectangle with color that smoothly fades from one side to the other.

FillPolygon(Color, Point[])

When implemented by a class, fills the interior of a polygon defined by an array of points specified by Point structures.

FillRectangle(Color, Rectangle)

When implemented by a class, fills the given rectangle by using specified color.

FillRectangle(Color, int, int, int, int)

When implemented by a class, fills the given rectangle by using specified color.

FillRectangle(Rectangle)

When implemented by a class, fills the given rectangle by using the current brush.

FillRectangle(int, int, int, int)

When implemented by a class, fills the given rectangular area by using the current brush.

FillRoundRectangle(int, int, int, int, int, int)

When implemented by a class, fills a rectangle with rounded corners. The rectangle is outlined by using the current pen and filled by using the current brush.

IntersectClipRect(Rectangle)

When implemented by a class, creates a new clipping region from the intersection of the current clipping region and the specified rectangle.

IntersectClipRect(int, int, int, int)

When implemented by a class, creates a new clipping region from the intersection of the current clipping region and the specified rectangle.

RestoreClip(IntPtr)

When implemented by a class, restores current clipping region from previously saved region.

SaveClip(Rectangle)

When implemented by a class, retrieves handle to clipping region saved from specified rectangle.

StringWidth(string)

When implemented by a class, returns width of the given string.

StringWidth(string, int, int)

When implemented by a class, returns width of the specified part of the given string.

StringWidth(string, int, int, int, out int)

When implemented by a class, returns width of the specified part of the given string fitting into the given Width.

StringWidth(string, int, int, int, out int, bool)

When implemented by a class, returns width of the specified part of the given string fitting into the given Width.

StringWidth(string, int, out int, bool)

When implemented by a class, returns width of the given string fitting into the given Width.

TextOut(string, int, Rectangle)

When implemented by a class, draws text within the specified rectangle.

TextOut(string, int, Rectangle, bool, bool)

When implemented by a class, draws text within the specified rectangle.

TextOut(string, int, Rectangle, int, int, bool, bool)

When implemented by a class, draws text within the specified rectangle.

TextOut(string, int, Rectangle, int, int, bool, bool, int)

When implemented by a class, draws text within the specified rectangle.

TextOut(string, int, int, int)

When implemented by a class, draws text in the specified location.

TextOut(string, int, int, int, bool, bool)

When implemented by a class, draws text in the specified location.

Transform(int, int, float, float)

When implemented by a class, sets a two-dimensional linear transformation for the specified device context.