class ButtonColors


Represents the container and content colors used in buttons in different states.

Summary

Public constructors

ButtonColors(
    containerColor: Color,
    contentColor: Color,
    secondaryContentColor: Color,
    iconColor: Color,
    disabledContainerColor: Color,
    disabledContentColor: Color,
    disabledSecondaryContentColor: Color,
    disabledIconColor: Color
)

Public functions

ButtonColors
copy(
    containerColor: Color,
    contentColor: Color,
    secondaryContentColor: Color,
    iconColor: Color,
    disabledContainerColor: Color,
    disabledContentColor: Color,
    disabledSecondaryContentColor: Color,
    disabledIconColor: Color
)

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

open operator Boolean
equals(other: Any?)
open Int

Public properties

Color

The background color of this Button when enabled (overridden by the containerPainter parameter on ImageButton

Color

The content color of this Button when enabled.

Color

The background color of this Button when not enabled (overridden by the disabledContainerPainter parameter on ImageButton)

Color

The content color of this Button when not enabled.

Color

The content color of this Button when not enabled.

Color

The content color of this Button when not enabled.

Color

The content color of this Button when enabled.

Color

The content color of this Button when enabled.

Public constructors

ButtonColors

ButtonColors(
    containerColor: Color,
    contentColor: Color,
    secondaryContentColor: Color,
    iconColor: Color,
    disabledContainerColor: Color,
    disabledContentColor: Color,
    disabledSecondaryContentColor: Color,
    disabledIconColor: Color
)
Parameters
containerColor: Color

The background color of this Button when enabled (overridden by the containerPainter parameter on ImageButton

contentColor: Color

The content color of this Button when enabled.

secondaryContentColor: Color

The content color of this Button when enabled.

iconColor: Color

The content color of this Button when enabled.

disabledContainerColor: Color

The background color of this Button when not enabled (overridden by the disabledContainerPainter parameter on ImageButton)

disabledContentColor: Color

The content color of this Button when not enabled.

disabledSecondaryContentColor: Color

The content color of this Button when not enabled.

disabledIconColor: Color

The content color of this Button when not enabled.

Public functions

copy

fun copy(
    containerColor: Color = Color.Unspecified,
    contentColor: Color = Color.Unspecified,
    secondaryContentColor: Color = Color.Unspecified,
    iconColor: Color = Color.Unspecified,
    disabledContainerColor: Color = Color.Unspecified,
    disabledContentColor: Color = Color.Unspecified,
    disabledSecondaryContentColor: Color = Color.Unspecified,
    disabledIconColor: Color = Color.Unspecified
): ButtonColors

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

Parameters
containerColor: Color = Color.Unspecified

The background color of this Button when enabled

contentColor: Color = Color.Unspecified

The content color of this Button when enabled

secondaryContentColor: Color = Color.Unspecified

The content color of this Button when enabled

iconColor: Color = Color.Unspecified

The content color of this Button when enabled

disabledContainerColor: Color = Color.Unspecified

The background color of this Button when not enabled

disabledContentColor: Color = Color.Unspecified

The content color of this Button when not enabled

disabledSecondaryContentColor: Color = Color.Unspecified

The content color of this Button when not enabled

disabledIconColor: Color = Color.Unspecified

The content color of this Button when not enabled

equals

open operator fun equals(other: Any?): Boolean

hashCode

open fun hashCode(): Int

Public properties

containerColor

Added in 1.0.0-alpha36
val containerColorColor

The background color of this Button when enabled (overridden by the containerPainter parameter on ImageButton

contentColor

Added in 1.0.0-alpha36
val contentColorColor

The content color of this Button when enabled.

disabledContainerColor

Added in 1.0.0-alpha36
val disabledContainerColorColor

The background color of this Button when not enabled (overridden by the disabledContainerPainter parameter on ImageButton)

disabledContentColor

Added in 1.0.0-alpha36
val disabledContentColorColor

The content color of this Button when not enabled.

disabledIconColor

Added in 1.0.0-alpha36
val disabledIconColorColor

The content color of this Button when not enabled.

disabledSecondaryContentColor

Added in 1.0.0-alpha36
val disabledSecondaryContentColorColor

The content color of this Button when not enabled.

iconColor

Added in 1.0.0-alpha36
val iconColorColor

The content color of this Button when enabled.

secondaryContentColor

Added in 1.0.0-alpha36
val secondaryContentColorColor

The content color of this Button when enabled.