Copy link to clipboard
Copied
Hi there,
how to write script to below three steps for pathitem , thanks
pathitem .CONVERT_TO_RECTANGLE;
script to step2 and step3
artb.add(pathitem.geometricBounds);
step1,
step2
step3
Please try it with a newer version (open document and one pathItem required)
var aDoc = app.activeDocument;
var pItBds = aDoc.pathItems[0].geometricBounds;
aDoc.artboards.add ([ pItBds[0], pItBds[1], pItBds[0]+(pItBds[2]-pItBds[0]), pItBds[1]+(pItBds[3]-pItBds[1]) ])
Does that makes sense for you?
Copy link to clipboard
Copied
Please try it with a newer version (open document and one pathItem required)
var aDoc = app.activeDocument;
var pItBds = aDoc.pathItems[0].geometricBounds;
aDoc.artboards.add ([ pItBds[0], pItBds[1], pItBds[0]+(pItBds[2]-pItBds[0]), pItBds[1]+(pItBds[3]-pItBds[1]) ])
Does that makes sense for you?
Copy link to clipboard
Copied
You've been a great help. Thank you for sharing your knowledge and solving my problem.
Copy link to clipboard
Copied
You're welcome.