LocalPinPositionCoeff: IGxPointF;
The LocalPinPositionCoeff property determines rotation point offset relative to the shape size. By default, the rotation point is in the center of a shape. To place a pivot in the upper left corner of a shape, set coordinates (0,0), in the lower left corner of a shape - (1,1), in the center - (0.5,0.5).
Executing the example requires that repository contains a workspace with the WSP identifier containing shape.
Add links to the Andy, Drawing, Metabase system assemblies.
Sub UserProc;
Var
MB: IMetabase;
ws: IWxWorkspace;
Shape: IWxShape;
Begin
MB := MetabaseClass.Active;
// Get workspace
ws := MB.ItemById("WSP").Edit As IWxWorkspace;
Shape := ws.Shapes.Item(0);
Shape.LocalPinPositionCoeff := New GxPointF.Create(0, 1);
// Save changes
(ws As IMetabaseObject).Save;
End Sub UserProc;
After executing the example the point of rotation is located in the upper left corner.
See also: