IconButtonColors

Class

Android
public class IconButtonColors(
    public val containerColor: Color,
    public val contentColor: Color,
    public val disabledContainerColor: Color,
    public val disabledContentColor: Color,
)

Represents the container and content colors used in an icon button in different states.

  • See IconButtonDefaults.filledIconButtonColors and IconButtonDefaults.filledTonalIconButtonColors for the default colors used in a FilledIconButton.
  • See IconButtonDefaults.outlinedIconButtonColors for the default colors used in an OutlinedIconButton.

Parameters

containerColorthe background color of this icon button when enabled.
contentColorthe color of this icon when enabled.
disabledContainerColorthe background color of this icon button when not enabled.
disabledContentColorthe color of this icon when not enabled.

Functions

public fun copy(
        containerColor: Color = this.containerColor,
        contentColor: Color = this.contentColor,
        disabledContainerColor: Color = this.disabledContainerColor,
        disabledContentColor: Color = this.disabledContentColor,
    ): IconButtonColors

Returns a copy of this IconButtonColors, optionally overriding some of the values.

Parameters

containerColorthe background color of this icon button when enabled.
contentColorthe color of this icon when enabled.
disabledContainerColorthe background color of this icon button when not enabled.
disabledContentColorthe color of this icon when not enabled.