Slider
#
属性#
enabled
:(in bool):默认为 true。如果启用为 false,则无法与滑块交互。has-focus
:(out bool):当滑块当前具有焦点时设置为 truevalue
(inout float):值。minimum
(in float):最小值(默认值:0)maximum
(in float):最大值(默认值:100)orientation
(in enumOrientation
):如果设置为 true,则以垂直方式显示滑块(默认值:水平)。
回调#
changed(float)
:值已更改
示例#
import { Slider } from "std-widgets.slint";
export component Example inherits Window {
width: 200px;
height: 25px;
Slider {
width: parent.width;
height: parent.height;
value: 42;
}
}