首页/ 接口索引/ Shape 几何与变换

shape.Rotate(angle)

相对旋转指定角度。

签名

shape.Rotate(angle)

说明

相对旋转指定角度。

Python 示例(可直接运行)

依赖 pywin32。示例假定 app / doc / page / layer 已就绪。 见「连接与初始化」
Python
shape = app.ActiveSelectionRange(1)

shape.Rotate(30)                           # 相对旋转 30 度(在现有角度上累加)
print("当前角度:", shape.RotationAngle)

shape.Rotate(-30)                          # 转回去
print("还原后:", shape.RotationAngle)

关于本类:Shape 几何与变换

位置、尺寸、旋转、包围盒。全部跟随 doc.Unit(你的环境是英寸),字号例外。

同类其他接口