foregroundColor

Typeproperty
DictionaryLCS
LibraryLiveCode Script
Syntax
set the foregroundColor of <object> to {empty | <colorName> | <RGBColor>}
set the foregroundColor of [<chunk> of] <field> to {empty| <colorName> | <RGBColor>}
Synonymsforecolor,firstcolor,textcolor,thumbcolor,fillfore,penfore
Associationsstack, card, field, button, graphic, scrollbar, player, image, group
Summary

Specifies the color of object text and borders.

Introduced1.0
OSmac, windows, linux, ios, android
Platformsdesktop, server, mobile
Example
set the foregroundColor of button "Help!" to "red"
set the foregroundColor of this card to "#FF00FF"
set the foregroundColor of the mouseChunk to 0,255,0
Values
NameTypeDescription
Value

The foregroundColor of an object is a color reference. The colorName is any standard color name.

The RGBColor consists of three comma-separated integers between zero and 255, specifying the level of each of red, green, and blue; or an HTML -style color consisting of a hash mark (#) followed by three hexadecimal numbers, one for each of red, green, and blue.

By default, the foregroundColor for all objects is empty.

RelatedKeyword: image, effective, default, button, field, player, card, scrollbar, graphic, colorPalette
Property: linkColor, HTMLText, owner, showBorder, showName, showValue, linkHiliteColor, foregroundPattern, RTFText
Command: answer color, group
Function: mouseColor, value
Glossary: object, property, color palette, HTML, hexadecimal, video clip, integer, keyword, audio clip, chunk, color reference, insertion point, object type, EPS
Object: graphic, button, scrollbar, stack, field, image
Description

Use the foregroundColor property to change the color of text or the color that fills an object.

Setting the foregroundColor of an object to empty allows the foregroundColor of the object's owner to show through. Use the effective keyword to find out what color is used for the object, even if its own foregroundColor is empty.

The setting of the foregroundColor property has different effects, depending on the object type:

The foregroundColor also determines the color of the blinking insertion point when it is in the field.

If an object's foregroundPattern is set, the pattern is shown instead of the color specified by foregroundColor.

Tagsui