public class LabelDragRenderer extends AbstractDragRenderer
ghostColor| Constructor and Description |
|---|
LabelDragRenderer()
create an instance, and presumably the mouse module will set the parent.
|
LabelDragRenderer(DasCanvasComponent parent)
create an instance.
|
| Modifier and Type | Method and Description |
|---|---|
protected void |
addDirtyBounds(java.awt.Rectangle dirty) |
protected void |
addDirtyBounds(java.awt.Rectangle[] dirty) |
void |
clear(java.awt.Graphics g)
this is not used, and is left over from an old version of the library.
|
protected java.awt.Rectangle[] |
getDirtyBounds() |
MouseDragEvent |
getMouseDragEvent(java.lang.Object source,
java.awt.Point p1,
java.awt.Point p2,
boolean isModified)
This method is called by the DMIA on mouse release.
|
boolean |
isPointSelection()
indicates that MM.mousePointSelected() should called as new mouse events
come in.
|
boolean |
isTooltip() |
boolean |
isUpdatingDragSelection()
range selection events should be fired during drag.
|
java.awt.Rectangle[] |
renderDrag(java.awt.Graphics g,
java.awt.Point p1,
java.awt.Point p2)
draws the drag for mousing from p1 to p2, and returns an array of
Rectangles covering the rendering.
|
protected void |
resetDirtyBounds() |
void |
setLabel(java.lang.String s)
set the label to be drawn.
|
void |
setTooltip(boolean tooltip) |
getParent, setParentpublic LabelDragRenderer(DasCanvasComponent parent)
parent - component sourcing the mouse events, typically a DasPlot.public LabelDragRenderer()
public void clear(java.awt.Graphics g)
AbstractDragRendererclear in interface DragRendererclear in class AbstractDragRendererg - the graphics contextpublic MouseDragEvent getMouseDragEvent(java.lang.Object source, java.awt.Point p1, java.awt.Point p2, boolean isModified)
getMouseDragEvent in interface DragRenderergetMouseDragEvent in class AbstractDragRendererp1 - the click pointp2 - the current mouse position during drag and release.public boolean isPointSelection()
AbstractDragRendererisPointSelection in interface DragRendererisPointSelection in class AbstractDragRendererpublic boolean isUpdatingDragSelection()
AbstractDragRendererisUpdatingDragSelection in interface DragRendererisUpdatingDragSelection in class AbstractDragRendererpublic void setLabel(java.lang.String s)
s - the label, which can contain Granny control sequences like !A and !n.http://autoplot.org/help#Granny_Stringspublic java.awt.Rectangle[] renderDrag(java.awt.Graphics g,
java.awt.Point p1,
java.awt.Point p2)
DragRendererg - the graphics context for renderingp1 - the click pointp2 - the current mouse position during drag and release.protected void resetDirtyBounds()
protected void addDirtyBounds(java.awt.Rectangle[] dirty)
protected void addDirtyBounds(java.awt.Rectangle dirty)
protected java.awt.Rectangle[] getDirtyBounds()
public boolean isTooltip()
public void setTooltip(boolean tooltip)