GraphicsDrawText Method (Font, Brush, RectangleF, String, FormattedTextWrapMode, FormattedTextAlignment, FormattedTextTrimming) |
Draws text in a rectangle with the specified formatted text trimming
Namespace:
Eto.Drawing
Assembly:
Eto (in Eto.dll) Version: 2.5.3-dev
Syntax public void DrawText(
Font font,
Brush brush,
RectangleF frame,
string text,
FormattedTextWrapMode wrap = FormattedTextWrapMode.Word,
FormattedTextAlignment alignment = FormattedTextAlignment.Left,
FormattedTextTrimming trimming = FormattedTextTrimming.WordEllipsis
)
Public Sub DrawText (
font As Font,
brush As Brush,
frame As RectangleF,
text As String,
Optional wrap As FormattedTextWrapMode = FormattedTextWrapMode.Word,
Optional alignment As FormattedTextAlignment = FormattedTextAlignment.Left,
Optional trimming As FormattedTextTrimming = FormattedTextTrimming.WordEllipsis
)
member DrawText :
font : Font *
brush : Brush *
frame : RectangleF *
text : string *
?wrap : FormattedTextWrapMode *
?alignment : FormattedTextAlignment *
?trimming : FormattedTextTrimming
(* Defaults:
let _wrap = defaultArg wrap FormattedTextWrapMode.Word
let _alignment = defaultArg alignment FormattedTextAlignment.Left
let _trimming = defaultArg trimming FormattedTextTrimming.WordEllipsis
*)
-> unit
Parameters
- font
- Type: Eto.DrawingFont
Font to draw the text with - brush
- Type: Eto.DrawingBrush
Brush to fill the text path - frame
- Type: Eto.DrawingRectangleF
Frame for the text to be drawn into - text
- Type: SystemString
String to draw - wrap (Optional)
- Type: Eto.DrawingFormattedTextWrapMode
Wrap mode for the text - alignment (Optional)
- Type: Eto.DrawingFormattedTextAlignment
Alignment of the text in the specified rectangle - trimming (Optional)
- Type: Eto.DrawingFormattedTextTrimming
Trimming to apply if the text does not fit in the supplied rectangle
See Also