🌈 Create new beautiful Compose Gradients with our new wesite ->
Class

TextStyle

Description of a text style for the Text composable.

Source set: Android
public class TextStyle(
    public val color: ColorProvider = TextDefaults.defaultTextColor,
    public val fontSize: TextUnit? = null,
    public val fontWeight: FontWeight? = null,
    public val fontStyle: FontStyle? = null,
    public val textAlign: TextAlign? = null,
    public val textDecoration: TextDecoration? = null,
    public val fontFamily: FontFamily? = null,
)

Description of a text style for the Text composable.

Parameters

color optionally specifies the color to use for the text, defaults to TextDefaults.defaultTextColor.
fontSize optionally specifies the size to use for the text, defaults to system when null.
fontWeight optionally specifies the weight to use for the text, defaults to system when null.
fontStyle optionally specifies style (such as italics) to use for the text, defaults to system when null.
textAlign optionally specifies the alignment to use for the text, defaults to start when. null.
textDecoration optionally specifies decorations (e.g. underline) to use for the text, defaults to none when null
fontFamily optionally specifies which font family to use for the text, defaults to system when null.

Functions

copy

Source set: Android
public fun copy(
        color: ColorProvider = this.color,
        fontSize: TextUnit? = this.fontSize,
        fontWeight: FontWeight? = this.fontWeight,
        fontStyle: FontStyle? = this.fontStyle,
        textAlign: TextAlign? = this.textAlign,
        textDecoration: TextDecoration? = this.textDecoration,
        fontFamily: FontFamily? = this.fontFamily,
    ): TextStyle

equals

Source set: Android
override fun equals(other: Any?): Boolean

hashCode

Source set: Android
override fun hashCode(): Int

toString

Source set: Android
override fun toString(): String