Class IndicatorTool
- java.lang.Object
-
- org.locationtech.jtstest.testbuilder.ui.tools.BasicTool
-
- org.locationtech.jtstest.testbuilder.ui.tools.IndicatorTool
-
- All Implemented Interfaces:
KeyListener,MouseListener,MouseMotionListener,MouseWheelListener,EventListener,Tool
- Direct Known Subclasses:
BoxBandTool,EditVertexTool,LineBandTool,MoveTool
public abstract class IndicatorTool extends BasicTool
-
-
Constructor Summary
Constructors Constructor Description IndicatorTool()IndicatorTool(Cursor cursor)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voidclearIndicator()protected ShapegetShape()Gets the shape for displaying the current state of the action.booleanisIndicatorVisible()Important for XOR drawing.voidmouseDragged(MouseEvent e)voidmouseMoved(MouseEvent e)protected voidredrawIndicator()-
Methods inherited from class org.locationtech.jtstest.testbuilder.ui.tools.BasicTool
activate, deactivate, geomModel, getCursor, getGraphics2D, gridSize, keyPressed, keyReleased, keyTyped, mouseClicked, mouseEntered, mouseExited, mousePressed, mouseReleased, mouseWheelMoved, panel, toModelSnapped, toModelSnappedIfCloseToViewGrid, toModelSnappedToViewGrid
-
-
-
-
Constructor Detail
-
IndicatorTool
public IndicatorTool()
-
IndicatorTool
public IndicatorTool(Cursor cursor)
-
-
Method Detail
-
getShape
protected Shape getShape()
Gets the shape for displaying the current state of the action. Subclasses should override.- Returns:
- null if nothing should be drawn
-
isIndicatorVisible
public boolean isIndicatorVisible()
Important for XOR drawing. Even if #getShape returns null, this method will return true between calls of #redrawShape and #clearShape.
-
clearIndicator
protected void clearIndicator()
-
redrawIndicator
protected void redrawIndicator()
-
mouseDragged
public void mouseDragged(MouseEvent e)
- Specified by:
mouseDraggedin interfaceMouseMotionListener- Overrides:
mouseDraggedin classBasicTool
-
mouseMoved
public void mouseMoved(MouseEvent e)
- Specified by:
mouseMovedin interfaceMouseMotionListener- Overrides:
mouseMovedin classBasicTool
-
-