net.sourceforge.swtlayeredgraph.examples.graphsettings
Class SampleShape
java.lang.Object
net.sourceforge.swtlayeredgraph.LayerDrawable
net.sourceforge.swtlayeredgraph.examples.graphsettings.SampleShape
- All Implemented Interfaces:
- java.io.Serializable
public class SampleShape
- extends LayerDrawable
- Author:
- davija
- See Also:
- Serialized Form
Constructor Summary |
SampleShape(java.lang.Double x1,
java.lang.Double y1,
java.lang.Double x2,
java.lang.Double y2,
int color,
java.lang.String name)
|
Method Summary |
void |
draw(GCTransformer transformer)
Draws this object on the GC in the transformer. |
void |
drawHover(GCTransformer transformer)
Draws this object, as an object that has the mouse over it, on the GC in
the transformer. |
void |
drawSelected(GCTransformer transformer)
Draws this object, as a selected object, on the GC in the transformer. |
void |
handleMouseDown(org.eclipse.swt.widgets.Event e,
GraphPoint graphPoint)
Handles a mouse down event on this object. |
void |
move(java.lang.Double dx,
java.lang.Double dy,
CoordinateType type)
Moves the object by the specified x and y deltas. |
Methods inherited from class net.sourceforge.swtlayeredgraph.LayerDrawable |
addExtentChangeListener, addExtentPoint, addNameChangeListner, clearExtents, getExtents, getName, handleMouseDoubleClick, handleMouseMove, handleMouseUp, isDirty, isDrawable, isFocused, isGroup, isLayer, isSelected, isVisible, recalculateExtents, removeExtentChangeListener, removeNameChangeListener, setDirty, setFocused, setName, setSelected, setVisible |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ul
public GraphPoint ul
lr
public GraphPoint lr
SampleShape
public SampleShape(java.lang.Double x1,
java.lang.Double y1,
java.lang.Double x2,
java.lang.Double y2,
int color,
java.lang.String name)
draw
public void draw(GCTransformer transformer)
- Description copied from class:
LayerDrawable
- Draws this object on the GC in the transformer.
- Specified by:
draw
in class LayerDrawable
- Parameters:
transformer
- GC Transformer for the device to draw on.
drawHover
public void drawHover(GCTransformer transformer)
- Description copied from class:
LayerDrawable
- Draws this object, as an object that has the mouse over it, on the GC in
the transformer.
- Specified by:
drawHover
in class LayerDrawable
- Parameters:
transformer
- GC Transformer for the device to draw on.
drawSelected
public void drawSelected(GCTransformer transformer)
- Description copied from class:
LayerDrawable
- Draws this object, as a selected object, on the GC in the transformer.
- Specified by:
drawSelected
in class LayerDrawable
- Parameters:
transformer
- GC Transformer for the device to draw on.
move
public void move(java.lang.Double dx,
java.lang.Double dy,
CoordinateType type)
- Description copied from class:
LayerDrawable
- Moves the object by the specified x and y deltas. Deltas are passed in
the coordinate system specified by type.
- Specified by:
move
in class LayerDrawable
- Parameters:
dx
- X Deltady
- Y Deltatype
- Type of coordinate system for X & Y
handleMouseDown
public void handleMouseDown(org.eclipse.swt.widgets.Event e,
GraphPoint graphPoint)
- Description copied from class:
LayerDrawable
- Handles a mouse down event on this object.
- Overrides:
handleMouseDown
in class LayerDrawable
- Parameters:
e
- SWT Event that was fired.
Copyright © 2009. All Rights Reserved.