CSGetCharHeight Function

Description

Returns the font character height of the Consoul window font.

By default, Consoul window have the line height (CSGetLineHeight) equal to the font's character height. However this changes when line spacing is used (CSSetLineSpacing).

Syntax

VB/A 32bits

Private Declare Function CSGetCharHeight Lib "consoul_010205_32.dll" ( _
  ByVal hWnd As Long _
) As Integer

VB/A 64bits

Private Declare PtrSafe Function CSGetCharHeight Lib "consoul_010205_64.dll" ( _
  ByVal hWnd As LongPtr _
) As Integer

Return Value

The return value is the character height of the Consoul window font (specified at window creation time, see CSCreateLogWindow).

Parameters

hWnd

The window handle (HWND) of the Consoul window, as returned by CSCreateLogWindow.

Remarks

This function internally uses the Win32 GetTextMetrics API to query for font information and returns the wCharHeight member of the TEXTMETRIC structure.

Last updated: May 13 2022.