RotatingTool
The RotatingTool is used to interactively change the angle of an element.
Erbt von: DiagramTool
Eigenschaften
AdornedElement : FrameworkElement
Gets or sets the current FrameworkElement that is being rotated.
AdornedNode : Node
Gets the current Node that the AdornedElement is in.
Handle : FrameworkElement
Gets or sets the current rotate handle that is being dragged.
OriginalAngle : double
Gets or sets the angle of the AdornedElement when the user started rotating.
RotationPoint : Point
Gets or sets the point around which the element is being rotated.
SnapAngleEpsilon : double
Gets or sets the closeness to a desired angle at which the angle is "snapped to".
SnapAngleMultiple : double
Gets or sets the preferred angles for the selected element.
Methoden
ComputeRotate(Point) : double
Compute the new angle given a Point.
- newPoint
- a Point in model coordinates
Rückgabe: the new angle, in degrees
DoActivate()
Start rotation.
DoCancel()
Restore the OriginalAngle of the AdornedElement and stop this tool.
DoDeactivate()
This stops the current edit (StopTransaction).
DoMouseMove()
Call Double) with a new angle determined by the mouse point.
DoMouseUp()
Call Double) with an angle based on the most recent mouse point and raise an "object rotated" event before stopping the tool.
DoStart()
Capture the mouse when starting this tool.
DoStop()
Release the mouse capture when stopping this tool.
UpdateAdornments(Part)
Show an Adornment with a rotate handle at a point to the side of the AdornedElement, if the node is selected and visible and if CanRotate is true.
- part
Felder
SnapAngleEpsilonProperty : DependencyProperty
Identifies the SnapAngleEpsilon dependency property.
SnapAngleMultipleProperty : DependencyProperty
Identifies the SnapAngleMultiple dependency property.