SharpLeaf Reference > SharpLeaf Methods > GetTextWidth Method > (String,FontType)

SharpLeaf.GetTextWidth Method (String,FontType)

Measure the width taken by a paragraph of text, interpreting newline characters (but not tab characters).

public double GetTextWidth(
    string text,
    FontType font
);
text
Text to measure, possibly including linebreaks.
font
Font to measure text with – current paragraph’s by default.
return value
Measured width.

See also ...

SharpLeaf Members | SharpLeaf.GetTextWidth Method


Send comments on this topic
© Dyalog Ltd 2021