O2S.Components.PDF4NET Documentation
MeasureString Method



O2S.Components.PDF4NET.Graphics.Text Namespace > PDFTextEngine Class : MeasureString Method
String to measure.
Font used to display the string.
Measures the specified string.
Syntax
'Declaration
 
Public Shared Function MeasureString( _
   ByVal s As String, _
   ByVal font As PDFFont _
) As PDFSize
'Usage
 
Dim s As String
Dim font As PDFFont
Dim value As PDFSize
 
value = PDFTextEngine.MeasureString(s, font)
public static PDFSize MeasureString( 
   string s,
   PDFFont font
)
public:
static PDFSize^ MeasureString( 
   String^ s,
   PDFFont^ font
) 

Parameters

s
String to measure.
font
Font used to display the string.

Return Value

The size of the string when displayed using the font.
Requirements

Supported .NET Platforms: .NET 4.0 and higher, Windows Forms, ASP.NET, Windows Presentation Foundation 4.x, Silverlight 5, WinRT, Universal Windows Platform, Xamarin Mac, iOS & Android, Portable Class Library, .NET Core, .NET Standard


Target Platforms:Windows 10, Windows 8.1, Windows 8 , Windows 7, Windows Vista SP1 or later, Windows Server 2008, Windows Server 2008 R2

See Also

Reference

PDFTextEngine Class
PDFTextEngine Members