Modifier and Type  Method and Description 

Rectangle 
Window.getBounds()
Returns the bounds  position and size  of the app's main window.

Rectangle 
Rectangle.intersection(Rectangle rect)
Returns a new rectangle which represents the intersection of the receiver
and the given rectangle.

Rectangle 
Rectangle.union(Rectangle rect)
Returns a new rectangle which represents the union of the receiver and
the given rectangle.

Modifier and Type  Method and Description 

void 
Rectangle.add(Rectangle rect)
Destructively replaces the x, y, width and height values in the receiver
with ones which represent the union of the rectangles specified by the
receiver and the given rectangle.

void 
Rectangle.intersect(Rectangle rect)
Destructively replaces the x, y, width and height values in the receiver
with ones which represent the intersection of the rectangles specified by
the receiver and the given rectangle.

Rectangle 
Rectangle.intersection(Rectangle rect)
Returns a new rectangle which represents the intersection of the receiver
and the given rectangle.

boolean 
Rectangle.intersects(Rectangle rect)
Returns
true if the given rectangle intersects with the
receiver and false otherwise. 
void 
Window.setBounds(Rectangle bounds)
Sets the bounds  position and size  of the app's main window.

Rectangle 
Rectangle.union(Rectangle rect)
Returns a new rectangle which represents the union of the receiver and
the given rectangle.
