Package com.snowtide.pdf.layout
Class Rectangle
- java.lang.Object
 - 
- com.snowtide.pdf.layout.Rectangle
 
 
- 
- 
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description floatarea()The total area of this region.Regionbounds()Instances ofRegionwill always return themselves from theirboundsimplementations.floatby()The bottom edge of this region.static booleancontains(Region query, Region r)Returns true only ifris entirely contained withinquery.floatendxpos()floatendypos()floatheight()The total height of this region.static Rectangleintersection(Region... regions)Returns a Rectangle that is the intersection ofstartand all of the remaining provided Regions, or null if there is no common intersection.static booleanintersects(Region r1, Region r2)Returns true only if any portion of the two Regions intersect.floatlx()The left edge of this region.floatrx()The right edge of this region.StringtoString()floatty()The top edge of this region.static Rectangleunion(Region... regions)Returns aRectanglewhose coordinates represent the minimum bounding rectangle of all of the provided rectangles.floatwidth()The width of this region.floatxpos()floatypos() 
 - 
 
- 
- 
Constructor Detail
- 
Rectangle
public Rectangle(float x, float y, float x2, float y2) 
- 
Rectangle
public Rectangle(Region src)
 
 - 
 
- 
Method Detail
- 
width
public final float width()
Description copied from interface:RegionThe width of this region. 
- 
height
public final float height()
Description copied from interface:RegionThe total height of this region. 
- 
area
public final float area()
Description copied from interface:RegionThe total area of this region. 
- 
bounds
public Region bounds()
Description copied from interface:RegionInstances ofRegionwill always return themselves from theirboundsimplementations. 
- 
lx
public float lx()
Description copied from interface:RegionThe left edge of this region. 
- 
rx
public float rx()
Description copied from interface:RegionThe right edge of this region. 
- 
by
public float by()
Description copied from interface:RegionThe bottom edge of this region. 
- 
ty
public float ty()
Description copied from interface:RegionThe top edge of this region. 
- 
intersects
public static boolean intersects(Region r1, Region r2)
Returns true only if any portion of the two Regions intersect. 
- 
contains
public static boolean contains(Region query, Region r)
Returns true only ifris entirely contained withinquery. 
- 
union
public static final Rectangle union(Region... regions)
Returns aRectanglewhose coordinates represent the minimum bounding rectangle of all of the provided rectangles.- Throws:
 IllegalArgumentException- if no regions are provided
 
- 
intersection
public static Rectangle intersection(Region... regions)
Returns a Rectangle that is the intersection ofstartand all of the remaining provided Regions, or null if there is no common intersection.- Throws:
 IllegalArgumentException- if no regions are provided
 
 - 
 
 -