VintaSoft Imaging .NET SDK 15.2: Documentation for .NET developer
Vintasoft.Imaging.Pdf.Drawing Namespace / PdfGraphics Class / MeasureString Methods / MeasureString(String,PdfFont,Single,Single,Single,Single,Single) Method
Syntax Requirements SeeAlso
In This Topic
MeasureString(String,PdfFont,Single,Single,Single,Single,Single) Method (PdfGraphics)
In This Topic
Measures the specified string when drawn with the specified PdfFont.
Syntax
'Declaration

Public Overloads Sub MeasureString( _
ByVal text
String to measure.
As System.String, _
ByVal font
PdfFont that defines the text format of the string.
As Vintasoft.Imaging.Pdf.Tree.Fonts.PdfFont, _
ByVal height
Text string height.
As Single, _
ByRef width
Text string width.
As Single, _
ByRef x
Text string X offset.
As Single, _
ByRef y
Text string Y offset.
As Single, _
ByRef fontSize
Font size.
As Single _
)
public void MeasureString(
System.String text,
Vintasoft.Imaging.Pdf.Tree.Fonts.PdfFont font,
float height,
out float width,
out float x,
out float y,
out float fontSize
)

Parameters

text
String to measure.
font
PdfFont that defines the text format of the string.
height
Text string height.
width
Text string width.
x
Text string X offset.
y
Text string Y offset.
fontSize
Font size.
Requirements

Target Platforms: .NET 11; .NET 10; .NET 9; .NET 8; .NET 6; .NET Framework 4.8, 4.7, 4.6, 4.5, 4.0, 3.5

See Also