Class CurvedLinkReshapingTool
- Namespace
- Northwoods.Go.Tools.Extensions
- Assembly
- CurvedLinkReshapingWinForms.dll
This CurvedLinkReshapingTool class allows for a Link's path to be modified by the user via the dragging of a single tool handle at the middle of the link. Dragging the handle changes the value of Curviness.
public class CurvedLinkReshapingTool : LinkReshapingTool
- Inheritance
-
CurvedLinkReshapingTool
- Inherited Members
Constructors
CurvedLinkReshapingTool()
Constructs a CurvedLinkReshapingTool.
public CurvedLinkReshapingTool()
Methods
DoActivate()
Start reshaping, if FindToolHandleAt(Point, string) finds a reshape handle at the mouse down point.
public override void DoActivate()
Remarks
If successful this sets Handle to be the reshape handle that it finds and AdornedLink to be the Link being routed. It also remembers the original link route (a list of Points) and curviness in case this tool is cancelled. And it starts a transaction.
DoCancel()
Restore the link route to be the original points and curviness and stop this tool.
public override void DoCancel()
Reshape(Point)
Change the route of the AdornedLink by moving the point corresponding to the current Handle to be at the given Point.
public override void Reshape(Point newPoint)
Parameters
newPoint
Pointthe value of the call to Reshape(Point)
Remarks
This is called by DoMouseMove() and DoMouseUp() with the result of calling ComputeReshape(Point) to constrain the input point.