Class

RemoteTextUnit

Represents a TextUnit value (Sp or Em) backed by a RemoteFloat.

RevenueCat

RevenueCat

Add subscriptions to your apps in minutes

Ad Get started for free
Android
public class RemoteTextUnit
internal constructor(public val value: RemoteFloat, public val type: TextUnitType) :
    BaseRemoteState<TextUnit>()

Represents a TextUnit value (Sp or Em) backed by a RemoteFloat.

Functions

toPx

@RestrictTo(RestrictTo.Scope.LIBRARY_GROUP)
    public fun toPx(density: RemoteDensity): RemoteFloat

Converts this RemoteTextUnit to pixels using the provided density.


toPx

public fun toPx(): RemoteFloat

Converts this RemoteTextUnit to pixels using the screen's density.