This topic has not yet been rated - Rate this topic

TextRenderer.MeasureText Method

[This documentation is for preview only, and is subject to change in later releases. Blank topics are included as placeholders.]

Measures the specified text when drawn with the specified font.

This member is overloaded. For complete information about this member, including syntax, usage, and examples, click a name in the overload list.

  Name Description
Public method Static member MeasureText(String, Font) Provides the size, in pixels, of the specified text when drawn with the specified font.
Public method Static member MeasureText(IDeviceContext, String, Font) Provides the size, in pixels, of the specified text drawn with the specified font in the specified device context.
Public method Static member MeasureText(String, Font, Size) Provides the size, in pixels, of the specified text when drawn with the specified font, using the specified size to create an initial bounding rectangle.
Public method Static member MeasureText(IDeviceContext, String, Font, Size) Provides the size, in pixels, of the specified text when drawn with the specified font in the specified device context, using the specified size to create an initial bounding rectangle for the text.
Public method Static member MeasureText(String, Font, Size, TextFormatFlags) Provides the size, in pixels, of the specified text when drawn with the specified font and formatting instructions, using the specified size to create the initial bounding rectangle for the text.
Public method Static member MeasureText(IDeviceContext, String, Font, Size, TextFormatFlags) Provides the size, in pixels, of the specified text when drawn with the specified device context, font, and formatting instructions, using the specified size to create the initial bounding rectangle for the text.
Top
Did you find this helpful?
(1500 characters remaining)