FontVariation.Setting


Represents a single point in a variation, such as 0.7 or 100

Summary

Public functions

Float

Convert a value to a final value for use as a font variation setting.

Cmn

Public properties

String

The font variation axis, such as 'wdth' or 'ital'

Cmn
Boolean

True if this setting requires density to resolve

Cmn

Public functions

toVariationValue

fun toVariationValue(density: Density?): Float

Convert a value to a final value for use as a font variation setting.

If needsDensity is false, density may be null

Parameters
density: Density?

to resolve from Compose types to feature-specific ranges.

Public properties

axisName

val axisNameString

The font variation axis, such as 'wdth' or 'ital'

needsDensity

val needsDensityBoolean

True if this setting requires density to resolve

When false, may toVariationValue may be called with null or any Density