# Rect¶

Structure representing a rectangle.

The structure has a width, height and a coordinate in a two-dimensional coordinate system.

## minX¶

Minimum X value.

The smallest x-coordinate in the rectangle.

``````minX: number
``````

## minY¶

Minimum Y value.

The smallest y-coordinate in the rectangle.

``````minY: number
``````

## maxX¶

Maximum X value.

The greatest x-coordinate in the rectangle.

``````maxX: number
``````

## maxY¶

Maximum Y value.

The greatest y-coordinate in the rectangle.

``````maxY: number
``````

## x¶

X value.

The x-coordinate of the rectangle.

``````x: number
``````

## y¶

Y value.

The y-coordinate of the rectangle.

``````y: number
``````

## width¶

Width of rectangle.

The width of the rectangle.

``````width: number
``````

## height¶

Height of rectangle.

The height of the rectangle.

``````height: number
``````

## origin¶

Point that specifies the rectangles origin.

The x- and y-coordinate that specifies the rectangles origin as a Point structure.

``````origin: Point
``````

## size¶

Size of the rectangle.

The width and height of the rectangle as a Size structure.

``````size: Size
``````

## -new Rect¶

Constructs a rectangle.

``````new Rect(x: number, y: number, width: number, height: number)
``````

Constructs a new rectangle placed in a two-dimensional coordinate system.

### Parameters¶

x
number
X coordinate.

y
number
Y coordinate.

width
number
Width of rectangle.

height
number
Height of rectangle.