WinXDraw_GetFontHeight


height = WinXDraw_GetFontHeight (hFont, @ascent, @descenct)

Gets the height of a font

Parameter Description
hFont The handle to the font to get the height of
@ascent The variable to store the ascent height
@descent The variable to store the descent height

Returns

The height of the font

Remarks

Sometimes you have a handle to a font, but no LOGFONT structure. You can use this function to get the font height and also the ascention and descention if you need them.

Examples

' Get the height of a system font
hFont = GetStockObject($$DEFAULT_GUI_FONT)
height = WinXDraw_GetFontHeight (hFont, @ascent, @descenct)

Related Links

Text and Fonts
WinXDraw_GetTextWidth