Skip to content

StandardButton

import { StandardButton, VerticalBox } from "std-widgets.slint";
export component Example inherits Window {
VerticalBox {
StandardButton { kind: ok; }
StandardButton { kind: apply; }
StandardButton { kind: cancel; }
}
}
slint
std-widgets standardbutton example

The StandardButton looks like a button, but instead of customizing with text and icon, it can used one of the pre-defined kind and the text and icon will depend on the style.

bool default: false

Defaults to true. When false, the button can’t be pressed

bool (out) default: false

Set to true when the button currently has the focus

enum StandardButtonKind default: the first enum value

The kind of button, one of ok cancel, apply, close, reset, help, yes, no, abort, retry or ignore

StandardButton {
kind: ok;
}
slint

bool default: false

If set to true the button is displayed with the primary accent color.

bool (out) default: false

Set to true when the button is pressed.

Invoked when clicked: A finger or the left mouse button is pressed, then released on this element.

StandardButton {
clicked() => {
debug("Button clicked");
}
}
slint

© 2025 SixtyFPS GmbH