GetText (label)
SetText (label)
Font property (label)
TextColor property (label)
Label.GetText(string buffer)Gets the current text on the label into the string BUFFER.
Example:
string buffer; lblStatus.GetText(buffer); Display("The label says %s.", buffer);will display the label's contents in a message box.
See Also: Button.NormalGraphic, Button.SetText, Label.TextColor, Label.Font
Label.SetText(string newtext)Changes the text displayed in the specified label to NEWTEXT. This command allows you to change the text during the game, for example to create a Lucasarts-style status line.
Example:
string buffer; GetLocationName(mouse.x, mouse.y, buffer); lblStatus.SetText(buffer);will display the name of the location the cursor is over on label 'lblStatus'
See Also: Button.NormalGraphic, Button.SetText, Label.TextColor, Label.Font
int Label.Font;Gets/sets the font used to display the label's text. This is useful if you have a standard SCI font for your English version, but want to change to a TTF font for foreign language versions.
Example:
if (IsTranslationAvailable()) { lblStatus.Font = 2; }will change label 'lblStatus' to use font 2 if a game translation is in use.
See Also: IsTranslationAvailable, Label.SetText, TextBox.Font
int Label.TextColor;Gets/sets the text colour used to display the label's text.
Example:
lblStatus.TextColor = 14;will change label 'lblStatus' to have yellow text.
See Also: Label.Font, Label.SetText
Browser Based Help. Published by chm2web software. |