Displays a Windows Font Selection dialog and returns selected font as name,size string.
Takes window (Int).
Returns "name,size" string on success, empty string if user cancels or window not found.
BGI GUI
Parameters & Returns
Parameters
windowInt
Returns
String
Quick Summary
Displays a Windows Font Selection dialog and returns selected font as name,size string.
Takes window (Int).
Returns "name,size" string on success, empty string if user cancels or window not found.
Technical Exegesis...
Displays a Windows Font Selection dialog and returns selected font as name,size string. Searches gizmoMap for window ID to get parent HWND. Creates LOGFONT structure initialized with current requestedFont* globals (name, size, bold, italic, underline, strikeout). Creates CHOOSEFONT structure with CF_SCREENFONTS | CF_EFFECTS | CF_INITTOLOGFONTSTRUCT flags, sets initial color from requestedRed/Green/Blue. Calls ChooseFont() to show dialog.
Displays a Windows Font Selection dialog and returns selected font as name,size string. Searches gizmoMap for window ID to get parent HWND. Creates LOGFONT structure initialized with current requestedFont* globals (name, size, bold, italic, underline, strikeout). Creates CHOOSEFONT structure with CF_SCREENFONTS | CF_EFFECTS | CF_INITTOLOGFONTSTRUCT flags, sets initial color from requestedRed/Green/Blue. Calls ChooseFont() to show dialog. If user selects font, stores properties in globals: requestedFontName, requestedFontSize, requestedFontBold, requestedFontItalic, requestedFontUnderline, requestedFontStrikeout. Also stores color in requestedRed/Green/Blue and requestedRedF/GreenF/BlueF. Returns "name,size" string on success, empty string if user cancels or window not found.
This function shows the standard Windows font picker with font list, size, style (bold/italic), effects (underline/strikeout), and color. Dialog initializes with current requested* values, allowing incremental adjustments. Font size conversion uses MulDiv with LOGPIXELSY for DPI-aware sizing. Use bgiGetSelectedFont* functions to retrieve individual properties: bgiGetSelectedFontName(), bgiGetSelectedFontSize(), bgiGetSelectedFontBold(), bgiGetSelectedFontItalic(), bgiGetSelectedFontUnderline(), bgiGetSelectedFontStrikeout(). Dialog also sets color globals accessible via bgiRequestedRed/Green/Blue*. Dialog is modal - blocks until user selects or cancels.