This documentation is archived and is not being maintained.
TextMetrics Structure
Visual Studio 2010
Provides basic information about the font specified by a visual style for a particular element.
Assembly: System.Windows.Forms (in System.Windows.Forms.dll)
The TextMetrics type exposes the following members.
| Name | Description | |
|---|---|---|
![]() | Ascent | Gets or sets the ascent of characters in the font. |
![]() | AverageCharWidth | Gets or sets the average width of characters in the font. |
![]() | BreakChar | Gets or sets the character used to define word breaks for text justification. |
![]() | CharSet | Gets or sets the character set of the font. |
![]() | DefaultChar | Gets or sets the character to be substituted for characters not in the font. |
![]() | Descent | Gets or sets the descent of characters in the font. |
![]() | DigitizedAspectX | Gets or sets the horizontal aspect of the device for which the font was designed. |
![]() | DigitizedAspectY | Gets or sets the vertical aspect of the device for which the font was designed. |
![]() | ExternalLeading | Gets or sets the amount of extra leading that the application adds between rows. |
![]() | FirstChar | Gets or sets the first character defined in the font. |
![]() | Height | Gets or sets the height of characters in the font. |
![]() | InternalLeading | Gets or sets the amount of leading inside the bounds set by the Height property. |
![]() | Italic | Gets or sets a value indicating whether the font is italic. |
![]() | LastChar | Gets or sets the last character defined in the font. |
![]() | MaxCharWidth | Gets or sets the width of the widest character in the font. |
![]() | Overhang | Gets or sets the extra width per string that may be added to some synthesized fonts. |
![]() | PitchAndFamily | Gets or sets information about the pitch, technology, and family of a physical font. |
![]() | StruckOut | Gets or sets a value indicating whether the font specifies a horizontal line through the characters. |
![]() | Underlined | Gets or sets a value indicating whether the font is underlined. |
![]() | Weight | Gets or sets the weight of the font. |
| Name | Description | |
|---|---|---|
![]() | Equals | Indicates whether this instance and a specified object are equal. (Inherited from ValueType.) |
![]() | Finalize | Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection. (Inherited from Object.) |
![]() | GetHashCode | Returns the hash code for this instance. (Inherited from ValueType.) |
![]() | GetType | Gets the Type of the current instance. (Inherited from Object.) |
![]() | MemberwiseClone | Creates a shallow copy of the current Object. (Inherited from Object.) |
![]() | ToString | Returns the fully qualified type name of this instance. (Inherited from ValueType.) |
The TextMetrics structure specifies the return values of the VisualStyleRenderer::GetTextMetrics method.
Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows XP SP2 x64 Edition, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2
The .NET Framework does not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.
Show:
