|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Object | +--org.omegahat.Graphics.Primitives.RectRegionDescription
Class the provides a symbolic description of a rectangular region area for different coordinate systems, etc.
| Field Summary | |
protected UDouble |
height
|
protected int |
hJust
The horizontal justification, default LEFT. |
protected int |
vJust
The vertical justification, default BOTTOM. |
protected UDouble |
width
|
protected UDouble |
x
|
protected UDouble |
y
|
| Constructor Summary | |
RectRegionDescription()
Create the default region description that occupies all of its parent's space. |
|
RectRegionDescription(double x,
double y,
double width,
double height)
Specify the location and dimensions of the region being described, assuming Normalized Parent Coordinates (NPC). |
|
RectRegionDescription(double x,
double y,
double width,
double height,
int unit)
Specify the location and dimensions of the region being described, using the specified unit type for all values. |
|
RectRegionDescription(UDouble x,
UDouble y,
UDouble width,
UDouble height)
Specify the location and dimension of the region description, allowing each to have its own unit. |
|
| Method Summary | |
RectRegion |
compute(ScaleInt sx,
ScaleInt sy,
int parentOrigin,
double widthCM,
double heightCM,
int fontSize,
GraphicalContainerInt parentId)
Compute the actual bounding box described by this region description in terms of the normalized dimensions of its parent container, that is NPC. |
UDouble |
getHeight()
Accessor for height field |
int |
getHJust()
Accessor for hJust field |
int |
getVJust()
Accessor for vJust field |
UDouble |
getWidth()
Accessor for width field |
UDouble |
getX()
Accessor for x field |
UDouble |
getY()
Accessor for y field |
double |
justifyX(double x,
double width)
return the x co-ordinate justifying a region of width across, using the internal horizontal justification of this object. |
double |
justifyY(double y,
double height)
return the y co-ordinate justifying a region of width across, using the internal vertical justification of this object. |
UDouble |
setHeight(UDouble value)
Accessor for setting height field |
int |
setHJust(int value)
Accessor for setting hJust field |
int |
setVJust(int value)
Accessor for setting vJust field |
UDouble |
setWidth(UDouble value)
Accessor for setting width field |
UDouble |
setX(UDouble value)
Accessor for setting x field |
UDouble |
setY(UDouble value)
Accessor for setting y field |
java.lang.String |
toString()
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
protected UDouble x
protected UDouble y
protected UDouble width
protected UDouble height
protected int hJust
Should only be set to one of the symbolic constants in class Justification.
protected int vJust
Should only be set to one of the symbolic constants in class Justification.
| Constructor Detail |
public RectRegionDescription()
public RectRegionDescription(double x,
double y,
double width,
double height)
public RectRegionDescription(double x,
double y,
double width,
double height,
int unit)
public RectRegionDescription(UDouble x,
UDouble y,
UDouble width,
UDouble height)
| Method Detail |
public RectRegion compute(ScaleInt sx,
ScaleInt sy,
int parentOrigin,
double widthCM,
double heightCM,
int fontSize,
GraphicalContainerInt parentId)
RegionDescriptionIntcompute in interface RegionDescriptionIntorg.omegahat.Graphics.Primitives.RegionDescriptionIntsx - parent container's horizontal ScaleInt object for transforming
coordinates in that space.sy - parent container's vertical ScaleInt object for transforming
coordinates in that space.
public double justifyX(double x,
double width)
public double justifyY(double y,
double height)
public int getHJust()
hJust fieldgetHJust in interface RegionDescriptionIntpublic int setHJust(int value)
hJust fieldsetHJust in interface RegionDescriptionIntpublic int getVJust()
vJust fieldgetVJust in interface RegionDescriptionIntpublic int setVJust(int value)
vJust fieldsetVJust in interface RegionDescriptionIntpublic UDouble getWidth()
width fieldgetWidth in interface RegionDescriptionIntpublic UDouble setWidth(UDouble value)
width fieldsetWidth in interface RegionDescriptionIntpublic UDouble getHeight()
height fieldgetHeight in interface RegionDescriptionIntpublic UDouble setHeight(UDouble value)
height fieldsetHeight in interface RegionDescriptionIntpublic UDouble getY()
y fieldgetY in interface RegionDescriptionIntpublic UDouble setY(UDouble value)
y fieldsetY in interface RegionDescriptionIntpublic UDouble getX()
x fieldgetX in interface RegionDescriptionIntpublic UDouble setX(UDouble value)
x fieldsetX in interface RegionDescriptionIntpublic java.lang.String toString()
toString in class java.lang.Object
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||