Class RegionInfo
java.lang.Object
java.awt.geom.RectangularShape
java.awt.geom.Rectangle2D
java.awt.geom.Rectangle2D.Float
org.apache.batik.extension.svg.RegionInfo
- All Implemented Interfaces:
Shape, Serializable, Cloneable
This class holds the neccessary information to render a
<batik:flowRegion> that is defined within the <batik:flowRoot>
element. Namely it holds the bounds of the region and the desired
vertical alignment.
- Version:
- $Id$
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class Rectangle2D
Rectangle2D.Double, Rectangle2D.Float -
Field Summary
FieldsFields inherited from class Rectangle2D.Float
height, width, x, yFields inherited from class Rectangle2D
OUT_BOTTOM, OUT_LEFT, OUT_RIGHT, OUT_TOP -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionfloatGets the vertical alignment for this flow region.voidsetVerticalAlignment(float verticalAlignment) Sets the alignment position of the text within this flow region.Methods inherited from class Rectangle2D.Float
createIntersection, createUnion, getBounds2D, getHeight, getWidth, getX, getY, isEmpty, outcode, setRect, setRect, setRect, toStringMethods inherited from class Rectangle2D
add, add, add, contains, contains, equals, getPathIterator, getPathIterator, hashCode, intersect, intersects, intersectsLine, intersectsLine, outcode, setFrame, unionMethods inherited from class RectangularShape
clone, contains, contains, getBounds, getCenterX, getCenterY, getFrame, getMaxX, getMaxY, getMinX, getMinY, intersects, setFrame, setFrame, setFrameFromCenter, setFrameFromCenter, setFrameFromDiagonal, setFrameFromDiagonal
-
Field Details
-
verticalAlignment
private float verticalAlignment
-
-
Constructor Details
-
RegionInfo
public RegionInfo(float x, float y, float w, float h, float verticalAlignment)
-
-
Method Details
-
getVerticalAlignment
public float getVerticalAlignment()Gets the vertical alignment for this flow region.- Returns:
- the vertical alignment for this flow region. It will be 0.0 for top, 0.5 for middle and 1.0 for bottom.
-
setVerticalAlignment
public void setVerticalAlignment(float verticalAlignment) Sets the alignment position of the text within this flow region. The value must be 0.0 for top, 0.5 for middle and 1.0 for bottom.- Parameters:
verticalAlignment- the vertical alignment of the text.
-