# class Rectangle

#### package lime.math

Available on all platforms

### Constructor

###

`new (x:Float = 0, y:Float = 0, width:Float = 0, height:Float = 0)`

### Variables

###

`bottom:Float`

###

`bottomRight:Vector2`

###

`height:Float`

###

`left:Float`

###

`right:Float`

###

`size:Vector2`

###

`top:Float`

###

`topLeft:Vector2`

###

`width:Float`

###

`x:Float`

###

`y:Float`

### Methods

###

`__contract (x:Float, y:Float, width:Float, height:Float):Void`

###

`__expand (x:Float, y:Float, width:Float, height:Float):Void`

###

`clone ():Rectangle`

###

`contains (x:Float, y:Float):Bool`

###

`containsPoint (point:Vector2):Bool`

###

`containsRect (rect:Rectangle):Bool`

###

`copyFrom (sourceRect:Rectangle):Void`

###

`equals (toCompare:Rectangle):Bool`

###

`inflate (dx:Float, dy:Float):Void`

###

`inflatePoint (point:Vector2):Void`

###

`intersection (toIntersect:Rectangle):Rectangle`

###

`intersects (toIntersect:Rectangle):Bool`

###

`isEmpty ():Bool`

###

`offset (dx:Float, dy:Float):Void`

###

`offsetPoint (point:Vector2):Void`

###

`setEmpty ():Void`

###

`setTo (xa:Float, ya:Float, widtha:Float, heighta:Float):Void`

###

`transform (m:Matrix3):Rectangle`

###

`union (toUnion:Rectangle):Rectangle`