Defines (or redefines, depending on mode) the font alias alias, e.g. stf_default, as the font name with the given height, width, options and xscale
Source position: msefont.pas line 52
function registerfontalias( |
const alias: string; |
const name: string; |
mode: fontaliasmodety = fam_nooverwrite; |
const height: Integer = 0; |
const width: Integer = 0; |
const options: fontoptionsty = []; |
const xscale: real = 1.0; |
ancestor: string = defaultfontalias; |
const template: tfontcomp = Nil |
):Boolean; |
Defines (or redefines, depending on mode) the font alias alias, e.g. stf_default, as the font name with the given height, width, options and xscale. A value of 0 or an empty string keeps the value of ancestor.
The font aliases of 'Project'-'Options'-'Font Alias' in MSEide are only used at design time, to see the same fonts as at runtime: the program must register them itself on startup, before creating its forms, for example:
begin registerfontalias('stf_default','Palatino Linotype',fam_overwrite,20); application.createform(tmainfo,mainfo); application.run; end.
The same can be done without recompiling by the command line parameter --FONTALIAS=<alias>,<fontname>[,<height>[,<width>[,<options>[,<xscale>[,<ancestor>]]]]], where an empty value keeps the default, e.g. --FONTALIAS=stf_default,,16 for a 16 pixel high default font.