Range

Abstract base class for range-based controls.

Range is a base class for Control nodes that change a floating-point value between a minimum and a maximum, using step and page, for example a ScrollBar.

@GodotBaseClass
struct Range {}

Members

Aliases

BaseClasses
alias BaseClasses = AliasSeq!(typeof(_GODOT_base), typeof(_GODOT_base).BaseClasses)
Undocumented in source.

Functions

getAsRatio
double getAsRatio()
getMax
double getMax()
getMin
double getMin()
getPage
double getPage()
getStep
double getStep()
getValue
double getValue()
isGreaterAllowed
bool isGreaterAllowed()
isLesserAllowed
bool isLesserAllowed()
isRatioExp
bool isRatioExp()
isUsingRoundedValues
bool isUsingRoundedValues()
opAssign
typeof(null) opAssign(typeof(null) n)
opEquals
bool opEquals(Range other)
opEquals
bool opEquals(typeof(null) n)
setAllowGreater
void setAllowGreater(bool allow)
setAllowLesser
void setAllowLesser(bool allow)
setAsRatio
void setAsRatio(double value)
setExpRatio
void setExpRatio(bool enabled)
setMax
void setMax(double maximum)
setMin
void setMin(double minimum)
setPage
void setPage(double pagesize)
setStep
void setStep(double step)
setUseRoundedValues
void setUseRoundedValues(bool enabled)
setValue
void setValue(double value)
share
void share(Node _with)

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.

toHash
size_t toHash()
unshare
void unshare()

Stops range from sharing its member variables with any other.

Mixins

__anonymous
mixin baseCasts
Undocumented in source.

Properties

allowGreater
bool allowGreater [@property getter]
bool allowGreater [@property setter]

If true, value may be greater than maxValue.

allowLesser
bool allowLesser [@property getter]
bool allowLesser [@property setter]

If true, value may be less than minValue.

expEdit
bool expEdit [@property getter]
bool expEdit [@property setter]

If true, and min_value is greater than 0, value will be represented exponentially rather than linearly.

maxValue
double maxValue [@property getter]
double maxValue [@property setter]

Maximum value. Range is clamped if value is greater than max_value.

minValue
double minValue [@property getter]
double minValue [@property setter]

Minimum value. Range is clamped if value is less than min_value.

page
double page [@property getter]
double page [@property setter]

Page size. Used mainly for ScrollBar. ScrollBar's length is its size multiplied by page over the difference between min_value and max_value.

ratio
double ratio [@property getter]
double ratio [@property setter]

The value mapped between 0 and 1.

rounded
bool rounded [@property getter]
bool rounded [@property setter]

If true, value will always be rounded to the nearest integer.

step
double step [@property getter]
double step [@property setter]

If greater than 0, value will always be rounded to a multiple of step. If rounded is also true, value will first be rounded to a multiple of step then rounded to the nearest integer.

value
double value [@property getter]
double value [@property setter]

Range's current value.

Static functions

_new
Range _new()

Construct a new instance of Range. Note: use memnew!Range instead.

Static variables

_classBindingInitialized
bool _classBindingInitialized;
Undocumented in source.

Structs

GDNativeClassBinding
struct GDNativeClassBinding
Undocumented in source.

Unions

__anonymous
union __anonymous
Undocumented in source.

Variables

_GODOT_internal_name
enum string _GODOT_internal_name;
Undocumented in source.

Mixed In Members

From mixin baseCasts

as
inout(To) as()
Undocumented in source. Be warned that the author may not have intended to support it.
as
inout(To) as()
Undocumented in source. Be warned that the author may not have intended to support it.
as
inout(ToRef) as()
Undocumented in source. Be warned that the author may not have intended to support it.
opCast
template opCast(To)
Undocumented in source.
opCast
template opCast(To)
Undocumented in source.
opCast
template opCast(ToRef)
Undocumented in source.
opCast
void* opCast()
Undocumented in source. Be warned that the author may not have intended to support it.
opCast
godot_object opCast()
Undocumented in source. Be warned that the author may not have intended to support it.
opCast
bool opCast()
Undocumented in source. Be warned that the author may not have intended to support it.

Meta