Skip to content

Slider

Selects a numeric value within a continuous range.

<Slider ... />

Overview

This component is backed by the platform control or container. Prefer its XML tag in an .etlua template; keep view-tree construction out of controllers.

Topics

Properties

Name Type Required Description
action function optional Component-specific setting passed to the native control.
allowsTickMarkValuesOnly boolean optional Restricts slider values to tick marks when true.
disabled boolean optional Component-specific setting passed to the native control.
max number optional Component-specific setting passed to the native control.
min number optional Component-specific setting passed to the native control.
tickMarks table optional Slider tick mark positions.
tint string optional Semantic color filling the track, SwiftUI .tint.
style string optional level for an editable fill bar (a continuous capacity level indicator).
value table optional Current selected, edited, or measured value.

Example

<Slider />

Platform notes

  • AppKit uses the AppKit implementation. UIKit uses the UIKit implementation.

Source: lua/embedded/AppKit.lua:1863 (AppKit.Slider)