Class AbstractShapeTool
java.lang.Object
com.inductiveautomation.ignition.designer.designable.tools.AbstractDesignTool
com.inductiveautomation.factorypmi.designer.workspace.tools.AbstractShapeTool
- All Implemented Interfaces:
IDesignTool
- Direct Known Subclasses:
AbstractRectangularShapeTool,ArrowTool,PathEditorTool,PolygonTool
-
Nested Class Summary
Nested ClassesNested classes/interfaces inherited from interface com.inductiveautomation.ignition.designer.designable.IDesignTool
IDesignTool.ToolbarInitializer -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected PathBasedVisionShapeprotected Cursorprotected JComponentFields inherited from class com.inductiveautomation.ignition.designer.designable.tools.AbstractDesignTool
actionMap, changeSupport, designable, HANDLES_PROPERTY, inputMap, interactionLayer, panel, workspace -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected abstract Cursorprotected voidThe cursor to use given the current event mask, which can be used to detect what keys are being held downprotected abstract Class<? extends ShapeDelegate>protected abstract Stringprotected PathBasedVisionShapegetShape()protected booleanhandlesShape(ShapeDelegate shape) voidinstall(DesignPanel panel) Installs the tool for the given panel.booleanisRelevantFor(JComponent component) Gives the tool a chance to create a new selection control object to install handles on the selection.protected abstract ISelectionControlprotected abstract ShapeDelegatenewShapeDelegate(Rectangle2D rect) voidCalled when the user clicks in the design space.voidCalled while the user is dragging.voidCalled when the user stops dragging.voidonDragStart(Point startPoint, Point lastPoint, Rectangle r, int modifiers) Called when the user start's dragging while this tool is active.voidCalled when the user presses the mouse in the design space.protected static StringShortcut for:voidUninstalls the tool.protected voidprotected voidupdateToolbar(List<JComponent> selection) protected booleanvalidSelection(List<JComponent> selection) Methods inherited from class com.inductiveautomation.ignition.designer.designable.tools.AbstractDesignTool
addAction, addKeyBinding, addKeyBinding, addPropertyChangeListener, createCursor, findDropContainer, getAction, getDragHighlight, getOffsettingBounds, getOriginalBounds, getStatusBarText, getToolbarInitializer, isInstalled, itemMovable, movable, newToolbarSpinner, newToolbarSpinner, newToolbarSpinner, onClickAlterSelection, onDoubleClick, onKeyEvent, onMove, onPopupTrigger, onRelease, onRightClickSwitchToSelectionTool, removePropertyChangeListener
-
Field Details
-
dropContainer
-
addingShape
-
cursor
-
-
Constructor Details
-
AbstractShapeTool
public AbstractShapeTool()
-
-
Method Details
-
tt
Shortcut for:"<html>" + BundleUtil.get().getString("fpmi." + key); -
install
Description copied from interface:IDesignToolInstalls the tool for the given panel. Tools are built to be re-used by repeatedly being installed and then uninstalled as tools get switched out.- Specified by:
installin interfaceIDesignTool- Overrides:
installin classAbstractDesignTool
-
uninstall
public void uninstall()Description copied from interface:IDesignToolUninstalls the tool.- Specified by:
uninstallin interfaceIDesignTool- Overrides:
uninstallin classAbstractDesignTool
-
isRelevantFor
- Overrides:
isRelevantForin classAbstractDesignTool
-
getShape
-
updateToolbar
-
updateToolbar
-
disableToolbar
protected void disableToolbar() -
createCursor
-
onPress
Description copied from interface:IDesignToolCalled when the user presses the mouse in the design space.- Specified by:
onPressin interfaceIDesignTool- Overrides:
onPressin classAbstractDesignTool- Parameters:
move- The point at which they pressed. Relative to the designable container.modifiers- A bitmask of modifiers. Comes fromInputEvent.getModifiersEx()
-
onClick
Description copied from interface:IDesignToolCalled when the user clicks in the design space.- Specified by:
onClickin interfaceIDesignTool- Overrides:
onClickin classAbstractDesignTool- Parameters:
p- The point at which they clicked. Relative to the designable container.modifiers- A bitmask of modifiers. Comes fromInputEvent.getModifiersEx()
-
getCursor
Description copied from interface:IDesignToolThe cursor to use given the current event mask, which can be used to detect what keys are being held down- Specified by:
getCursorin interfaceIDesignTool- Overrides:
getCursorin classAbstractDesignTool
-
onDragStart
Description copied from class:AbstractDesignToolCalled when the user start's dragging while this tool is active. All coordinates are relative to the interaction panel and are in zoomed space.- Specified by:
onDragStartin interfaceIDesignTool- Overrides:
onDragStartin classAbstractDesignTool
-
onDrag
Description copied from class:AbstractDesignToolCalled while the user is dragging. All coordinates are relative to the interaction panel and are in zoomed space.- Specified by:
onDragin interfaceIDesignTool- Overrides:
onDragin classAbstractDesignTool
-
onDragEnd
Description copied from class:AbstractDesignToolCalled when the user stops dragging. All coordinates are relative to the interaction panel and are in zoomed space.- Specified by:
onDragEndin interfaceIDesignTool- Overrides:
onDragEndin classAbstractDesignTool
-
newSelectionControl
Description copied from interface:IDesignToolGives the tool a chance to create a new selection control object to install handles on the selection. Called on the active tool when the selection changes or after a tool is first installed.- Specified by:
newSelectionControlin interfaceIDesignTool- Overrides:
newSelectionControlin classAbstractDesignTool
-
validSelection
-
handlesShape
-
newShapeControl
-
getDelegateType
-
newShapeDelegate
-
getNewShapeName
-