public class Anchor2D extends Overlay implements VtkPainter, java.lang.Runnable
Modifier and Type | Class and Description |
---|---|
static class |
Anchor2D.Anchor2DEvent |
static interface |
Anchor2D.Anchor2DListener
Deprecated.
Use
Anchor2D.Anchor2DPositionListener listener or OverlayListener |
static interface |
Anchor2D.Anchor2DPositionListener
Interface to listen Anchor2D position change
|
Overlay.OverlayPriority
Modifier and Type | Field and Description |
---|---|
static java.awt.Color |
DEFAULT_NORMAL_COLOR |
static int |
DEFAULT_RAY |
static java.awt.Color |
DEFAULT_SELECTED_COLOR |
static java.lang.String |
PROPERTY_COLOR |
static java.lang.String |
PROPERTY_RAY |
static java.lang.String |
PROPERTY_SELECTED |
static java.lang.String |
PROPERTY_SELECTEDCOLOR |
ID_CANBEREMOVED, ID_CLASSNAME, ID_ID, ID_NAME, ID_OVERLAY, ID_PRIORITY, ID_READONLY, ID_RECEIVEKEYEVENTONHIDDEN, ID_RECEIVEMOUSEEVENTONHIDDEN, LOD_SMALL, LOD_TINY, PROPERTY_CANBEREMOVED, PROPERTY_NAME, PROPERTY_PERSISTENT, PROPERTY_PRIORITY, PROPERTY_READONLY, PROPERTY_RECEIVEKEYEVENTONHIDDEN, PROPERTY_RECEIVEMOUSEEVENTONHIDDEN
Constructor and Description |
---|
Anchor2D() |
Anchor2D(double x,
double y) |
Anchor2D(double x,
double y,
java.awt.Color color) |
Anchor2D(double x,
double y,
java.awt.Color color,
java.awt.Color selectedColor) |
Anchor2D(double x,
double y,
int ray) |
Anchor2D(double x,
double y,
int ray,
java.awt.Color color) |
Anchor2D(double x,
double y,
int ray,
java.awt.Color color,
java.awt.Color selectedColor) |
Anchor2D(java.awt.geom.Point2D position)
Deprecated.
Use
Anchor2D(double, double) instead. |
Anchor2D(java.awt.geom.Point2D position,
java.awt.Color color)
Deprecated.
Use
Anchor2D(double, double, Color) instead. |
Anchor2D(java.awt.geom.Point2D position,
java.awt.Color color,
java.awt.Color selectedColor)
Deprecated.
Use
Anchor2D(double, double, Color, Color) instead. |
Anchor2D(java.awt.geom.Point2D position,
int ray)
Deprecated.
Use
Anchor2D(double, double, int) instead. |
Anchor2D(java.awt.geom.Point2D position,
int ray,
java.awt.Color color)
Deprecated.
Use
Anchor2D(double, double, int, Color) instead. |
Anchor2D(java.awt.geom.Point2D position,
int ray,
java.awt.Color color,
java.awt.Color selectedColor)
Deprecated.
Use
Anchor2D(double, double, int, Color, Color) instead. |
Anchor2D(Sequence sequence)
Deprecated.
Use
Anchor2D() instead. |
Anchor2D(Sequence sequence,
double x,
double y)
Deprecated.
Use
Anchor2D(double, double) instead. |
Anchor2D(Sequence sequence,
double x,
double y,
java.awt.Color color)
Deprecated.
Use
Anchor2D(double, double, Color, Color) instead. |
Anchor2D(Sequence sequence,
double x,
double y,
java.awt.Color color,
java.awt.Color selectedColor)
Deprecated.
Use
Anchor2D(double, double, int) instead. |
Anchor2D(Sequence sequence,
double x,
double y,
int ray)
Deprecated.
Use
Anchor2D(double, double, int) instead. |
Anchor2D(Sequence sequence,
double x,
double y,
int ray,
java.awt.Color color,
java.awt.Color selectedColor)
Deprecated.
Use
Anchor2D(double, double, int, Color, Color) instead. |
Anchor2D(Sequence sequence,
java.awt.geom.Point2D position)
Deprecated.
Use
Anchor2D(double, double) instead. |
Anchor2D(Sequence sequence,
java.awt.geom.Point2D position,
java.awt.Color color)
Deprecated.
Use
Anchor2D(double, double, Color) instead. |
Anchor2D(Sequence sequence,
java.awt.geom.Point2D position,
java.awt.Color color,
java.awt.Color selectedColor)
Deprecated.
Use
Anchor2D(double, double, Color, Color) instead. |
Anchor2D(Sequence sequence,
java.awt.geom.Point2D position,
int ray)
Deprecated.
Use
Anchor2D(double, double, int) instead. |
Anchor2D(Sequence sequence,
java.awt.geom.Point2D position,
int ray,
java.awt.Color color)
Deprecated.
Use
Anchor2D(Point2D, int, Color) instead. |
Anchor2D(Sequence sequence,
java.awt.geom.Point2D position,
int ray,
java.awt.Color color,
java.awt.Color selectedColor)
Deprecated.
Use
Anchor2D(double, double, int, Color, Color) instead. |
Modifier and Type | Method and Description |
---|---|
void |
addAnchorListener(Anchor2D.Anchor2DListener listener)
Deprecated.
|
void |
addListener(Anchor2D.Anchor2DListener listener)
Deprecated.
|
void |
addPositionListener(Anchor2D.Anchor2DPositionListener listener) |
java.awt.Color |
getColor() |
java.awt.geom.Point2D |
getPosition() |
java.awt.geom.Point2D |
getPositionInternal()
Get anchor position (return the internal reference)
|
double |
getPositionX() |
double |
getPositionY() |
vtk.vtkProp[] |
getProps()
Returns the VTK actors for this painter.
|
int |
getRay() |
java.awt.Color |
getSelectedColor() |
double |
getX() |
double |
getY() |
int |
getZ() |
boolean |
isOver(IcyCanvas canvas,
double x,
double y) |
boolean |
isOver(IcyCanvas canvas,
java.awt.geom.Point2D imagePoint)
Returns
true if specified Point3D is over the anchor in the specified canvas |
boolean |
isSelected() |
boolean |
isVisible() |
void |
keyPressed(java.awt.event.KeyEvent e,
java.awt.geom.Point2D imagePoint,
IcyCanvas canvas)
Deprecated.
|
void |
keyPressed(java.awt.event.KeyEvent e,
Point5D.Double imagePoint,
IcyCanvas canvas)
Key press event forwarded to the overlay.
|
void |
keyReleased(java.awt.event.KeyEvent e,
java.awt.geom.Point2D imagePoint,
IcyCanvas canvas)
Deprecated.
|
void |
keyReleased(java.awt.event.KeyEvent e,
Point5D.Double imagePoint,
IcyCanvas canvas)
Key release event forwarded to the overlay.
|
boolean |
loadFromXML(org.w3c.dom.Node node)
LOAD
|
boolean |
loadPositionFromXML(org.w3c.dom.Node node) |
void |
mouseDrag(java.awt.event.MouseEvent e,
java.awt.geom.Point2D imagePoint,
IcyCanvas canvas)
Deprecated.
|
void |
mouseDrag(java.awt.event.MouseEvent e,
Point5D.Double imagePoint,
IcyCanvas canvas)
Mouse drag event forwarded to the overlay.
|
void |
mouseMove(java.awt.event.MouseEvent e,
java.awt.geom.Point2D imagePoint,
IcyCanvas canvas)
Deprecated.
|
void |
mouseMove(java.awt.event.MouseEvent e,
Point5D.Double imagePoint,
IcyCanvas canvas)
Mouse move event forwarded to the overlay.
|
void |
mousePressed(java.awt.event.MouseEvent e,
java.awt.geom.Point2D imagePoint,
IcyCanvas canvas)
Deprecated.
|
void |
mousePressed(java.awt.event.MouseEvent e,
Point5D.Double imagePoint,
IcyCanvas canvas)
Mouse press event forwarded to the overlay.
|
void |
mouseReleased(java.awt.event.MouseEvent e,
java.awt.geom.Point2D imagePoint,
IcyCanvas canvas)
Deprecated.
|
void |
mouseReleased(java.awt.event.MouseEvent e,
Point5D.Double imagePoint,
IcyCanvas canvas)
Mouse release event forwarded to the overlay.
|
void |
moveTo(double x,
double y) |
void |
moveTo(java.awt.geom.Point2D p) |
void |
onChanged(CollapsibleEvent object)
fire changed event
|
void |
paint(java.awt.Graphics2D g,
Sequence sequence,
IcyCanvas canvas)
Paint method called to draw the overlay.
|
void |
paint(java.awt.Graphics2D g,
Sequence sequence,
IcyCanvas canvas,
boolean simplified) |
void |
removeAnchorListener(Anchor2D.Anchor2DListener listener)
Deprecated.
|
void |
removeListener(Anchor2D.Anchor2DListener listener)
Deprecated.
|
void |
removePositionListener(Anchor2D.Anchor2DPositionListener listener) |
void |
run() |
boolean |
savePositionToXML(org.w3c.dom.Node node) |
boolean |
saveToXML(org.w3c.dom.Node node)
SAVE
|
void |
setColor(java.awt.Color value) |
void |
setPosition(double x,
double y) |
void |
setPosition(java.awt.geom.Point2D p) |
void |
setRay(int value) |
void |
setSelected(boolean value) |
void |
setSelectedColor(java.awt.Color value) |
void |
setVisible(boolean value) |
void |
setX(double x) |
void |
setY(double y) |
void |
setZ(int value)
Set Z position (-1 = ALL)
|
void |
translate(double dx,
double dy) |
addOverlayListener, attachTo, beginUpdate, changed, compareTo, createFromXML, detachFrom, endUpdate, getAttachedCanvas, getCanBeRemoved, getName, getOptionsPanel, getOverlayCount, getPriority, getReceiveKeyEventOnHidden, getReceiveMouseEventOnHidden, getSequences, isAttached, isFixed, isPersistent, isReadOnly, isUpdating, loadFromXML, loadOverlaysFromXML, mouseClick, mouseClick, mouseEntered, mouseEntered, mouseExited, mouseExited, mouseWheelMoved, mouseWheelMoved, painterChanged, propertyChanged, remove, removeOverlayListener, saveOverlaysToXML, setCanBeRemoved, setFixed, setName, setPersistent, setPriority, setReadOnly, setReceiveKeyEventOnHidden, setReceiveMouseEventOnHidden
public static final int DEFAULT_RAY
public static final java.awt.Color DEFAULT_NORMAL_COLOR
public static final java.awt.Color DEFAULT_SELECTED_COLOR
public static final java.lang.String PROPERTY_COLOR
public static final java.lang.String PROPERTY_SELECTEDCOLOR
public static final java.lang.String PROPERTY_SELECTED
public static final java.lang.String PROPERTY_RAY
public Anchor2D(double x, double y, int ray, java.awt.Color color, java.awt.Color selectedColor)
public Anchor2D(double x, double y, int ray, java.awt.Color color)
public Anchor2D(double x, double y, int ray)
x
- y
- ray
- public Anchor2D(double x, double y, java.awt.Color color, java.awt.Color selectedColor)
x
- y
- color
- public Anchor2D(double x, double y, java.awt.Color color)
x
- y
- color
- public Anchor2D(double x, double y)
x
- y
- public Anchor2D()
@Deprecated public Anchor2D(java.awt.geom.Point2D position, int ray, java.awt.Color color, java.awt.Color selectedColor)
Anchor2D(double, double, int, Color, Color)
instead.@Deprecated public Anchor2D(java.awt.geom.Point2D position, int ray, java.awt.Color color)
Anchor2D(double, double, int, Color)
instead.@Deprecated public Anchor2D(java.awt.geom.Point2D position, int ray)
Anchor2D(double, double, int)
instead.@Deprecated public Anchor2D(java.awt.geom.Point2D position, java.awt.Color color, java.awt.Color selectedColor)
Anchor2D(double, double, Color, Color)
instead.@Deprecated public Anchor2D(java.awt.geom.Point2D position, java.awt.Color color)
Anchor2D(double, double, Color)
instead.@Deprecated public Anchor2D(java.awt.geom.Point2D position)
Anchor2D(double, double)
instead.@Deprecated public Anchor2D(Sequence sequence, double x, double y, int ray, java.awt.Color color, java.awt.Color selectedColor)
Anchor2D(double, double, int, Color, Color)
instead.@Deprecated public Anchor2D(Sequence sequence, java.awt.geom.Point2D position, int ray, java.awt.Color color, java.awt.Color selectedColor)
Anchor2D(double, double, int, Color, Color)
instead.@Deprecated public Anchor2D(Sequence sequence, java.awt.geom.Point2D position, int ray, java.awt.Color color)
Anchor2D(Point2D, int, Color)
instead.@Deprecated public Anchor2D(Sequence sequence, double x, double y, int ray)
Anchor2D(double, double, int)
instead.@Deprecated public Anchor2D(Sequence sequence, java.awt.geom.Point2D position, java.awt.Color color)
Anchor2D(double, double, Color)
instead.@Deprecated public Anchor2D(Sequence sequence, java.awt.geom.Point2D position, int ray)
Anchor2D(double, double, int)
instead.@Deprecated public Anchor2D(Sequence sequence, double x, double y, java.awt.Color color, java.awt.Color selectedColor)
Anchor2D(double, double, int)
instead.@Deprecated public Anchor2D(Sequence sequence, java.awt.geom.Point2D position, java.awt.Color color, java.awt.Color selectedColor)
Anchor2D(double, double, Color, Color)
instead.@Deprecated public Anchor2D(Sequence sequence, double x, double y, java.awt.Color color)
Anchor2D(double, double, Color, Color)
instead.@Deprecated public Anchor2D(Sequence sequence, double x, double y)
Anchor2D(double, double)
instead.@Deprecated public Anchor2D(Sequence sequence, java.awt.geom.Point2D position)
Anchor2D(double, double)
instead.@Deprecated public Anchor2D(Sequence sequence)
Anchor2D()
instead.public double getX()
public void setX(double x)
x
- the x to setpublic double getY()
public void setY(double y)
y
- the y to setpublic java.awt.geom.Point2D getPositionInternal()
public java.awt.geom.Point2D getPosition()
public double getPositionX()
public double getPositionY()
public void moveTo(java.awt.geom.Point2D p)
public void moveTo(double x, double y)
public void setPosition(java.awt.geom.Point2D p)
public void setPosition(double x, double y)
public void translate(double dx, double dy)
public int getZ()
public void setZ(int value)
public int getRay()
public void setRay(int value)
value
- the ray to setpublic java.awt.Color getColor()
public void setColor(java.awt.Color value)
value
- the color to setpublic java.awt.Color getSelectedColor()
public void setSelectedColor(java.awt.Color value)
value
- the selectedColor to setpublic boolean isSelected()
public void setSelected(boolean value)
value
- the selected to setpublic boolean isVisible()
public void setVisible(boolean value)
value
- the visible to setpublic vtk.vtkProp[] getProps()
VtkPainter
getProps
in interface VtkPainter
public boolean isOver(IcyCanvas canvas, java.awt.geom.Point2D imagePoint)
true
if specified Point3D is over the anchor in the specified canvaspublic void onChanged(CollapsibleEvent object)
ChangeListener
onChanged
in interface ChangeListener
onChanged
in class Overlay
public void addPositionListener(Anchor2D.Anchor2DPositionListener listener)
public void removePositionListener(Anchor2D.Anchor2DPositionListener listener)
@Deprecated public void addAnchorListener(Anchor2D.Anchor2DListener listener)
addPositionListener(Anchor2DPositionListener)
or
Overlay.addOverlayListener(OverlayListener)
instead.@Deprecated public void removeAnchorListener(Anchor2D.Anchor2DListener listener)
removePositionListener(Anchor2DPositionListener)
or
Overlay.removeOverlayListener(OverlayListener)
instead.@Deprecated public void addListener(Anchor2D.Anchor2DListener listener)
addPositionListener(Anchor2DPositionListener)
or
Overlay.addOverlayListener(OverlayListener)
instead.@Deprecated public void removeListener(Anchor2D.Anchor2DListener listener)
removePositionListener(Anchor2DPositionListener)
or
Overlay.removeOverlayListener(OverlayListener)
instead.public void paint(java.awt.Graphics2D g, Sequence sequence, IcyCanvas canvas, boolean simplified)
public void paint(java.awt.Graphics2D g, Sequence sequence, IcyCanvas canvas)
Overlay
@Deprecated public void keyPressed(java.awt.event.KeyEvent e, java.awt.geom.Point2D imagePoint, IcyCanvas canvas)
Painter
keyPressed
in interface Painter
keyPressed
in class Overlay
e
- key eventimagePoint
- mouse position (image coordinates)canvas
- icy canvas@Deprecated public void keyReleased(java.awt.event.KeyEvent e, java.awt.geom.Point2D imagePoint, IcyCanvas canvas)
Painter
keyReleased
in interface Painter
keyReleased
in class Overlay
e
- key eventimagePoint
- mouse position (image coordinates)canvas
- icy canvas@Deprecated public void mousePressed(java.awt.event.MouseEvent e, java.awt.geom.Point2D imagePoint, IcyCanvas canvas)
Painter
mousePressed
in interface Painter
mousePressed
in class Overlay
e
- mouse eventimagePoint
- mouse position (image coordinates)canvas
- icy canvas@Deprecated public void mouseReleased(java.awt.event.MouseEvent e, java.awt.geom.Point2D imagePoint, IcyCanvas canvas)
Painter
mouseReleased
in interface Painter
mouseReleased
in class Overlay
e
- mouse eventimagePoint
- mouse position (image coordinates)canvas
- icy canvas@Deprecated public void mouseDrag(java.awt.event.MouseEvent e, java.awt.geom.Point2D imagePoint, IcyCanvas canvas)
Painter
@Deprecated public void mouseMove(java.awt.event.MouseEvent e, java.awt.geom.Point2D imagePoint, IcyCanvas canvas)
Painter
public void keyPressed(java.awt.event.KeyEvent e, Point5D.Double imagePoint, IcyCanvas canvas)
Overlay
keyPressed
in class Overlay
e
- key eventimagePoint
- mouse position (image coordinates)canvas
- icy canvaspublic void keyReleased(java.awt.event.KeyEvent e, Point5D.Double imagePoint, IcyCanvas canvas)
Overlay
keyReleased
in class Overlay
e
- key eventimagePoint
- mouse position (image coordinates)canvas
- icy canvaspublic void mousePressed(java.awt.event.MouseEvent e, Point5D.Double imagePoint, IcyCanvas canvas)
Overlay
mousePressed
in class Overlay
e
- mouse eventimagePoint
- mouse position (image coordinates)canvas
- icy canvaspublic void mouseReleased(java.awt.event.MouseEvent e, Point5D.Double imagePoint, IcyCanvas canvas)
Overlay
mouseReleased
in class Overlay
e
- mouse eventimagePoint
- mouse position (image coordinates)canvas
- icy canvaspublic void mouseDrag(java.awt.event.MouseEvent e, Point5D.Double imagePoint, IcyCanvas canvas)
Overlay
public void mouseMove(java.awt.event.MouseEvent e, Point5D.Double imagePoint, IcyCanvas canvas)
Overlay
public void run()
run
in interface java.lang.Runnable
public boolean loadPositionFromXML(org.w3c.dom.Node node)
public boolean savePositionToXML(org.w3c.dom.Node node)
public boolean loadFromXML(org.w3c.dom.Node node)
XMLPersistent
loadFromXML
in interface XMLPersistent
loadFromXML
in class Overlay
public boolean saveToXML(org.w3c.dom.Node node)
XMLPersistent
saveToXML
in interface XMLPersistent
saveToXML
in class Overlay