IDiagramTool
This interface specifies the methods the diagram uses to control each tool and the methods used to handle the standard input events processed through the diagram.
Properties
public bool Active { get; set; }
value = iDiagramTool.Active
iDiagramTool.Active = value
Gets or sets whether this tool is started and is actively doing something.
public Diagram Diagram { get; set; }
value = iDiagramTool.Diagram
iDiagramTool.Diagram = value
Gets the Diagram for which this tool is handling input events.
Methods
public bool CanStart()
result = iDiagramTool.CanStart()
This predicate is used by the diagram to decide if this tool can be started.
Returns: true if the ToolManager can make this tool the current one and call the DoStart method
public void DoActivate()
iDiagramTool.DoActivate()
This method is called by the diagram after setting CurrentTool, to make the new tool active.
public void DoCancel()
iDiagramTool.DoCancel()
The diagram will call this method when the we wish to cancel the current tool's operation.
public void DoDeactivate()
iDiagramTool.DoDeactivate()
This method is called by the diagram on the old tool when CurrentTool is set to a new tool.
public void DoKeyDown(KeyEventArgs e)
iDiagramTool.DoKeyDown(e)
The diagram will call this method upon a key down event.
public void DoKeyUp(KeyEventArgs e)
iDiagramTool.DoKeyUp(e)
The diagram will call this method upon a key up event.
public void DoMouseDown()
iDiagramTool.DoMouseDown()
The diagram will call this method upon a mouse down event.
public void DoMouseMove()
iDiagramTool.DoMouseMove()
The diagram will call this method upon a mouse move event.
public void DoMouseUp()
iDiagramTool.DoMouseUp()
The diagram will call this method upon a mouse up event.
public void DoMouseWheel()
iDiagramTool.DoMouseWheel()
The diagram will call this method as the mouse wheel is rotated.
public void DoStart()
iDiagramTool.DoStart()
This method is called by the diagram when this tool becomes the current tool.
public void DoStop()
iDiagramTool.DoStop()
This method is called by the diagram when this tool stops being the current tool.
public void UpdateAdornments(Part part)
iDiagramTool.UpdateAdornments(part)
The diagram asks each tool to update any adornments the tool might use for a given part.
- part