FloatingToolbarColors

Class

Common
@ExperimentalMaterial3ExpressiveApi
class FloatingToolbarColors(
    val toolbarContainerColor: Color,
    val toolbarContentColor: Color,
    val fabContainerColor: Color,
    val fabContentColor: Color,
)

Represents the container and content colors used in a the various floating toolbars.

Parameters

toolbarContainerColorthe container color for the floating toolbar.
toolbarContentColorthe content color for the floating toolbar
fabContainerColorthe container color for an adjacent floating action button.
fabContentColorthe content color for an adjacent floating action button

Functions

fun copy(
        toolbarContainerColor: Color = this.toolbarContainerColor,
        toolbarContentColor: Color = this.toolbarContentColor,
        fabContainerColor: Color = this.fabContainerColor,
        fabContentColor: Color = this.fabContentColor,
    ) =
        FloatingToolbarColors(
            toolbarContainerColor.takeOrElse { this.toolbarContainerColor },
            toolbarContentColor.takeOrElse { this.toolbarContentColor },
            fabContainerColor.takeOrElse { this.fabContainerColor },
            fabContentColor.takeOrElse { this.fabContentColor },
        )

Returns a copy of this IconToggleButtonColors, optionally overriding some of the values. This uses the Color.Unspecified to mean “use the value from the source”