In this section:
Textual window input/output uses, by default, a Windows font called SYSTEM_FIXED_FONT output in black. You are not limited to the use of this font; Windows can write text in a wide variety of fonts and colours. You simply use appropriate Windows API routines to create one or more fonts and then attach them to a window.
In order to create a new font, it is usually best to start with the parameters defining the system font and modify them to obtain what you require.
For example:
WINAPP
INCLUDE <windows.ins>
INTEGER lfheight,lfwidth,lfescapement,
+ lforientation,lfweight,lfitalic,lfunderline,
+ lfstrikeout,lfcharset,lfoutprecision,
+ lfclipprecision,lfquality,lfpitchandfamily
CHARACTER*80 lffacename
INTEGER newfont
CALL get_system_font@(lfheight,lfwidth,lfescapement,
+ lforientation,lfweight,lfitalic,lfunderline,
+ lfstrikeout,lfcharset,lfoutprecision,
+ lfclipprecision,lfquality,lfpitchandfamily,lffacename)
c--- Alter the default parameters to double the size
c--- and specify italic.
lfheight=2*lfheight
lfwidth =2*lfwidth
lfitalic=1
c--- CreateFont is a Windows API function...
newfont=CreateFont(lfheight,lfwidth,lfescapement,
+ lforientation,lfweight,lfitalic,lfunderline,
+ lfstrikeout,lfcharset,lfoutprecision,
+ lfclipprecision,lfquality,lfpitchandfamily,lffacename)
CALL set_default_font@(newfont)
...
The default font used by a ClearWin window (SYSTEM_FIXED_FONT) can be changed by a call to either SET_DEFAULT_PROPORTIONAL_FONT@ or to SET_DEFAULT_FONT@. These routines will alter the default font used by ClearWin+ on all ClearWin windows created subsequent to the call. The original default can be restored by a call to SET_DEFAULT_TO_FIXED_FONT@.