Shiny Language Reference

Language Reference > Font Functions


setfontcol

setfontcol(font FontVar, int RGBValue);

 

Synonyms:

settextcol(font FontVar, int RGBValue);

 

 

Sets the colour of the specified font

SETFONTCOL sets the RGB colour of the specified font previously created with CREATEFONT. It does not select the font for future use, so can be called at any time. The RGB value can be specified by using the RGB statement.

 

Parameters

FontVar

The variable declared as type FONT to change the colour

RGBValue

An RGB value, specified as an integer, used for the new font colour.

 

Return Value

None.

 

Example Code

font MyFont;
createfont(MyFont, "Arial", 12);

// Set the font to bright blue
setfontcol(MyFont, RGB(0, 0, 255));