Abstract base class for range-based controls.
|float||get_as_ratio ( ) const|
|void||set_as_ratio ( float value )|
|void||share ( Node with )|
|void||unshare ( )|
- changed ( )
This signal is emitted when min, max, range or step change.
- value_changed ( float value )
This signal is emitted when value changes.
- bool exp_edit - If
min_valueis greater than 0,
valuewill be represented exponentially rather than linearly.
- float max_value - Maximum value. Range is clamped if
valueis greater than
max_value. Default value: 100.
- float min_value - Minimum value. Range is clamped if
valueis less than
min_value. Default value: 0.
- float page - Page size. Used mainly for ScrollBar. ScrollBar’s length is its size multiplied by
pageover the difference between
- bool rounded - If
valuewill always be rounded to the nearest integer.
- float step - If greater than 0,
valuewill always be rounded to a multiple of
valuewill first be rounded to a multiple of
stepthen rounded to the nearest integer.
- float value - Range’s current value.
Member Function Description¶
- float get_as_ratio ( ) const
Return value mapped to 0 to 1 range.
- void set_as_ratio ( float value )
Set value mapped to 0 to 1 (unit) range, it will then be converted to the actual value within min and max.
Binds two Ranges together along with any Ranges previously grouped with either of them. When any of Range’s member variables change, it will share the new value with all other Ranges in its group.
Stop Range from sharing its member variables with any other Range.