.NET Framework 4.5.2+
.NET Framework 4.5.2+
.NET Standard 2.0+

PdfGraphics.MeasureString(String, Font, SizeF) Method

Measures the specified string when drawn with the specified Font and text layout size.

Namespace: DevExpress.Pdf

Assembly: DevExpress.Pdf.v20.1.Drawing.dll

Declaration

public SizeF MeasureString(
    string text,
    Font font,
    SizeF layoutSize
)
Public Function MeasureString(
    text As String,
    font As Font,
    layoutSize As SizeF
) As SizeF

Parameters

Name Type Description
text String

A String to measure.

font Font

A Font object that defines the text format of the string.

layoutSize SizeF

A SizeF structure that specifies the maximum layout area for the text.

Returns

Type Description
SizeF

A SizeF structure that represents the measured size of the string.

See Also