Changes the font to the specified typeface, size, and code page.
Syntax
┌───────────────┬───────────────┬───────────────┬───────────────┐ │Tag │Element │Attributes │End │ ├───────────────┼───────────────┼───────────────┼───────────────┤ │:font. │Fonts │facename= │None │ ├───────────────┼───────────────┼───────────────┼───────────────┤ │ │ │size= │ │ ├───────────────┼───────────────┼───────────────┼───────────────┤ │ │ │codepage= │ │ └───────────────┴───────────────┴───────────────┴───────────────┘
Attributes
facename=
This attribute is required. If default is specified, the font is reset to the default system font.
Notice that facename= values have initial capitals. These are required; otherwise, the IPF compiler will not recognize them as valid values. No error message is returned when an invalid value for facename= is encountered.
Following are the Presentation Manager image fonts available on all system-supported
display adapters:
┌───────────────┐ │Face │ ├───────────────┤ │Courier │ ├───────────────┤ │Helv │ ├───────────────┤ │Tms Rmn │ ├───────────────┤ │System │ │Monospaced │ ├───────────────┤ │System │ │Proportional │ └───────────────┘
The size= attribute is required. If the value is set to 0x0, the font is reset to the default system font.
codepage=
The codepage= attribute is optional. If no code-page value is specified, the code page of the active system process is used.
Description
:font changes the current font for the text within the current window. When a heading tag defining a new window is encountered, the font resets to the default system font.
You can make as many font changes within a window as you want. If you define highlighted phrases while a font tag is in effect, the highlighted text will be displayed in the font style corresponding to the specified typeface.
When you specify height and width values for a valid font name, you do not have to know the exact point values. If no match is found for a specified font size, IPF uses a "best fit" method to select the font. For example, suppose you specify:
:font facename=Helv size=20x12.
IPF selects "Helv 18x10" because it is the closest match.