Show / Hide Table of Contents

Class GraphicsExtentions

Extensions for the System.Drawing.Graphics class.

Inheritance
System.Object
GraphicsExtentions
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: DesktopMagicPluginAPI.Drawing
Assembly: DesktopMagicPluginAPI.dll
Syntax
public static class GraphicsExtentions

Methods

| Improve this Doc View Source

DrawStringFixedWidth(Graphics, String, Font, Brush, PointF, Single)

Declaration
public static void DrawStringFixedWidth(this Graphics graphics, string s, Font font, Brush brush, PointF point, float width)
Parameters
Type Name Description
System.Drawing.Graphics graphics

Graphics object.

System.String s

String to draw.

System.Drawing.Font font

System.Drawing.Font that defines the text format of the string.

System.Drawing.Brush brush

System.Drawing.Brush that determines the color and texture of the drawn text.

System.Drawing.PointF point

System.Drawing.PointF structure that specifies the upper-left corner of the drawn text.

System.Single width

The specified width.

| Improve this Doc View Source

DrawStringFixedWidth(Graphics, String, Font, Brush, Single, Single, Single)

Declaration
public static void DrawStringFixedWidth(this Graphics graphics, string s, Font font, Brush brush, float x, float y, float width)
Parameters
Type Name Description
System.Drawing.Graphics graphics

Graphics object.

System.String s

String to draw.

System.Drawing.Font font

System.Drawing.Font that defines the text format of the string.

System.Drawing.Brush brush

System.Drawing.Brush that determines the color and texture of the drawn text.

System.Single x

The x-coordinate of the upper-left corner of the drawn text.

System.Single y

The y-coordinate of the upper-left corner of the drawn text.

System.Single width

The specified width.

| Improve this Doc View Source

DrawStringMonospace(Graphics, String, Font, Brush, PointF)

Declaration
public static void DrawStringMonospace(this Graphics graphics, string s, Font font, Brush brush, PointF point)
Parameters
Type Name Description
System.Drawing.Graphics graphics

Graphics object.

System.String s

String to draw.

System.Drawing.Font font

System.Drawing.Font that defines the text format of the string.

System.Drawing.Brush brush

System.Drawing.Brush that determines the color and texture of the drawn text.

System.Drawing.PointF point

System.Drawing.PointF structure that specifies the upper-left corner of the drawn text.

| Improve this Doc View Source

DrawStringMonospace(Graphics, String, Font, Brush, Single, Single)

Declaration
public static void DrawStringMonospace(this Graphics graphics, string s, Font font, Brush brush, float x, float y)
Parameters
Type Name Description
System.Drawing.Graphics graphics

Graphics object.

System.String s

String to draw.

System.Drawing.Font font

System.Drawing.Font that defines the text format of the string.

System.Drawing.Brush brush

System.Drawing.Brush that determines the color and texture of the drawn text.

System.Single x

The x-coordinate of the upper-left corner of the drawn text.

System.Single y

The y-coordinate of the upper-left corner of the drawn text.

| Improve this Doc View Source

DrawStringNoLeftPadding(Graphics, String, Font, Brush, PointF)

Declaration
public static void DrawStringNoLeftPadding(this Graphics graphics, string s, Font font, Brush brush, PointF point)
Parameters
Type Name Description
System.Drawing.Graphics graphics

Graphics object.

System.String s

String to draw.

System.Drawing.Font font

System.Drawing.Font that defines the text format of the string.

System.Drawing.Brush brush

System.Drawing.Brush that determines the color and texture of the drawn text.

System.Drawing.PointF point

System.Drawing.PointF structure that specifies the upper-left corner of the drawn text.

| Improve this Doc View Source

DrawStringNoLeftPadding(Graphics, String, Font, Brush, Single, Single)

Declaration
public static void DrawStringNoLeftPadding(this Graphics graphics, string s, Font font, Brush brush, float x, float y)
Parameters
Type Name Description
System.Drawing.Graphics graphics

Graphics object.

System.String s

String to draw.

System.Drawing.Font font

System.Drawing.Font that defines the text format of the string.

System.Drawing.Brush brush

System.Drawing.Brush that determines the color and texture of the drawn text.

System.Single x

The x-coordinate of the upper-left corner of the drawn text.

System.Single y

The y-coordinate of the upper-left corner of the drawn text.

| Improve this Doc View Source

MeasureStringNoLeftPadding(Graphics, String, Font)

Declaration
public static SizeF MeasureStringNoLeftPadding(this Graphics graphics, string text, Font font)
Parameters
Type Name Description
System.Drawing.Graphics graphics

Graphics object.

System.String text

String to measure.

System.Drawing.Font font

System.Drawing.Font that defines the text format of the string.

Returns
Type Description
System.Drawing.SizeF
  • Improve this Doc
  • View Source
In This Article
Back to top Generated by DocFX