MeasureText Method (RenderContextBase)
Measures text
Syntax
public virtual Size MeasureText( string text, float fontSize, FontFamily fontFamily, FontWeight fontWeight, FontStyle fontStyle )
Parameters
- text
- The text to measure
- fontSize
- The size of a font face
- fontFamily
- The family name of related fonts
- fontWeight
- The density of a typeface
- fontStyle
- The style of a font face
Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2
See Also