#include <Scales.H>
|
static double | getVal (GtkRange *wid) |
|
Base class for the HScale and VScale classes.
This class operates by using the "<<" operator to load in the VScaleFuncData and HScaleFuncData classes, like so :
The scales can be set by locating the desired scale widget to set and then using the "=" operator :
- Examples:
- ScaleTest.C.
Definition at line 159 of file Scales.H.
◆ ~Scales()
virtual Scales::~Scales |
( |
void |
| ) |
|
|
inlinevirtual |
◆ drawValue()
Draw the value above the scale widget.
- Returns
- A reference to this scale class.
Definition at line 321 of file Scales.H.
◆ findIndex()
int Scales::findIndex |
( |
GtkWidget * |
widget | ) |
|
|
inline |
Find the GTK widget index (from 1) in the list of scales
- Parameters
-
widget | The widget to look for |
- Returns
- 0 if it isn't on the list, the index (from 1) otherwise
Definition at line 356 of file Scales.H.
◆ getLower()
double Scales::getLower |
( |
void |
| ) |
|
|
inline |
Get the lower range value.
- Returns
- The current lower value.
Definition at line 275 of file Scales.H.
◆ getStep()
double Scales::getStep |
( |
void |
| ) |
|
|
inline |
Get the stepping value of the scale widget.
- Returns
- the stepping value of the scale. If there are no scales, then return NaN
Definition at line 214 of file Scales.H.
◆ getUpper()
double Scales::getUpper |
( |
void |
| ) |
|
|
inline |
Set the upper range value.
- Returns
- The current upper value.
Definition at line 289 of file Scales.H.
◆ getVal() [1/2]
static double Scales::getVal |
( |
GtkRange * |
wid | ) |
|
|
inlinestatic |
Get the current value of the provided scale widget.
- Parameters
-
wid | The widget to get the position from |
- Returns
- the value the scale is set to.
- Examples:
- ScaleTest.C.
Definition at line 198 of file Scales.H.
◆ getVal() [2/2]
double Scales::getVal |
( |
void |
| ) |
|
|
inline |
Get the current value of the scale widget.
- Returns
- the value the scale is set to. If there are no scales, then return NaN
Definition at line 205 of file Scales.H.
◆ invert()
void Scales::invert |
( |
bool |
isInverted | ) |
|
|
inline |
Turn the scale upside down (Vertical scales) or flip left/right (Horizontal scales)
- Parameters
-
isInverted | True to invert, False to return to normal transposition |
Definition at line 405 of file Scales.H.
◆ operator<<() [1/2]
Create a horizontal scale widget
- Parameters
-
- Returns
- A reference to this scale class.
Definition at line 330 of file Scales.H.
◆ operator<<() [2/2]
Create a vertical scale widget
- Parameters
-
- Returns
- A reference to this scale class.
Definition at line 343 of file Scales.H.
◆ operator=() [1/2]
Scales& Scales::operator= |
( |
double |
pos | ) |
|
|
inline |
Set the scale to a particular value.
- Parameters
-
pos | The value to set the scale to. |
- Returns
- A reference to this scale class.
Definition at line 304 of file Scales.H.
◆ operator=() [2/2]
Scales& Scales::operator= |
( |
int |
pos | ) |
|
|
inline |
Set the scale to a particular value.
- Parameters
-
pos | The value to set the scale to. |
- Returns
- A reference to this scale class.
Definition at line 314 of file Scales.H.
◆ quantise()
void Scales::quantise |
( |
bool |
isQuantised | ) |
|
|
inline |
Quantise the scale to the step size. If the user slides it, then it is quantised to the closest step size increment.
Definition at line 394 of file Scales.H.
◆ quantiseVal()
static void Scales::quantiseVal |
( |
void * |
wid, |
|
|
void * |
data |
|
) |
| |
|
inlinestaticprivate |
Perform the quantisation of the widget
- Parameters
-
wid | The widget which caused this callback. |
data | The user data associated with that button press. |
Definition at line 178 of file Scales.H.
◆ setDigits()
void Scales::setDigits |
( |
double |
step | ) |
|
|
inlineprivate |
Auto-set the number of decimal points to display in the slider
- Parameters
-
step | The slider stepping factor between movements. |
Definition at line 164 of file Scales.H.
◆ setLower()
void Scales::setLower |
( |
double |
lower | ) |
|
|
inline |
Set the lower range value.
- Parameters
-
lower | The new lower value. |
Definition at line 244 of file Scales.H.
◆ setStep()
void Scales::setStep |
( |
double |
step | ) |
|
|
inline |
Set the stepping value of the scale widget.
- Parameters
-
step | the stepping value of the scale. |
Definition at line 229 of file Scales.H.
◆ setUpper()
void Scales::setUpper |
( |
double |
upper | ) |
|
|
inline |
Set the upper range value.
- Parameters
-
upper | The new upper value. |
Definition at line 260 of file Scales.H.
◆ signalConnectAfter()
connect a callback to execute after the currently connected callbacks
- Parameters
-
Definition at line 376 of file Scales.H.
◆ signalRemove()
disconnect the callback
- Parameters
-
Definition at line 384 of file Scales.H.
The documentation for this class was generated from the following file: