Method ClipAndJustify
ClipAndJustify(string, int, Alignment, TextDirection, int, TextFormatter?)
Justifies text within a specified width.
public static string ClipAndJustify(string text, int width, Alignment textAlignment, TextDirection textDirection = TextDirection.LeftRight_TopBottom, int tabWidth = 0, TextFormatter? textFormatter = null)
Parameters
textstringThe text to justify.
widthintThe number of columns to clip the text to. Text longer than
widthwill be clipped.textAlignmentAlignmentAlignment.
textDirectionTextDirectionThe text direction.
tabWidthintThe number of columns used for a tab.
textFormatterTextFormatterTextFormatter instance to access any of his objects.
Returns
- string
Justified and clipped text.
ClipAndJustify(string, int, bool, TextDirection, int, TextFormatter?)
Justifies text within a specified width.
public static string ClipAndJustify(string text, int width, bool justify, TextDirection textDirection = TextDirection.LeftRight_TopBottom, int tabWidth = 0, TextFormatter? textFormatter = null)
Parameters
textstringThe text to justify.
widthintThe number of columns to clip the text to. Text longer than
widthwill be clipped.justifyboolJustify.
textDirectionTextDirectionThe text direction.
tabWidthintThe number of columns used for a tab.
textFormatterTextFormatterTextFormatter instance to access any of his objects.
Returns
- string
Justified and clipped text.