public class Rectangle extends Object implements Serializable
Modifier and Type | Field and Description |
---|---|
protected float |
height |
protected float |
width |
protected float |
x |
protected float |
y |
Constructor and Description |
---|
Rectangle(float width, float height) |
Rectangle(float x, float y, float width, float height) |
Rectangle(Rectangle rect) |
Modifier and Type | Method and Description |
---|---|
|
applyMargins(float topIndent, float rightIndent, float bottomIndent, float leftIndent, boolean reverse) |
Rectangle |
clone() |
Rectangle |
decreaseHeight(float extra) |
boolean |
equalsWithEpsilon(Rectangle that) |
boolean |
equalsWithEpsilon(Rectangle that, float eps) |
float |
getBottom()
Gets lly, the same to getY() .
|
static Rectangle |
getCommonRectangle(Rectangle... rectangles)
Calculates the common rectangle which includes all the input rectangles.
|
float |
getHeight() |
float |
getLeft()
Gets llx, the same: getX() .
|
float |
getRight()
Gets urx, the same to getX() + getWidth() .
|
float |
getTop()
Gets ury, the same to getY() + getHeight() .
|
float |
getWidth() |
float |
getX() |
float |
getY() |
Rectangle |
increaseHeight(float extra) |
boolean |
intersectsLine(float x1, float y1, float x2, float y2) |
Rectangle |
moveDown(float move) |
Rectangle |
moveLeft(float move) |
Rectangle |
moveRight(float move) |
Rectangle |
moveUp(float move) |
Rectangle |
setBbox(float llx, float lly, float urx, float ury) |
Rectangle |
setHeight(float height) |
Rectangle |
setWidth(float width) |
Rectangle |
setX(float x) |
Rectangle |
setY(float y) |
String |
toString() |
protected float x
protected float y
protected float width
protected float height
public Rectangle(float x, float y, float width, float height)
public Rectangle(float width, float height)
public Rectangle(Rectangle rect)
public static Rectangle getCommonRectangle(Rectangle... rectangles)
rectangles
- list of input rectangles.
public Rectangle setBbox(float llx, float lly, float urx, float ury)
public float getX()
public Rectangle setX(float x)
public float getY()
public Rectangle setY(float y)
public float getWidth()
public Rectangle setWidth(float width)
public float getHeight()
public Rectangle setHeight(float height)
public Rectangle increaseHeight(float extra)
public Rectangle decreaseHeight(float extra)
public float getLeft()
getX()
.
public float getRight()
getX() + getWidth()
.
public float getTop()
getY() + getHeight()
.
public float getBottom()
getY()
.
public Rectangle moveDown(float move)
public Rectangle moveUp(float move)
public Rectangle moveRight(float move)
public Rectangle moveLeft(float move)
publicRectangle> T applyMargins(float topIndent, float rightIndent, float bottomIndent, float leftIndent, boolean reverse)
public boolean intersectsLine(float x1, float y1, float x2, float y2)
public boolean equalsWithEpsilon(Rectangle that)
public boolean equalsWithEpsilon(Rectangle that, float eps)
Copyright © 1998–2016 iText Group NV. All rights reserved.