The Developer Preview for Android 11 is now available; test it out and share your feedback.

TextGeometricTransform

@Immutable data class TextGeometricTransform
kotlin.Any
   ↳ androidx.ui.text.style.TextGeometricTransform

Define a geometric transformation on text.

Summary

Public constructors

<init>(scaleX: Float = 1.0f, skewX: Float = 0f)

Define a geometric transformation on text.

Inherited extension functions

From androidx.compose
operator T

IMPORTANT: This global operator is TEMPORARY, and should be removed whenever an answer for contextual composers is reached.

Properties

Float

The scale of the text on the horizontal direction.

Float

The shear of the text on the horizontal direction.

Public constructors

<init>

TextGeometricTransform(
    scaleX: Float = 1.0f,
    skewX: Float = 0f)

Define a geometric transformation on text.

Parameters
scaleX: Float = 1.0f The scale of the text on the horizontal direction. The default value is 1.0f, i.e no scaling.
skewX: Float = 0f The shear of the text on the horizontal direction. A pixel at (x, y), where y is the distance above baseline, will be transformed to (x + y * skewX, y). The default value is 0.0f i.e. no skewing.

Properties

scaleX

val scaleX: Float

The scale of the text on the horizontal direction. The default value is 1.0f, i.e no scaling.

skewX

val skewX: Float

The shear of the text on the horizontal direction. A pixel at (x, y), where y is the distance above baseline, will be transformed to (x + y * skewX, y). The default value is 0.0f i.e. no skewing.