com.vividsolutions.jump.workbench.ui.cursortool
Class MeasureTool

java.lang.Object
  extended bycom.vividsolutions.jump.workbench.ui.cursortool.AbstractCursorTool
      extended bycom.vividsolutions.jump.workbench.ui.cursortool.MultiClickTool
          extended bycom.vividsolutions.jump.workbench.ui.cursortool.MeasureTool
All Implemented Interfaces:
CursorTool, java.util.EventListener, java.awt.event.MouseListener, java.awt.event.MouseMotionListener

public class MeasureTool
extends MultiClickTool

A tool which displays cumlative length, angle and cumlative area of a linestring drawn on the screen.

Version:
1.0
Author:
Martin Davis

Nested Class Summary
 
Nested classes inherited from class com.vividsolutions.jump.workbench.ui.cursortool.AbstractCursorTool
AbstractCursorTool.Listener
 
Constructor Summary
MeasureTool()
           
 
Method Summary
protected  void gestureFinished()
           
 java.awt.Cursor getCursor()
           
 javax.swing.Icon getIcon()
           
 void mouseLocationChanged(java.awt.event.MouseEvent e)
           
 
Methods inherited from class com.vividsolutions.jump.workbench.ui.cursortool.MultiClickTool
add, cancelGesture, finishGesture, getCoordinates, getMetrics, getShape, isFinishingRelease, mouseDragged, mouseMoved, mousePressed, mouseReleased, setCloseRing, setMetricsDisplay, toArray
 
Methods inherited from class com.vividsolutions.jump.workbench.ui.cursortool.AbstractCursorTool
activate, add, allowSnapping, check, cleanup, clearShape, createCursor, createCursor, createStandardSnappingPolicies, deactivate, drawShapeXOR, drawShapeXOR, execute, fireGestureFinished, getColor, getName, getPanel, getSnapManager, getTaskFrame, getWorkbench, isGestureInProgress, isRightMouseButtonUsed, isRollingBackInvalidEdits, isShapeOnScreen, mouseClicked, mouseEntered, mouseExited, name, redrawShape, reportNothingToUndoYet, setColor, setFilling, setStroke, setStrokeWidth, setup, snap, snap, toString, wasControlPressed, wasShiftPressed, workbench, workbenchFrame
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

MeasureTool

public MeasureTool()
Method Detail

getIcon

public javax.swing.Icon getIcon()
Returns:
null to use a default icon

getCursor

public java.awt.Cursor getCursor()
Specified by:
getCursor in interface CursorTool
Overrides:
getCursor in class AbstractCursorTool

mouseLocationChanged

public void mouseLocationChanged(java.awt.event.MouseEvent e)
Overrides:
mouseLocationChanged in class MultiClickTool

gestureFinished

protected void gestureFinished()
Specified by:
gestureFinished in class AbstractCursorTool