Difference between revisions of "LavishGUI:lguicheckbox (Data Type)"
Jump to navigation
Jump to search
(3 intermediate revisions by 2 users not shown) | |||
Line 1: | Line 1: | ||
== Description == | == Description == | ||
− | This data type provides and controls data for | + | This data type provides and controls data for [[LavishGUI:checkbox_%28Element_Type%29|checkbox (Element Type)]]. |
== Members == | == Members == | ||
* [[DataType:string|string]] '''Text''' : checkbox text | * [[DataType:string|string]] '''Text''' : checkbox text | ||
Line 6: | Line 6: | ||
* [[DataType:bool|bool]] '''Checked''' : TRUE if button is checked | * [[DataType:bool|bool]] '''Checked''' : TRUE if button is checked | ||
* [[LavishGUI:lguifont (Data Type)|lguifont]] '''Font''' : font object the checkbox is using | * [[LavishGUI:lguifont (Data Type)|lguifont]] '''Font''' : font object the checkbox is using | ||
+ | * [[LavishGUI:lguitexture (Data Type)|lguitexture]] '''Texture''': Texture displayed in unchecked, normal state | ||
+ | * [[LavishGUI:lguitexture (Data Type)|lguitexture]] '''TextureHover''': Texture displayed when unchecked and mouse cursor is over the checkbox | ||
+ | * [[LavishGUI:lguitexture (Data Type)|lguitexture]] '''TexturePressed''': Texture displayed in unchecked, pressed state | ||
+ | * [[LavishGUI:lguitexture (Data Type)|lguitexture]] '''TextureChecked''': Texture displayed in checked, normal state | ||
+ | * [[LavishGUI:lguitexture (Data Type)|lguitexture]] '''TextureCheckedHover''': Texture displayed when checked and mouse cursor is over the checkbox | ||
+ | * [[LavishGUI:lguitexture (Data Type)|lguitexture]] '''TextureCheckedPressed''': Texture displayed in checked, pressed state | ||
+ | |||
== Methods == | == Methods == | ||
*'''SetText['''text''']''' : sets the text on the checkbox | *'''SetText['''text''']''' : sets the text on the checkbox | ||
Line 52: | Line 59: | ||
== See Also == | == See Also == | ||
*[[LavishGUI]] | *[[LavishGUI]] | ||
+ | *[[LavishGUI:checkbox_%28Element_Type%29|checkbox (Element Type)]] | ||
* [[LavishScript:Data Types|LavishScript Data Types]] | * [[LavishScript:Data Types|LavishScript Data Types]] | ||
* [[IS:Session#Data_Types|Inner Space Session Data Types]] | * [[IS:Session#Data_Types|Inner Space Session Data Types]] | ||
[[Category:LavishGUI]] | [[Category:LavishGUI]] |
Latest revision as of 00:39, 17 October 2008
Description
This data type provides and controls data for checkbox (Element Type).
Members
- string Text : checkbox text
- bool Down : TRUE if the checkbox is pressed
- bool Checked : TRUE if button is checked
- lguifont Font : font object the checkbox is using
- lguitexture Texture: Texture displayed in unchecked, normal state
- lguitexture TextureHover: Texture displayed when unchecked and mouse cursor is over the checkbox
- lguitexture TexturePressed: Texture displayed in unchecked, pressed state
- lguitexture TextureChecked: Texture displayed in checked, normal state
- lguitexture TextureCheckedHover: Texture displayed when checked and mouse cursor is over the checkbox
- lguitexture TextureCheckedPressed: Texture displayed in checked, pressed state
Methods
- SetText[text] : sets the text on the checkbox
- SetChecked : sets the checkbox to checked status
- UnsetChecked : sets the checkbox to unchecked status
- ToggleChecked : toggles the checkbox status
Inherits
Returns
Same as lguielement.Name
Examples
Retrieve text on a checkbox
- echo Text on Checkbox: ${UIElement[test].FindChild[checkboxtest].Text}
- Output
Text on Checkbox: I am a test Checkbox
Display if a checkbox is pressed
- echo Checkbox Pressed? ${UIElement[test].FindChild[checkboxtest].Down}
- Output
Checkbox Pressed? FALSE
Display a checkbox's checked status
- echo Checkbox Checked? ${UIElement[test].FindChild[checkboxtest].Checked}
- Output
Checkbox Checked? FALSE
Display a checkbox's font
- echo Checkbox font: ${UIElement[test].FindChild[checkboxtest].Font}
- Output
Checkbox font: terminal
Set text on a checkbox
- UIElement[test].FindChild[checkboxtest]:SetText[Checkbox Text V2.0]
- echo Text on checkbox: ${UIElement[test].FindChild[checkboxtest].Text}
- Output
Text on checkbox: Checkbox Text V2.0
Toggle a checkbox's checked status
- UIElement[test].FindChild[checkboxtest]:ToggleChecked
- echo Checkbox Checked? ${UIElement[test].FindChild[checkboxtest].Checked}
- Output
Checkbox Checked? TRUE
Uncheck a checkbox
- UIElement[test].FindChild[checkboxtest]:UnsetChecked
- echo Checkbox Checked? ${UIElement[test].FindChild[checkboxtest].Checked}
- Output
Checkbox Checked? FALSE