public class MutableAffineTransformer extends AffineTransformer implements MutableTransformer, ShapeTransformer, ChangeEventSupport
Modifier and Type | Field and Description |
---|---|
protected ChangeEventSupport |
changeSupport |
inverse, transform
Constructor and Description |
---|
MutableAffineTransformer()
create an instance that does not transform points
|
MutableAffineTransformer(AffineTransform transform)
Create an instance with the supplied transform
|
Modifier and Type | Method and Description |
---|---|
void |
addChangeListener(ChangeListener l)
Adds a
ChangeListener . |
void |
concatenate(AffineTransform xform) |
void |
fireStateChanged()
Notifies all listeners that have registered interest for
notification on this event type.
|
ChangeListener[] |
getChangeListeners()
Returns an array of all the
ChangeListener s added
with addChangeListener(). |
void |
preConcatenate(AffineTransform xform) |
void |
removeChangeListener(ChangeListener l)
Removes a ChangeListener.
|
void |
rotate(double radians,
double x,
double y)
rotates the current transform at the supplied points
|
void |
rotate(double theta,
Point2D from)
preconcatenates the rotation at the supplied point with the current transform
|
void |
scale(double scalex,
double scaley,
Point2D from)
setter for the scale
fires a PropertyChangeEvent with the AffineTransforms representing
the previous and new values for scale and offset
|
void |
setScale(double scalex,
double scaley,
Point2D from)
setter for the scale
fires a PropertyChangeEvent with the AffineTransforms representing
the previous and new values for scale and offset
|
void |
setToIdentity() |
void |
setTranslate(double tx,
double ty)
replace the Transform's translate x and y values
with the passed values, leaving the scale values
unchanged
|
void |
shear(double shx,
double shy,
Point2D from)
shears the transform by passed parameters
|
String |
toString() |
void |
translate(double offsetx,
double offsety)
Apply the passed values to the current Transform
|
getInverse, getRotation, getScale, getScaleX, getScaleY, getShearX, getShearY, getTransform, getTranslateX, getTranslateY, inverseTransform, inverseTransform, setTransform, transform, transform
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
getRotation, getScale, getScaleX, getScaleY, getShearX, getShearY, getTransform, getTranslateX, getTranslateY
inverseTransform, transform
inverseTransform, transform
protected ChangeEventSupport changeSupport
public MutableAffineTransformer()
public MutableAffineTransformer(AffineTransform transform)
public String toString()
toString
in class AffineTransformer
public void scale(double scalex, double scaley, Point2D from)
scale
in interface MutableTransformer
scalex
- scaley
- public void setScale(double scalex, double scaley, Point2D from)
setScale
in interface MutableTransformer
scalex
- scaley
- public void shear(double shx, double shy, Point2D from)
shear
in interface MutableTransformer
shx
- x value to shearshy
- y value to shearpublic void setTranslate(double tx, double ty)
setTranslate
in interface MutableTransformer
tx
- the x valuety
- the y valuepublic void translate(double offsetx, double offsety)
translate
in interface MutableTransformer
offsetx
- the x-valueoffsety
- the y-valuepublic void rotate(double theta, Point2D from)
rotate
in interface MutableTransformer
public void rotate(double radians, double x, double y)
rotate
in interface MutableTransformer
public void concatenate(AffineTransform xform)
concatenate
in interface MutableTransformer
public void preConcatenate(AffineTransform xform)
preConcatenate
in interface MutableTransformer
public void addChangeListener(ChangeListener l)
ChangeListener
.addChangeListener
in interface ChangeEventSupport
l
- the listener to be addedpublic void removeChangeListener(ChangeListener l)
removeChangeListener
in interface ChangeEventSupport
l
- the listener to be removedpublic ChangeListener[] getChangeListeners()
ChangeListener
s added
with addChangeListener().getChangeListeners
in interface ChangeEventSupport
ChangeListener
s added or an empty
array if no listeners have been addedpublic void fireStateChanged()
fireStateChanged
in interface ChangeEventSupport
EventListenerList
public void setToIdentity()
setToIdentity
in interface MutableTransformer
Copyright © 2015. All rights reserved.