Button

@JvmName(name = "ButtonStatecffa97b99dc2_1")
fun UiScope.Button(label: StateSource<UiText>, width: Int = 150, enabled: Boolean = true, modifier: Modifier = Modifier.Empty, key: ElementKey<*>? = null)(source)
@JvmName(name = "ButtonState6e1d7e05cd68_1")
fun UiScope.Button(label: StateSource<String>, width: Int = 150, enabled: Boolean = true, modifier: Modifier = Modifier.Empty, key: ElementKey<*>? = null)(source)

Source-backed Button observing label at the next frame cutoff. Sources remain caller-owned; compatible nodes retain editing, focus, and scrolling state. Literal arguments keep their existing contracts. Equal source values do not re-evaluate this component. The complete modifier chain stays on the actual component; the wrapper delegates parent data and owns the sibling key. Keep sources and dedicated editing states outside observed callbacks. Evaluation and input failures follow ordinary runtime cleanup.


@JvmName(name = "ButtonStatecffa97b99dc2_2")
fun UiScope.Button(label: UiText, width: Int = 150, enabled: StateSource<Boolean>, modifier: Modifier = Modifier.Empty, key: ElementKey<*>? = null)(source)
@JvmName(name = "ButtonState6e1d7e05cd68_2")
fun UiScope.Button(label: String, width: Int = 150, enabled: StateSource<Boolean>, modifier: Modifier = Modifier.Empty, key: ElementKey<*>? = null)(source)

Source-backed Button observing enabled at the next frame cutoff. Sources remain caller-owned; compatible nodes retain editing, focus, and scrolling state. Literal arguments keep their existing contracts. Equal source values do not re-evaluate this component. The complete modifier chain stays on the actual component; the wrapper delegates parent data and owns the sibling key. Keep sources and dedicated editing states outside observed callbacks. Evaluation and input failures follow ordinary runtime cleanup.


@JvmName(name = "ButtonStatecffa97b99dc2_3")
fun UiScope.Button(label: StateSource<UiText>, width: Int = 150, enabled: StateSource<Boolean>, modifier: Modifier = Modifier.Empty, key: ElementKey<*>? = null)(source)
@JvmName(name = "ButtonState6e1d7e05cd68_3")
fun UiScope.Button(label: StateSource<String>, width: Int = 150, enabled: StateSource<Boolean>, modifier: Modifier = Modifier.Empty, key: ElementKey<*>? = null)(source)

Source-backed Button observing label, enabled at the next frame cutoff. Sources remain caller-owned; compatible nodes retain editing, focus, and scrolling state. Literal arguments keep their existing contracts. Equal source values do not re-evaluate this component. The complete modifier chain stays on the actual component; the wrapper delegates parent data and owns the sibling key. Keep sources and dedicated editing states outside observed callbacks. Evaluation and input failures follow ordinary runtime cleanup.


fun UiScope.Button(label: UiText, width: Int = 150, enabled: Boolean = true, modifier: Modifier = Modifier.Empty, key: ElementKey<*>? = null)(source)

Emits one fixed-height profile-backed button appearance and semantic surface.

The component does not install focus or activation implicitly. Compose onActivate with the same enabled state when primary pointer and focused Enter or Space presses represent one action, or use pointer modifiers for pointer-specific behavior.

Receiver

active owner-thread screen scope.

Parameters

label

unresolved button label.

width

requested logical width.

enabled

whether enabled appearance and semantics are used.

modifier

active behavior including caller-owned focus, activation, and pointer actions.

key

optional stable sibling identity.

Throws

when the label does not fit or width is incompatible with the profile.

when no runtime screen evaluation is active.


fun UiScope.Button(label: String, width: Int = 150, enabled: Boolean = true, modifier: Modifier = Modifier.Empty, key: ElementKey<*>? = null)(source)

Emits one literal fixed-height profile-backed button appearance and semantic surface.

Like the typed-label overload, this component installs neither focus nor activation.

Receiver

active owner-thread screen scope.

Parameters

label

literal converted to UiText.Literal.

width

requested logical width.

enabled

whether enabled appearance and semantics are used.

modifier

active behavior including caller-owned focus, activation, and pointer actions.

key

optional stable sibling identity.

Throws

when the label does not fit or width is incompatible with the profile.

when no runtime screen evaluation is active.