-
Notifications
You must be signed in to change notification settings - Fork 0
Range
Home | API by Category | Complete API Index | API Compatibility
| Field | Value |
|---|---|
| Full name | Electron2D.Range |
| Namespace | Electron2D |
| Kind | class |
| Category | UI and Text |
Provides a numeric value with minimum, maximum, step and ratio state.
public class Electron2D.Range : Electron2D.ControlRange is the shared base for controls such as Electron2D.Slider
and Electron2D.ProgressBar. It emits value_changed when
Electron2D.Range.Value changes through the normal setter.
This type is not synchronized. Create and mutate ranges on the main scene thread.
This type is available since Electron2D 0.1.0 Preview.
Electron2D.ProgressBarElectron2D.Slider
| Member | Kind | Summary |
|---|---|---|
AllowGreater |
Property | Gets or sets whether values above Electron2D.Range.MaxValue are allowed. |
AllowLesser |
Property | Gets or sets whether values below Electron2D.Range.MinValue are allowed. |
ExpEdit |
Property | Gets or sets whether exponential editing is requested by UI controls. |
MaxValue |
Property | Gets or sets the maximum value. |
MinValue |
Property | Gets or sets the minimum value. |
Page |
Property | Gets or sets the page size associated with this range. |
Ratio |
Property | Gets or sets the value as a ratio between minimum and maximum. |
Rounded |
Property | Gets or sets whether values are rounded to integers after step snapping. |
Step |
Property | Gets or sets the step used when snapping values. |
Value |
Property | Gets or sets the current value. |
Electron2D.Range() |
Constructor | Initializes a new instance of the Electron2D.Range class. |
SetValueNoSignal(System.Double) |
Method | Sets Electron2D.Range.Value without emitting value_changed. |
Kind: Property
public System.Boolean AllowGreater { get; set; }Gets or sets whether values above Electron2D.Range.MaxValue are allowed.
Disabling this property clamps the current value if needed.
true to allow greater values; otherwise, false.
This property is not synchronized. Mutate it on the main scene thread.
This property is available since Electron2D 0.1.0 Preview.
Electron2D.Range.AllowLesser
Kind: Property
public System.Boolean AllowLesser { get; set; }Gets or sets whether values below Electron2D.Range.MinValue are allowed.
Disabling this property clamps the current value if needed.
true to allow lesser values; otherwise, false.
This property is not synchronized. Mutate it on the main scene thread.
This property is available since Electron2D 0.1.0 Preview.
Electron2D.Range.AllowGreater
Kind: Property
public System.Boolean ExpEdit { get; set; }Gets or sets whether exponential editing is requested by UI controls.
The preview stores this flag for API consumers; slider input remains linear.
true when exponential editing is requested; otherwise, false.
This property is not synchronized. Mutate it on the main scene thread.
This property is available since Electron2D 0.1.0 Preview.
Electron2D.Slider
Kind: Property
public System.Double MaxValue { get; set; }Gets or sets the maximum value.
If assigned below Electron2D.Range.MinValue, the minimum is moved to the same value.
The upper bound used by Electron2D.Range.Value and Electron2D.Range.Ratio.
-
System.ArgumentOutOfRangeException: Thrown when the value is not finite.
This property is not synchronized. Mutate it on the main scene thread.
This property is available since Electron2D 0.1.0 Preview.
Electron2D.Range.MinValue
Kind: Property
public System.Double MinValue { get; set; }Gets or sets the minimum value.
If assigned above Electron2D.Range.MaxValue, the maximum is moved to the same value.
The lower bound used by Electron2D.Range.Value and Electron2D.Range.Ratio.
-
System.ArgumentOutOfRangeException: Thrown when the value is not finite.
This property is not synchronized. Mutate it on the main scene thread.
This property is available since Electron2D 0.1.0 Preview.
Electron2D.Range.MaxValue
Kind: Property
public System.Double Page { get; set; }Gets or sets the page size associated with this range.
The preview stores page size for API consumers; sliders do not render page indicators.
A finite non-negative page value.
-
System.ArgumentOutOfRangeException: Thrown when the assigned value is negative or not finite.
This property is not synchronized. Mutate it on the main scene thread.
This property is available since Electron2D 0.1.0 Preview.
Electron2D.Range
Kind: Property
public System.Double Ratio { get; set; }Gets or sets the value as a ratio between minimum and maximum.
Assigning this property maps the ratio to Electron2D.Range.Value.
A value in the range 0.0 through 1.0.
-
System.ArgumentOutOfRangeException: Thrown when the assigned value is not finite.
This property is not synchronized. Mutate it on the main scene thread.
This property is available since Electron2D 0.1.0 Preview.
Electron2D.Range.Value
Kind: Property
public System.Boolean Rounded { get; set; }Gets or sets whether values are rounded to integers after step snapping.
Rounding uses midpoint-away-from-zero behavior.
true to round values; otherwise, false.
This property is not synchronized. Mutate it on the main scene thread.
This property is available since Electron2D 0.1.0 Preview.
Electron2D.Range.Value
Kind: Property
public System.Double Step { get; set; }Gets or sets the step used when snapping values.
Non-zero values snap to the nearest step from Electron2D.Range.MinValue.
0 to disable snapping, or a positive finite step.
-
System.ArgumentOutOfRangeException: Thrown when the assigned value is negative or not finite.
This property is not synchronized. Mutate it on the main scene thread.
This property is available since Electron2D 0.1.0 Preview.
Electron2D.Range.Value
Kind: Property
public System.Double Value { get; set; }Gets or sets the current value.
Changing this property emits value_changed when the normalized value changes.
The normalized value after clamping and snapping.
-
System.ArgumentOutOfRangeException: Thrown when the assigned value is not finite.
This property is not synchronized. Mutate it on the main scene thread.
This property is available since Electron2D 0.1.0 Preview.
Electron2D.Range.SetValueNoSignal(System.Double)
Kind: Constructor
public Electron2D.Range()Initializes a new instance of the Electron2D.Range class.
The constructor registers the value_changed signal.
This constructor is not synchronized. Call it from the main scene thread.
This constructor is available since Electron2D 0.1.0 Preview.
Electron2D.Range
Kind: Method
public System.Void SetValueNoSignal(System.Double)(System.Double value)Sets Electron2D.Range.Value without emitting value_changed.
The assigned value is still clamped and snapped.
-
value: The value to assign.
-
System.ArgumentOutOfRangeException: Thrown whenvalueis not finite.
This method is not synchronized. Call it on the main scene thread.
This method is available since Electron2D 0.1.0 Preview.
Electron2D.Range.Value
Electron2D 0.1.0 Preview API reference. Generated from 175 public runtime types.