From Xojo Documentation

You are currently browsing the old Xojo documentation site. Please visit the new Xojo documentation site!

Class (inherits from Object)

New in 2019r2

A way to represent an axis-aligned rectangular area. Rect can be used for window size/position, control size/position and drawing of controls.

Bottom Left Top
Center Origin VerticalCenter
Height Right Width
HorizontalCenter Size
Clone LocalPoint SplitVertical
Contains LocalRect Union
Intersection Offset
Intersects SplitHorizontal

Constructor(X As Double, Y As Double, Width As Double, Height As Double)

Constructor(origin as Point, size as Size)

Sample Code

Var myRect As New Rect(10, 10, 100, 50)

See Also

Canvas control; Window, ContainerControl, Point, Size classes.