Skip to main content
Sulaco
Inspiring
Feb 20, 2026 2:50 PM UTC
Answered

Reset Scale transformations on multiple objects (Script)

I want to be able to reset scaling values on objects in InDesign, without changing their size. I found the following script snippet online, that does the job:

app.selection[0].redefineScaling();

But it only works on one object at the the time, even if I select multiple ones. Is there a way to make it work on multiple objects? Keep in mind that I know next to nothing about scripting 😅

    rob day
    rob dayCorrect answer
    Community Expert
    Feb 20, 2026 4:40 PM UTC

    Hi ​@Sulaco , This would redefine the scaling of all the document’s graphics’ container frames:

     


    //an array of all the document’s graphics
    var api = app.activeDocument.allGraphics

    for (var i = 0; i < api.length; i++){
    //api[i].parent is the graphic’s container frame
    //reset the width and height to 100%
    api[i].parent.redefineScaling([1.0, 1.0])
    };

     

    5 replies

    rob day
    Community Expert
    rob dayCommunity ExpertCorrect answer
    Community Expert
    Feb 20, 2026 4:40 PM UTC

    Hi ​@Sulaco , This would redefine the scaling of all the document’s graphics’ container frames:

     


    //an array of all the document’s graphics
    var api = app.activeDocument.allGraphics

    for (var i = 0; i < api.length; i++){
    //api[i].parent is the graphic’s container frame
    //reset the width and height to 100%
    api[i].parent.redefineScaling([1.0, 1.0])
    };

     

    Translate
    Sulaco
    SulacoAuthor
    Inspiring
    Feb 20, 2026 4:57 PM UTC

    Awesome, thank you! Is there a way to have this redefine only selected objects?

    Translate