Class to define an integer slider. More...
#include <Inventor/dialog/PoXtIntSliderData.h>
Public Member Functions | |
PoXtIntSliderData (const char *label=NULL, int min=0, int max=1, int initVal=0, TriggerMode mode=MOUSE_ON_RELEASE_TRIGGER) | |
virtual | ~PoXtIntSliderData () |
void | setValue (int value) |
int | getValue () const |
void | setLimit (int min, int max) |
void | getLimit (int &min, int &max) const |
virtual TypeXtElement | getType () const |
virtual PoXtElementData * | copy () const |
An integer slider is a slider where the values are integers. By default the limits of the slider are [0-1] and the initial value is 0.
PoXtIntSliderData::PoXtIntSliderData | ( | const char * | label = NULL , |
|
int | min = 0 , |
|||
int | max = 1 , |
|||
int | initVal = 0 , |
|||
TriggerMode | mode = MOUSE_ON_RELEASE_TRIGGER | |||
) |
Constructor.
virtual PoXtIntSliderData::~PoXtIntSliderData | ( | ) | [virtual] |
Destructor.
virtual PoXtElementData* PoXtIntSliderData::copy | ( | ) | const [virtual] |
Creates and returns a new Xt element which is a copy of this Xt element.
Implements PoXtElementData.
void PoXtIntSliderData::getLimit | ( | int & | min, | |
int & | max | |||
) | const |
Gets the limits of the slider.
virtual TypeXtElement PoXtIntSliderData::getType | ( | ) | const [virtual] |
Returns the type of the Xt element.
Implements PoXtSliderData.
int PoXtIntSliderData::getValue | ( | ) | const |
Gets the integer value of the slider.
void PoXtIntSliderData::setLimit | ( | int | min, | |
int | max | |||
) |
Sets the limits of the slider.
Update the slider thumb position. If the current value is not beetween the new limit, the current value is set to the minimal or maximum value, and a event is raised.
void PoXtIntSliderData::setValue | ( | int | value | ) |
Sets the integer value of the slider.
If the user enters a value greater or less than the limits of the slider in the numerical field, the corresponding limit is updated to this value.