class MASKING_DLL_DECLSPEC ScrollObject

Implements the basic functionality of a widget that can scroll things.

Inheritance:

ScrollObject


Public Methods

[more]virtual void SetMin(double min)
Sets the minimum value to which the object can scroll.
[more]virtual void SetMax(double max)
Sets the maximum value to which the object can scroll.
[more]virtual void SetRange(double min, double max)
A shortcut for SetMin() and SetMax()
[more]virtual void SetPosition(double pos)
Sets the position of the scroll object.
[more]virtual void SetIncrement(double inc)
Sets the value by which the object can scroll.
[more]virtual void Setup(double min, double max, double pos, double inc)
A shortcut for all of the above functions
[more]virtual void Increment()
Increments the object's position by the increment value.
[more]virtual void Decrement()
Decrements the object's position by the increment value.
[more]virtual double GetMin()
Returns the minimum value of the scroll object
[more]virtual double GetMax()
Returns the maximum value of the scroll object
[more]virtual double GetRange()
Returns the scroll object's range (ie.
[more]virtual double GetPosition()
Returns the position of the scroll object
[more]virtual double GetIncrement()
Returns the increment value

Protected Fields

[more]double min
The minimum value the object can scroll to
[more]double max
The maximum value the object can scroll to
[more]double pos
The current position of the scroll object
[more]double inc
The increment value of the scroll object


Documentation

Implements the basic functionality of a widget that can scroll things. That's not a widget that can be scrolled, but a widget that does the scrolling! ScrollObject is quite generic so it works with doubles instead of ints like most scroll widgets (sliders, scrollers, etc.) so if you use it to scroll integer values, you'll have to do a bit of casting.
odouble min
The minimum value the object can scroll to

odouble max
The maximum value the object can scroll to

odouble pos
The current position of the scroll object

odouble inc
The increment value of the scroll object

ovirtual void SetMin(double min)
Sets the minimum value to which the object can scroll. Default is 0.

ovirtual void SetMax(double max)
Sets the maximum value to which the object can scroll. Default is 100.

ovirtual void SetRange(double min, double max)
A shortcut for SetMin() and SetMax()

ovirtual void SetPosition(double pos)
Sets the position of the scroll object. The position is clipped to the object's range. Default is 0.

ovirtual void SetIncrement(double inc)
Sets the value by which the object can scroll. Default is 1. Must be positive!

ovirtual void Setup(double min, double max, double pos, double inc)
A shortcut for all of the above functions

ovirtual void Increment()
Increments the object's position by the increment value. The new position is clipped by the maximum value.

ovirtual void Decrement()
Decrements the object's position by the increment value. The new position is clipped by the minimum value.

ovirtual double GetMin()
Returns the minimum value of the scroll object

ovirtual double GetMax()
Returns the maximum value of the scroll object

ovirtual double GetRange()
Returns the scroll object's range (ie. max - min).

ovirtual double GetPosition()
Returns the position of the scroll object

ovirtual double GetIncrement()
Returns the increment value


Direct child classes:
SpinBox
Scroller
Progress

Alphabetic index Hierarchy of classes


Back to front page   |   page generated with DOC++