Share

AcDbMText::setRotation

C++

Acad::ErrorStatus setRotation(
    double
);

Description

Sets the direction value for the MText object. To obtain the new direction vector from angle, ObjectARX first obtains the normal vector of the current User Coordinate System (UCS) in the AutoCAD editor. Next, it calculates the Entity Coordinate System (OCS) for the normal vector just obtained. Finally, it rotates the X axis vector of this OCS around the normal vector by angle. Positive angles are counterclockwise when looking down the UCS normal towards the UCS origin (right-hand rule).

Note

The normal vector of the MText object is not used at all by this function.

setDirection() is a much more direct method to set the MText direction.

Returns Acad::eOk if successful or Acad::eInvalidInput if the data passed in is not acceptable.

Parameters

Parameters Description
unnamed Input rotation angle in radians

Links

AcDbMText Class

Was this information helpful?