Draws the specified text string in the specified rectangle with the specified Font and SolidBrush settings.
Namespace:
Aurigma.GraphicsMill.Drawing
Assembly:
Aurigma.GraphicsMill (in Aurigma.GraphicsMill.dll)
public void DrawString( string string, Font font, SolidBrush brush, Rectangle rect, TextTrimmingMode trim, bool hotkeyPrefix, bool clipping, bool wordWrap )
Type: System.String
A string to draw.Type: Aurigma.GraphicsMill.Drawing.Font
A Font that defines the text format of the string.Type: Aurigma.GraphicsMill.Drawing.SolidBrush
A SolidBrush that determines the color of the drawn text.Type: System.Drawing.Rectangle
A Rectangle structure that specifies the bounds of the drawn text.Type: Aurigma.GraphicsMill.Drawing.TextTrimmingMode
A TextTrimmingMode specifying how to handle the situation when a text does not fit a given rectangle (where to insert ellipsis).Type: System.Boolean
true
if the hotkey prefix (ampersand sign) is removed from the string and next character is underlined; otherwise, false
.Type: System.Boolean
true
if the string is clipped when it does not fit the bounding rectangle; otherwise, false
.Type: System.Boolean
true
if the wrapped inside the bounding rectangle; otherwise, false
.The extent of the text drawn by this method can be measured using the MeasureString(String, Font) method.
When you try to draw text on a grayscale bitmap, you will notice that the text is not antialiased. The reason of this problem is that neither GDI nor GDI+ support grayscale bitmaps, therefore Graphics Mill has to imitate it as indexed bitmap with grayscale palette. However, antialiasing is impossible on indexed bitmaps.