|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object java.util.AbstractCollection java.util.AbstractList fr.emn.lite.Lite fr.emn.lite.LiteGhost_old
pending: this doc is deprecated.
This object is a completely flat and independent Lite object, useful for direct manipulation.
A "source" Lite object is passed to its constructor. LiteGhost's asks its geometry to the source through the "getGhostPath" method (which can include children's geometry too).
LiteGhost provides "translate" and "zoom" methods. These methods don't change ghost's local transform (always equal to identity), but rather transforms the ghost geometry itself.
This is useful to avoid scale problems during mouse manipulation (for example when performing a zoom, then a translation).
Field Summary | |
protected java.awt.geom.Rectangle2D |
bounds
|
protected java.awt.geom.GeneralPath |
outline
|
protected Lite |
source
|
Fields inherited from class fr.emn.lite.Lite |
model, oldParent, parent, PICK_ACTIVEBOUNDS, PICK_ALL, PICK_DEEPEST, PICK_FIRST, PICK_GRAPHBOUNDS, PICK_INSIDE, PICK_INTER, PICK_MANIPULABLE, visible |
Fields inherited from class java.util.AbstractList |
modCount |
Constructor Summary | |
LiteGhost_old(Lite liteSource)
|
Method Summary | |
LiteGhost_old |
copy_old()
Copy (clone) the Ghost object |
LiteGhost |
copy()
Copy (clone) the Ghost object |
void |
doPaint(java.awt.Graphics2D g)
Include painting code here. |
java.awt.geom.Rectangle2D |
getBounds()
Returns the bounds of the Lite object in its own coordinate system. |
java.awt.geom.GeneralPath |
getPath()
|
java.awt.geom.AffineTransform |
getUserTransform()
Get transformations performed by the user |
boolean |
pick(java.awt.Graphics2D g,
java.awt.geom.Rectangle2D rect,
int strategy,
PickedList picked)
Picks this object with the specified strategy, and adds the results to the picked list. |
void |
setPath(java.awt.geom.GeneralPath path)
|
void |
setSource(Lite source)
Used when the ghost is created before its source (i.e. in copy & paste) |
void |
translate(double dx,
double dy)
|
void |
updateSource()
|
void |
zoom(java.awt.Point origin,
double scale)
|
void |
zoomCenter(double scale)
|
Methods inherited from class fr.emn.lite.Lite |
changeTransform, concatenate, context, dist, equals, get, getActiveBounds, getActiveBoundsFrom, getAncestor, getAncestor, getBoundsFrom, getBoundsFromNoCorrect, getChildrenGhostPath, getCommonAncestor, getGhost_old, getGhost, getGhostPath, getParent, getShadow, getTransform, getTransformFrom, getTransformNoCopy, isVisible, migrateBack, migrateTo, paint_old, paint, paintChildren, paintShadows, pickChildren, preConcatenate, setContext, setParent, setTransform, setVisible, size, toString, transformBounds |
Methods inherited from class java.util.AbstractList |
add, add, addAll, clear, hashCode, indexOf, iterator, lastIndexOf, listIterator, listIterator, remove, removeRange, set, subList |
Methods inherited from class java.util.AbstractCollection |
addAll, contains, containsAll, isEmpty, remove, removeAll, retainAll, toArray, toArray |
Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Methods inherited from interface java.util.List |
addAll, contains, containsAll, isEmpty, remove, removeAll, retainAll, toArray, toArray |
Field Detail |
protected Lite source
protected java.awt.geom.Rectangle2D bounds
protected java.awt.geom.GeneralPath outline
Constructor Detail |
public LiteGhost_old(Lite liteSource)
Method Detail |
public LiteGhost copy()
public LiteGhost_old copy_old()
public void doPaint(java.awt.Graphics2D g)
Lite
Call PaintChildren if Lite object is a container.
doPaint
in class Lite
public java.awt.geom.Rectangle2D getBounds()
Lite
getBounds
in class Lite
public java.awt.geom.GeneralPath getPath()
public java.awt.geom.AffineTransform getUserTransform()
public boolean pick(java.awt.Graphics2D g, java.awt.geom.Rectangle2D rect, int strategy, PickedList picked)
Lite
A picking strategy is a combination of a depth strategy and a geometrical strategy.
* Depth filters:
PICK_DEEPEST strategy : Deepest pickable children of this object (or the object itself if none) are added to the picked list. This is the default value.
PICK_FIRST strategy : First pickable children (or the object itself if pickable) are added to the picked list.
PICK_ALL strategy : All pickable objects are added to the list.
* Geometrical filters:
PICK_INTER strategy : Objects have to intersect the picking rectangle to be picked. This is the default value.
PICK_INSIDE strategy : Objects must be inside the picking rectangle to be picked. PICK_ACTIVEBOUNDS strategy PICK_GRAPHBOUNDS strategy * Semantic filters: PICK_MANIPULABLE strategy
pick
in class Lite
rect
- The picking rectanglestrategy
- The picking strategy to be used, i.e. a combination
of a depth strategy and a geometrical strategy. Default value (0) is
PICK_DEEPEST | PICK_INTER.picked
- if this argument is not null, picked objects are added
to the pick list.public void setPath(java.awt.geom.GeneralPath path)
public void setSource(Lite source)
public void translate(double dx, double dy)
public void updateSource()
public void zoom(java.awt.Point origin, double scale)
public void zoomCenter(double scale)
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |