| Article | 60002048 |
| Type | Wish |
| Product | Engine |
| Date Added | 10/1/2013 12:00:00 AM |
| Fixed | (10/2/2013 12:00:00 AM) |
| Submitted by | Wayne Romer |
Summary
Is it possible to have cmdRotate command to accept reference angle ?
Solution
Added in 6026 version.
Syntax: CmdRotate(SelSet as object, BasePoint as object, RefAngle as object, Rotation as object)
SelSet: A selection of vdFigures vdSelection or "USER"/null so the user can select the entities.
BasePoint: A base point gPoint object in User Coordinate system (UCS) or "USER"/null so the user picks the point.
RefAngle: The reference angle in radians as double or "USER"/null so the user choose the reference angle on screen.
Rotation: The rotation in radians as double or "USER"/null so the user rotates the objects to the screen.
Can be used like:
CmdRotate(mySel, new gPoint(2,3), null, null);
CmdRotate(null, null, null, null);
// when Rotation or RefAngle is passed with code then the double value must be in radians like:
CmdRotate(mySel, new gPoint(2,3), VectorDraw.Geometry.Globals.PI/6.0d, null);
CmdRotate(mySel, new gPoint(2,3), VectorDraw.Geometry.Globals.PI/6.0d, VectorDraw.Geometry.Globals.PI); // this will rotate the objects for PI-(PI/6) = 150 degrees
NOTE:
RotateEx method now calls CmdRotate(null, null, null, null);
The previous CmdRotate(SelSet as object, BasePoint as object, Rotation as object) is still available and working as before. This method is calling CmdRotate(null, null, 0.0d, null);
