|
|
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectvisual.statik.AbstractTransformableContent
public abstract class AbstractTransformableContent
A partial implementation of the TransformableContent interface that keeps track of transformation information
| Field Summary | |
|---|---|
protected double |
angle
|
protected boolean |
relocated
|
protected boolean |
rerotated
|
protected boolean |
rescaled
|
protected double |
x
|
protected double |
xRotation
|
protected double |
xScale
|
protected double |
y
|
protected double |
yRotation
|
protected double |
yScale
|
| Constructor Summary | |
|---|---|
AbstractTransformableContent()
Default Constructor |
|
| Method Summary | |
|---|---|
protected java.awt.geom.AffineTransform |
getAffineTransform()
Get the (concatenated) AffineTransform |
java.awt.geom.Rectangle2D |
getBounds2D()
Returns a high precision bounding box of the appropriately transformed content |
abstract java.awt.geom.Rectangle2D |
getBounds2D(boolean transformed)
Returns a high precision bounding box of the Content either before or after it is transformed |
protected boolean |
isTransformationRequired()
Does this AbstractTransformableContent object need to be transformed before being used? |
void |
setLocation(double x,
double y)
Set the translation (required by TransformedContent) |
void |
setRotation(double angle,
double x,
double y)
Set the angle of rotation around the midpoint (required by TransformedContent) |
void |
setScale(double scale)
Set the scaling |
void |
setScale(double xScale,
double yScale)
Set the scaling (required by TransformedContent) |
protected void |
setTransformationRequired(boolean required)
Set whether this AbstractTransformableContent object needs to be transformed before being used |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface visual.statik.SimpleContent |
|---|
render |
| Field Detail |
|---|
protected boolean relocated
protected boolean rerotated
protected boolean rescaled
protected double angle
protected double xScale
protected double yScale
protected double x
protected double y
protected double xRotation
protected double yRotation
| Constructor Detail |
|---|
public AbstractTransformableContent()
| Method Detail |
|---|
protected java.awt.geom.AffineTransform getAffineTransform()
public java.awt.geom.Rectangle2D getBounds2D()
public abstract java.awt.geom.Rectangle2D getBounds2D(boolean transformed)
getBounds2D in interface TransformableContenttransformed - true to get the BB of the transformed content
public void setLocation(double x,
double y)
setLocation in interface TransformableContentx - The x posiitony - The y position
public void setRotation(double angle,
double x,
double y)
setRotation in interface TransformableContentangle - The rotation anglex - The x-coordinate of the point to rotate aroundy - The y-coordinate of the point to rotate around
public void setScale(double xScale,
double yScale)
setScale in interface TransformableContentxScale - The scaling in the horizontal dimensionyScale - The scaling in the vertical dimensionpublic void setScale(double scale)
scale - The scaling (in both dimensions)protected void setTransformationRequired(boolean required)
required - true to indicate that a transformation is requriedprotected boolean isTransformationRequired()
|
|
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||