-
Notifications
You must be signed in to change notification settings - Fork 0
Slider
Home | API by Category | Complete API Index | API Compatibility
| Field | Value |
|---|---|
| Full name | Electron2D.Slider |
| Namespace | Electron2D |
| Kind | class |
| Category | UI and Text |
Provides an editable horizontal slider control.
public class Electron2D.Slider : Electron2D.RangeProfile: Electron2D 0.1.0 2D
Status: Supported / Parity verified
Out of profile: no
Godot reference: Slider
Editable horizontal Range control with pointer, touch, keyboard and gamepad value input.
Slider changes Electron2D.Range.Value from pointer, touch,
keyboard and gamepad input.
This type is not synchronized. Create and mutate sliders on the main scene thread.
This type is available since Electron2D 0.1.0 Preview.
Electron2D.Range
| Member | Kind | Summary |
|---|---|---|
Editable |
Property | Gets or sets whether user input can change the slider. |
Scrollable |
Property | Gets or sets whether wheel-like scrolling is allowed. |
Ticks |
Property | Gets or sets the number of visual ticks. |
TicksOnBorders |
Property | Gets or sets whether ticks are drawn on borders. |
Electron2D.Slider() |
Constructor | Initializes a new instance of the Electron2D.Slider class. |
_Draw() |
Method | Draws the slider track and fill. |
_GetMinimumSize() |
Method | Gets the minimum size requested by this slider. |
_GuiInput(Electron2D.InputEvent) |
Method | Handles GUI input routed to this slider. |
Kind: Property
public System.Boolean Editable { get; set; }Gets or sets whether user input can change the slider.
Programmatic assignments to Electron2D.Range.Value remain allowed.
true when input can edit Electron2D.Range.Value; 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.Boolean Scrollable { get; set; }Gets or sets whether wheel-like scrolling is allowed.
The preview stores this property for API consumers; wheel handling is not part of T-0069.
true when scroll input is allowed; 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.Editable
Kind: Property
public System.Int32 Ticks { get; set; }Gets or sets the number of visual ticks.
Tick rendering is not drawn in the preview visual style.
A non-negative tick count.
-
System.ArgumentOutOfRangeException: Thrown when the assigned value is negative.
This property is not synchronized. Mutate it on the main scene thread.
This property is available since Electron2D 0.1.0 Preview.
Electron2D.Slider.TicksOnBorders
Kind: Property
public System.Boolean TicksOnBorders { get; set; }Gets or sets whether ticks are drawn on borders.
The preview stores this property for API consumers.
true to include border ticks; 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.Ticks
Kind: Constructor
public Electron2D.Slider()Initializes a new instance of the Electron2D.Slider class.
The new slider can receive keyboard/gamepad focus and edit values.
This constructor is not synchronized. Call it from the main scene thread.
This constructor is available since Electron2D 0.1.0 Preview.
Electron2D.Slider
Kind: Method
public System.Void _Draw()()Draws the slider track and fill.
The preview drawing path uses rectangle primitives.
This callback is invoked on the main scene thread.
This method is available since Electron2D 0.1.0 Preview.
Electron2D.Range.Ratio
Kind: Method
public Electron2D.Vector2 _GetMinimumSize()()Gets the minimum size requested by this slider.
The minimum size does not depend on ticks in this preview.
A baseline horizontal slider size.
This callback is invoked on the main scene thread.
This method is available since Electron2D 0.1.0 Preview.
Electron2D.Control.GetMinimumSize
Kind: Method
public System.Void _GuiInput(Electron2D.InputEvent)(Electron2D.InputEvent inputEvent)Handles GUI input routed to this slider.
Input is ignored when Electron2D.Slider.Editable is false.
-
inputEvent: The input event delivered by the viewport.
This callback is invoked on the main scene thread.
This method is available since Electron2D 0.1.0 Preview.
Electron2D.Control._GuiInput(Electron2D.InputEvent)
Electron2D 0.1.0 Preview API reference. Generated from 175 public runtime types.