TonalPalette

A convenience class for retrieving colors that are constant in hue and chroma, but vary in tone.

Properties

Link copied to clipboard
open val chroma: Double
Link copied to clipboard
open val hue: Double
Link copied to clipboard
open val keyColor: Hct

Functions

Link copied to clipboard
open fun fromHct(hct: Hct): TonalPalette
Create tones using a HCT color.
Link copied to clipboard
open fun fromHueAndChroma(hue: Double, chroma: Double): TonalPalette
Create tones from a defined HCT hue and chroma.
Link copied to clipboard
open fun fromInt(argb: Int): TonalPalette
Create tones using the HCT hue and chroma from a color.
Link copied to clipboard
open fun getHct(tone: Double): Hct
Given a tone, use hue and chroma of palette to create a color, and return it as HCT.
Link copied to clipboard
open fun tone(tone: Int): Int
Create an ARGB color with HCT hue and chroma of this Tones instance, and the provided HCT tone.