set

operator fun set(left: Float, top: Float, right: Float, bottom: Float)

Set the rectangle's coordinates to the specified values. Note: no range checking is performed, so it is up to the caller to ensure that left <= right and top <= bottom.

Parameters

left

The X coordinate of the left side of the rectangle

top

The Y coordinate of the top of the rectangle

right

The X coordinate of the right side of the rectangle

bottom

The Y coordinate of the bottom of the rectangle


fun set(src: RectF)
fun set(src: Rect)

Copy the coordinates from src into this rectangle.

Parameters

src

The rectangle whose coordinates are copied into this rectangle.