LavishGUI:lguislider (Data Type)

From Lavish Software Wiki
Revision as of 23:50, 30 August 2005 by Beefalo (talk | contribs)
(diff) ←Older revision | view current revision (diff) | Newer revision→ (diff)
Jump to navigation Jump to search

Description

Members

  • int Range : range of the slider (0-Range)
  • int Value : value of the slider
  • bool Vertical : TRUE if the slider is up and down instead of left to right

Methods

  • SetRange[#] : sets the range of the slider
  • SetValue[#] : sets the value of the slider

Inherits

isuielement

Returns

Same as isuielement.Name

Examples

Display the range and value of a slider

  • echo Range: ${UIElement[test].FindChild[test].Range}
  • echo Value: ${UIElement[test].FindChild[test].Value}
Output
 Range: 100
 Value: 51

Set a slider's Range

  • UIElement[test].FindChild[test]:SetRange[100]
Sets Range from 0 to 100

Set a slider's Value

  • UIElement[test].FindChild[test]:SetValue[50]
This would set Value at exactly the halfway point


Example code
<?xml version="1.0" encoding="UTF-8"?> 
<ISUI> 
   <window name='test'> 
     <X>200</X> 
     <Y>200</Y> 
     <Width>150</Width> 
     <Height>80</Height> 
     <Title>My Window</Title> 
     <Children> 
        <slider name='test'> 
          <X>15</X> 
          <Y>5</Y> 
          <Width>100</Width> 
          <Height>20</Height> 
        </slider> 
    </Children> 
  </window> 
</ISUI> 

See Also