Class Slider

Namespace
Forma
Assembly
Forma.dll

Adjusts a numeric range by dragging a thumb or using the keyboard or mouse wheel.

public class Slider : Range, IAddChild<Control>, IAddChild, INotifyPropertyChanged, IDisposable
Inheritance
Slider
Implements
Derived
Inherited Members

Constructors

Slider(Orientation)

public Slider(Orientation orientation = Orientation.Horizontal)

Parameters

orientation Orientation

Properties

AccessibilityRole

public override AccessibilityRole AccessibilityRole { get; }

Property Value

AccessibilityRole

CustomStep

Godot-style keyboard/gamepad increment override; negative values fall back to Step.

public float CustomStep { get; set; }

Property Value

float

Editable

public bool Editable { get; set; }

Property Value

bool

Orientation

public Orientation Orientation { get; }

Property Value

Orientation

Scrollable

Enables mouse-wheel adjustment, matching Godot's Slider.scrollable property.

public bool Scrollable { get; set; }

Property Value

bool

TickCount

Number of evenly-spaced visual ticks; values below two draw no ticks.

public int TickCount { get; set; }

Property Value

int

TicksOnBorders

public bool TicksOnBorders { get; set; }

Property Value

bool

TicksPosition

public SliderTickPosition TicksPosition { get; set; }

Property Value

SliderTickPosition

Methods

GetCustomStep()

public float GetCustomStep()

Returns

float

GetMinimumSize()

public override Vector2 GetMinimumSize()

Returns

Vector2

GetTickRectangles()

Returns local tick rectangles for deterministic theme-independent validation.

public IReadOnlyList<Rectangle> GetTickRectangles()

Returns

IReadOnlyList<Rectangle>

SetCustomStep(float)

public void SetCustomStep(float customStep)

Parameters

customStep float

Events

DragEnded

Raised when a pointer drag ends; the argument reports whether the ratio actually changed, matching Godot's Slider.drag_ended(value_changed) signal.

public event Action<Slider, bool> DragEnded

Event Type

Action<Slider, bool>

DragStarted

Raised when a pointer drag begins, matching Godot's Slider.drag_started signal.

public event EventHandler DragStarted

Event Type

EventHandler