🌈 Create new beautiful Compose Gradients with our new wesite ->
Object

ElevatedToggleButtonDefaults

Contains default values used by ElevatedToggleButton.

Source set: Common
public object ElevatedToggleButtonDefaults

Contains default values used by ElevatedToggleButton.

Functions

colors

Source set: Common
@Composable
    public fun colors(): ToggleButtonColors

Creates a ToggleButtonColors that represents the default container and content colors used in a ElevatedToggleButton.

colors

Source set: Common
@Composable
    public fun colors(
        containerColor: Color = Color.Unspecified,
        contentColor: Color = Color.Unspecified,
        disabledContainerColor: Color = Color.Unspecified,
        disabledContentColor: Color = Color.Unspecified,
        checkedContainerColor: Color = Color.Unspecified,
        checkedContentColor: Color = Color.Unspecified,
    ): ToggleButtonColors

Creates a ToggleButtonColors that represents the default container and content colors used in a ElevatedToggleButton.

Parameters

containerColor the container color of this ElevatedToggleButton when enabled.
contentColor the content color of this ElevatedToggleButton when enabled.
disabledContainerColor the container color of this ElevatedToggleButton when not enabled.
disabledContentColor the content color of this ElevatedToggleButton when not enabled.
checkedContainerColor the container color of this ElevatedToggleButton when checked.
checkedContentColor the content color of this ElevatedToggleButton when checked.

elevation

Source set: Common
@Composable
    public fun elevation(
        defaultElevation: Dp = ElevatedButtonTokens.ContainerElevation,
        pressedElevation: Dp = ElevatedButtonTokens.PressedContainerElevation,
        focusedElevation: Dp = ElevatedButtonTokens.FocusedContainerElevation,
        hoveredElevation: Dp = ElevatedButtonTokens.HoveredContainerElevation,
        disabledElevation: Dp = ElevatedButtonTokens.DisabledContainerElevation,
    ): ToggleButtonElevation

Creates a ToggleButtonElevation that will animate between the provided values according to the Material specification for an ElevatedToggleButton.

Parameters

defaultElevation the elevation used when the ElevatedToggleButton is enabled, and has no other Interactions.
pressedElevation the elevation used when this ElevatedToggleButton is enabled and pressed.
focusedElevation the elevation used when the ElevatedToggleButton is enabled and focused.
hoveredElevation the elevation used when the ElevatedToggleButton is enabled and hovered.
disabledElevation the elevation used when the ElevatedToggleButton is not enabled.

Content updated: