public class Transform2D extends AnimatedWiredEdit implements GraphicsPanelEdit
RedoName, UndoName
Constructor and Description |
---|
Transform2D()
Creates a transform edit with no changes.
|
Transform2D(double sx,
double shy,
double shx,
double sy,
double tx,
double ty)
Creates a transform edit with given scaling, shearing and translation.
|
Transform2D(double sx,
double shy,
double shx,
double sy,
double tx,
double ty,
Shape shape,
int frames)
Creates a transform edit with given scaling, shearing, translation,
animation shape and number of frames.
|
Modifier and Type | Method and Description |
---|---|
boolean |
addEdit(UndoableEdit edit) |
WiredEdit |
copy(RecordPlot plot)
Creates a copy of the edit which is attached to the plot, and thus can be
(re/un)done.
|
Shape |
createTransformedShape(Component component,
Shape shape) |
String |
getPresentationName() |
protected Shape[] |
getShapes(Shape shape,
int steps)
Returns an array of 'frames' shapes deformed from the given initial
shape.
|
boolean |
isSupportedBy(GraphicsPanel p)
Returns true if this edit is supported by the given graphics panel.
|
protected void |
redoEdit() |
String |
toString()
Returns a string representation of the edit.
|
protected void |
undoEdit() |
endAnimation, getShape, showAnimation, startAnimation
getID, getRecordPlot, setRecordPlot
getFrames, getNextEdit, getParent, getPreviousEdit, redo, setNextEdit, setParent, setPreviousEdit, undo
die, getRedoPresentationName, getUndoPresentationName, isSignificant, replaceEdit
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
getID
canRedo, canUndo, die, getRedoPresentationName, getUndoPresentationName, isSignificant, replaceEdit
public Transform2D()
public Transform2D(double sx, double shy, double shx, double sy, double tx, double ty)
public Transform2D(double sx, double shy, double shx, double sy, double tx, double ty, Shape shape, int frames)
public WiredEdit copy(RecordPlot plot)
WiredEdit
protected Shape[] getShapes(Shape shape, int steps)
AnimatedWiredEdit
getShapes
in class AnimatedWiredEdit
public Shape createTransformedShape(Component component, Shape shape)
createTransformedShape
in class org.freehep.swing.undo.AnimatedEdit
public String getPresentationName()
getPresentationName
in interface UndoableEdit
getPresentationName
in class AbstractUndoableEdit
public boolean addEdit(UndoableEdit edit)
addEdit
in interface UndoableEdit
addEdit
in class AbstractUndoableEdit
public boolean isSupportedBy(GraphicsPanel p)
GraphicsPanelEdit
isSupportedBy
in interface GraphicsPanelEdit
p
- panel by which this edit will be handled.protected void redoEdit()
redoEdit
in class org.freehep.swing.undo.AnimatedEdit
protected void undoEdit()
undoEdit
in class org.freehep.swing.undo.AnimatedEdit
public String toString()
AnimatedWiredEdit
toString
in class AnimatedWiredEdit
Copyright © 1996-2014 FreeHEP. All Rights Reserved.