6 The fonts parameter

This is a database table parameter. Please refer to 2.2 for a detailed explanation of database tables layout. In all the following examples we assume that the recordseparator is ^ and the fieldseparator is | .

The entries parameter contains 2 fields referring to fonts. Column 8 of the entries parameter contains a pointer to a record in the fonts parameter (from now on this record will be called a font profile) and Column 9 in the entries parameter contains the alignment information of the text relative to the icon.

Column Name Type Default Range
0 Key String    
1 Font name String   All fonts supported by the system.
2 Font style Integer   0 = plain, 1 = bold, 2 = italic ; 3 = bold & italic
3 Font size Integer    

 

Column 0 is the (primary) key. This key will be used when referring to this record.

Column 1 defines the name of the font. Because the amount of available fonts depend on the underlying OS, it is safer to use generic font names or names of font families like: "SansSerif", "Serif" and "Monospaced".

Column 2 defines the style applied to the font.

Column 3 defines the size of the font.

6.1 fontprofile and tipfontprofile from the options parameter

In 3.9 and 3.10 we defined the fontprofile and tipfontprofile options. Which implies that the fontprofile(s) defined by these options are required too.

So we need at least 2 fontprofiles (actually we only need 1 fontprofile because fontprofiles can be shared).

Built in font profiles

defaultfont and tipdefaultfont are built in font profiles. These 2 profiles can be used without the need to define them first in the fonts paremeter.

You can override these built fontprofiles.

Some examples

(assumptions: fontprofile = defaultfont, tipfontprofile = tipdefaultfont )

<PARAM name=fonts value="
^defaultfont|SansSerif|0|15
^tipdefaultfont|SansSerif|0|13
">


<PARAM name=entries value="
^root|Using defaultfont|-start-|c|o
^child1|Using special font 1|root|n|||||font1
^child2|Using special font 2|root|n|||||font2
">

<PARAM name=fonts value="
^defaultfont|SansSerif|0|15
^tipdefaultfont|SansSerif|0|13
^font1|Monospaced|1|13
^font2|Serif|2|20
">