Class OpenTCSCreationTool
java.lang.Object
org.jhotdraw.beans.AbstractBean
org.jhotdraw.draw.tool.AbstractTool
org.jhotdraw.draw.tool.CreationTool
org.opentcs.guing.application.toolbar.OpenTCSCreationTool
- All Implemented Interfaces:
java.awt.event.KeyListener,java.awt.event.MouseListener,java.awt.event.MouseMotionListener,java.io.Serializable,java.lang.Cloneable,java.util.EventListener,org.jhotdraw.draw.tool.Tool
public class OpenTCSCreationTool
extends org.jhotdraw.draw.tool.CreationTool
A custom tool used to create
PointFigures and LocationFigures.- See Also:
- Serialized Form
-
Field Summary
Fields inherited from class org.jhotdraw.draw.tool.CreationTool
createdFigure, minimalSize, minimalSizeTreshold, presentationName, prototype, prototypeAttributes -
Constructor Summary
Constructors Constructor Description OpenTCSCreationTool(ActiveLayerProvider activeLayerProvider, org.jhotdraw.draw.Figure prototype)Creates a new instance. -
Method Summary
Modifier and Type Method Description protected org.jhotdraw.draw.FigurecreateFigure()voidmousePressed(java.awt.event.MouseEvent evt)Methods inherited from class org.jhotdraw.draw.tool.CreationTool
activate, creationFinished, deactivate, getAddedFigure, getCreatedFigure, getPrototype, isToolDoneAfterCreation, mouseDragged, mouseReleased, setToolDoneAfterCreation, updateCursorMethods inherited from class org.jhotdraw.draw.tool.AbstractTool
addToolListener, addUndoableEditListener, constrainPoint, constrainPoint, createActionMap, createInputMap, draw, editCopy, editCut, editDelete, editDuplicate, editPaste, fireAreaInvalidated, fireAreaInvalidated, fireBoundsInvalidated, fireToolDone, fireToolStarted, getActionMap, getDrawing, getEditor, getInputMap, getToolTipText, getView, isActive, keyPressed, keyReleased, keyTyped, maybeFireBoundsInvalidated, mouseClicked, mouseEntered, mouseExited, mouseMoved, removeToolListener, removeUndoableEditListener, setActionMap, setInputMap, supportsHandleInteraction, viewToDrawing
-
Constructor Details
-
OpenTCSCreationTool
@Inject public OpenTCSCreationTool(ActiveLayerProvider activeLayerProvider, org.jhotdraw.draw.Figure prototype)Creates a new instance.- Parameters:
activeLayerProvider- Provides the currently active layer.prototype- The figure to be used as a prototype.
-
-
Method Details
-
mousePressed
public void mousePressed(java.awt.event.MouseEvent evt)- Specified by:
mousePressedin interfacejava.awt.event.MouseListener- Overrides:
mousePressedin classorg.jhotdraw.draw.tool.CreationTool
-
createFigure
protected org.jhotdraw.draw.Figure createFigure()- Overrides:
createFigurein classorg.jhotdraw.draw.tool.CreationTool
-