public final class Rectangle
extends java.awt.Rectangle
Title: Rectangle class
Description:
Copyright (c) 2005-2013 by Steema Software SL. All Rights Reserved.
Company: Steema Software SL
Constructor and Description |
---|
Rectangle() |
Rectangle(int x,
int y,
int width,
int height) |
Rectangle(Point location,
Dimension size) |
Rectangle(Rectangle r) |
Rectangle(java.awt.Rectangle r) |
Modifier and Type | Method and Description |
---|---|
Point |
center()
Returns the center point of the rectangle
|
Rectangle |
copy() |
static Rectangle |
fromLTRB(int left,
int top,
int right,
int bottom) |
int |
getBottom()
Gets rectangle Bottom coordinate.
|
int |
getLeft()
Gets rectangle Left coordinate.
|
Point |
getLocation() |
int |
getRight()
Gets rectangle Right coordinate.
|
int |
getTop()
Gets rectangle Top coordinate.
|
void |
inflate(int horizontal,
int vertical) |
void |
intersect(Rectangle value) |
void |
offset(int w,
int h) |
void |
setBottom(int value)
Sets rectangle Bottom coordinate.
|
void |
setLeft(int value)
Sets rectangle Left coordinate.
|
void |
setRight(int value)
Sets rectangle Right coordinate.
|
void |
setTop(int value)
Sets rectangle Top coordinate.
|
add, add, add, contains, contains, contains, contains, createIntersection, createUnion, equals, getBounds, getBounds2D, getHeight, getSize, getWidth, getX, getY, grow, inside, intersection, intersects, isEmpty, move, outcode, reshape, resize, setBounds, setBounds, setLocation, setLocation, setRect, setSize, setSize, toString, translate, union
add, add, add, contains, contains, getPathIterator, getPathIterator, hashCode, intersect, intersects, intersectsLine, intersectsLine, outcode, setFrame, setRect, union
clone, contains, contains, getCenterX, getCenterY, getFrame, getMaxX, getMaxY, getMinX, getMinY, intersects, setFrame, setFrame, setFrameFromCenter, setFrameFromCenter, setFrameFromDiagonal, setFrameFromDiagonal
public static final Rectangle EMPTY
public Rectangle()
public Rectangle(int x, int y, int width, int height)
public Rectangle(Rectangle r)
public Rectangle(java.awt.Rectangle r)
public Point center()
public Rectangle copy()
public int getLeft()
public void setLeft(int value)
public int getRight()
public void setRight(int value)
public int getTop()
public void setTop(int value)
public int getBottom()
public void setBottom(int value)
public static Rectangle fromLTRB(int left, int top, int right, int bottom)
public void inflate(int horizontal, int vertical)
public void intersect(Rectangle value)
public void offset(int w, int h)
w
- h
- public Point getLocation()
getLocation
in class java.awt.Rectangle