WinXDraw_GetFontDialog


WinXDraw_GetFontDialog (hWndOwner, LOGFONT @logFont, @colour)

Displays a dialog box allowing the user to select a font.

Parameter Description
hWndOwner The handle to the window that will own the dialog, or 0 for none
LOGFONT @logFont The logFont structure used to initialise the dialog. When the function returns this structure will contain the user's selection
@colour The colour used to initialise the dialog. When the function returns this variable will contain the user's selection

Returns

$$TRUE on success or $$FALSE on fail

Remarks

You should initialise the LOGFONT structure with WinXDraw_MakeLogFont before calling this function for the first time.

Examples

'Declare the LOGFONT structure
LOGFONT logFont

...

'Initialise the parameters
logFont = WinXDraw_MakeLogFont ("Arial", 20, 0)
colour = 0

'Ask the user for a font
WinXDraw_GetFontDialog (#hMain, @logFont, @colour)

Related Links

Text and Fonts
WinXDrawText
WinXDraw_MakeLogFont
WinXSetFont