{% setvar book_path %}/reference/androidx/_book.yaml{% endsetvar %} {% include "_shared/_reference-head-tags.html" %}

Rect.Companion

public static class Rect.Companion


Summary

Public methods

static final @NonNull Rect

A rectangle with left, top, right, and bottom edges all at zero.

Extension functions

static final @NonNull TwoWayConverter<@NonNull Rect, @NonNull AnimationVector4D>

A type converter that converts a Rect to a AnimationVector4D, and vice versa.

static final @NonNull Rect

Visibility threshold for Rect.

Public methods

getZero

public static final @NonNull Rect getZero()

A rectangle with left, top, right, and bottom edges all at zero.

Extension functions

VectorConvertersKt.getVectorConverter

public static final @NonNull TwoWayConverter<@NonNull Rect, @NonNull AnimationVector4DVectorConvertersKt.getVectorConverter(@NonNull Rect.Companion receiver)

A type converter that converts a Rect to a AnimationVector4D, and vice versa.

VisibilityThresholdsKt.getVisibilityThreshold

public static final @NonNull Rect VisibilityThresholdsKt.getVisibilityThreshold(
    @NonNull Rect.Companion receiver
)

Visibility threshold for Rect. This defines the amount of value change that is considered to be no longer visible. The animation system uses this to signal to some default spring animations to stop when the value is close enough to the target.