I'd like to apply rotation to a few PageItem instances, but would like to reset the rotation first so it doesn't accumulate when I run the same script multiple times. I'm having a hard time trying to figure out how to restet the transformation matrix.
I've spotted
which is close to what I need but it's a bit old now.It looks like there isn't a matrix property anymore.
This:
alert(app.activeDocument.selection[0].matrix);
ouputs undefined
I've tried
app.activeDocument.selection[0].transform(app.getIdentityMatrix());
but it seems transformations are accumulated, multiplied, not reset.
If I want to reset the rotation of a PageItem, how would I go about doing that ?
Thanks,
George