Skip to main content
dublove
Legend
August 1, 2025
Answered

How to use a script to redefine the image scaling ratio to 100%?

  • August 1, 2025
  • 1 reply
  • 157 views

I searched for some information. Is this it?
WhenScalingOptions.ADJUST_SCALING_PERCENTAG
For example, if I select an object like this, how should I write it?
var sel = app.documents[0].selection;

 

After moving and zooming the image multiple times, the frame becomes misaligned. I want to clear it.

 

Correct answer rob day

ScalingOptions.ADJUST_SCALING_PERCENTAG

 

Hi @dublove , I don’t think there is any ScalingOptions constant in the API. If you are trying to reset scaled text to 100% without changing its appearance try this:

 

var sel = app.activeDocument.selection[0];
//an array of 2 numbers where 1 equals 100%
sel.redefineScaling ([1,1])

 

 

 

 

1 reply

rob day
Community Expert
rob dayCommunity ExpertCorrect answer
Community Expert
August 1, 2025

ScalingOptions.ADJUST_SCALING_PERCENTAG

 

Hi @dublove , I don’t think there is any ScalingOptions constant in the API. If you are trying to reset scaled text to 100% without changing its appearance try this:

 

var sel = app.activeDocument.selection[0];
//an array of 2 numbers where 1 equals 100%
sel.redefineScaling ([1,1])