Get position of center point of a pathItem, group and so on
Unfortunately there is no command in Javascript for Illustrator that allows you to read the position (x,y) of the centre of an object. This would be very helpful for many operations such as rotation and movement via Javascript.
For polygons that have their own centre point, like the triangle (3 sided polygon) this would have to be considered.
Suggestion:
var vCenterpoint = getCenterpoint(vPathItem); // x,y values
2
votes
Jens Ulrich Kriebeler
shared this idea