6.0

Table Of Contents
141
SetStyle (procedure)
Sets the style to be used for all subsequent commands. The specified style must already exist in the
document.
Note: SetStyle() supercedes the SetFont() command. Although PlanetPress Talk still recognizes
SetFont(), this behavior is unlikely to continue in future versions, and it is therefore highly recommended
that you use the SetStyle() command in your scripts.
Syntax
setstyle( stylename )
Argument
stylename — Name of the style to use for all subsequent commands. The name of the style must be
preceded by an ampersand. You can reference the bold, italic, or underlined versions of a font by appending
the appropriate letter or letters to the name of the style. Append .b for the bold version, .i for the italic
version, .bi for the bold italic version, and .u for the underlined version.
Code Sample Example
This example displays a line of text using two different existing styles called Blackfont and Bluefont.
Example
margin(1,1)
setstyle(&blackfont)
show('The word ')
setstyle(&bluefont.i)
show('blue')
setstyle(&blackfont)
show(' is now highlighted')
SetStyleExt (procedure)
Select an existing style and set the size, color, style property, or font ratio for its font. This eliminates the
need to create several styles that use the same font. setstyleext() does not support bold, italic, or
underline styles with double-byte character sets.
Syntax
setstyleext(stylename, fontsize, styleproperty, fontcolor, fontratio)