Rotate a Shape with Suitable Angle in PHP

Aspose.Diagram - Rotate a Shape with Suitable Angle

To Rotate a Shape with Suitable Angle using Aspose.Diagram Java for PHP, simply invoke RotateShape module. Here you can see example code.

PHP Code

 # Create instance of Diagram

$diagram=new Diagram($dataDir."Drawing.vsd");

\# Add a shape and set the angle

$diagram->getPages()->getPage(0)->getShapes()->getShape(1)->setAngle(190);

\# Save diagram

$saveFileFormat=new SaveFileFormat();

$diagram->save($dataDir."RotateShape.vdx",$saveFileFormat->VDX);

print "Rotated shape.".PHP_EOL;

Download Running Code

Download Rotate a Shape with Suitable Angle (Aspose.Diagram) from any of the below mentioned social coding sites: