ChipStyle


@ExperimentalCarApi
@CarProtocol
@RequiresCarApi(value = 9)
class ChipStyle


Defines the visual style of a Chip.

This style can be used to customize the appearance of the chip, such as its background and content colors.

This style can be set on both the ChipSection to apply to all chips, and/or individually to a single Chip. A common usage pattern is to set a default style on the Section, then override the style of the individual "selected" Chips. Remember that these colors will fall back to host defaults if they are unset or they fail contrast checks.

Summary

Nested types

A builder of ChipStyle.

Public functions

Boolean
equals(other: Any?)
CarColor?

Returns the background color of the chip, or null if not set.

CarColor?

Returns the content color of the chip, or null if not set.

CarColor?

Returns the stroke color of the chip, or null if not set.

Int
String

Public functions

equals

fun equals(other: Any?): Boolean

getBackgroundColor

Added in 1.8.0-beta01
fun getBackgroundColor(): CarColor?

Returns the background color of the chip, or null if not set.

getContentColor

Added in 1.8.0-beta01
fun getContentColor(): CarColor?

Returns the content color of the chip, or null if not set.

getOutlineColor

Added in 1.8.0-beta01
fun getOutlineColor(): CarColor?

Returns the stroke color of the chip, or null if not set.

hashCode

fun hashCode(): Int

toString

fun toString(): String