Copy link to clipboard
Copied
How to scale multiple objects programatically using javascript in InDesign (grouping and ungrouping).
For example, Rectangle, TextFrame, Oval and ellipse tools selection.
Thanks,
Nehru
Copy link to clipboard
Copied
Moving to InDesign Scripting forum
Copy link to clipboard
Copied
Hi,
Try this..
var myDoc = app.activeDocument;
var objects = myDoc.selection;
var xScale = 80 / 100;
var yScale = 80 / 100;
for (t=0; t<objects.length; t++) {
objects
.horizontalScale = objects .horizontalScale * xScale; objects
.verticalScale = objects .verticalScale * yScale; }
Thanks,
prabu G
Copy link to clipboard
Copied
Try my scripts to resize based on factors.
You can set a factor to multiply the current sizes.
The code will resize all selected objects based on the center anchor point.
http://lf.corullon.com.br/scripts_id_lfc/index_enus.html
Em 15 de jul de 2017 3:21 AM, "Ananth@desgin" <forums_noreply@adobe.com>
escreveu:
Adobe Community <https://forums.adobe.com/?et=watches.email.thread>
Scaling multiple objects using javascript in InDesign
resposta de Ananth@desgin
<https://forums.adobe.com/people/Ananth%40desgin?et=watches.email.thread>
em InDesign Scripting - Visualize a discussão completa
<https://forums.adobe.com/message/9704042?et=watches.email.thread#9704042>
Copy link to clipboard
Copied
If we select multiple objects and scale continuously then at one point, I am getting the following message. "This value would cause one or more objects to leave the pasterboard". How to calculate the size of absoluteHorizontalScale that cause this message programmatically using JavaScript.
Thanks,
Nehru