clampTo

fun clampTo(width: Int, height: Int): Rect

Returns this rectangle clamped to [0, width] x [0, height].