This class provides a horizontal or vertical scrollbar to provide scrolling capabilities, or a numeric input mechanism. Most methods generally used with a scrollbar are handled by the parent class Valuator.
Method Summary: | ||
Scrollbar::Scrollbar | (); | |
void | Scrollbar::setVertical | (bool b); |
void | Scrollbar::setSliderSize | (float f); |
float | Scrollbar::getSliderSize | (); |
int | Scrollbar::getIntValue | (); |
int | Scrollbar::setScrollValue | (int position, int size, int top, int total); |
void | Scrollbar::setLineSize | (int i); |
int | Scrollbar::getLineSize | (); |
Scrollbar::Scrollbar |
Scrollbar::Scrollbar(); Constructs a new Scrollbar widget. |
void Scrollbar::setVertical | ||||||
void Scrollbar::setVertical(bool b); Sets the orientation for the scrollbar. The default is horizontal. | ||||||
|
void Scrollbar::setSliderSize | ||||||
void Scrollbar::setSliderSize(float f); Sets the dimension of the moving part of the slider. This is the fraction of the size of the whole widget. The default is 0.08. | ||||||
|
float Scrollbar::getSliderSize |
float Scrollbar::getSliderSize(); Returns the size of the slider as a precentage of the size of the whole widget. |
int Scrollbar::getIntValue |
int Scrollbar::getIntValue(); Returns the integer value of the slider. To get the floating point value, use Valuator::getValue(). |
int Scrollbar::setScrollValue | |||||||||||||||
int Scrollbar::setScrollValue(int position, int size, int top, int total); Sets the range, value, and slider size of the scrollbar to make a variable sized one. This method should be called from the callback, including when the data changes size, the window is resized, or the scroll position changes. | |||||||||||||||
|
void Scrollbar::setLineSize | ||||||
void Scrollbar::setLineSize(int i); Controls how big the steps are that the arrow keys make. The default is 16. | ||||||
|
int Scrollbar::getLineSize |
int Scrollbar::getLineSize(); Returns the number of steps take for an arrow key press. |