class TextButtonColors


Represents the container and content colors used in a text button in different states.

See TextButtonDefaults.filledTextButtonColors, TextButtonDefaults.filledTonalTextButtonColors, TextButtonDefaults.textButtonColors and TextButtonDefaults.outlinedTextButtonColors for TextButtonColors with different levels of emphasis.

Summary

Public constructors

TextButtonColors(
    containerColor: Color,
    contentColor: Color,
    disabledContainerColor: Color,
    disabledContentColor: Color
)

Public functions

TextButtonColors
copy(
    containerColor: Color,
    contentColor: Color,
    disabledContainerColor: Color,
    disabledContentColor: Color
)

Returns a copy of this TextButtonColors optionally overriding some of the values.

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

Public properties

Color

the background color of this text button when enabled.

Color

the content color of this text button when enabled.

Color

the background color of this text button when not enabled.

Color

the content color of this text button when not enabled.

Public constructors

TextButtonColors

TextButtonColors(
    containerColor: Color,
    contentColor: Color,
    disabledContainerColor: Color,
    disabledContentColor: Color
)
Parameters
containerColor: Color

the background color of this text button when enabled.

contentColor: Color

the content color of this text button when enabled.

disabledContainerColor: Color

the background color of this text button when not enabled.

disabledContentColor: Color

the content color of this text button when not enabled.

Public functions

copy

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

Returns a copy of this TextButtonColors optionally overriding some of the values.

Parameters
containerColor: Color = this.containerColor

the background color of this text button when enabled.

contentColor: Color = this.contentColor

the content color of this text button when enabled.

disabledContainerColor: Color = this.disabledContainerColor

the background color of this text button when not enabled.

disabledContentColor: Color = this.disabledContentColor

the content color of this text 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-alpha30
val containerColorColor

the background color of this text button when enabled.

contentColor

Added in 1.0.0-alpha30
val contentColorColor

the content color of this text button when enabled.

disabledContainerColor

Added in 1.0.0-alpha30
val disabledContainerColorColor

the background color of this text button when not enabled.

disabledContentColor

Added in 1.0.0-alpha30
val disabledContentColorColor

the content color of this text button when not enabled.