• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

Proportionally resize frames based on image

New Here ,
Oct 19, 2018 Oct 19, 2018

Copy link to clipboard

Copied

Hello, in my document I have one circular frame on each page. I am loading one eps file into each of the circular frames via a merge - there are a few thousand images.  When an image is loaded into the frame, if the image is a square or it shows up fine, but if the image is tall or wide, then it doesn't effectively fill up the space in the circle frame. I'm looking for a script or suggestions on where to start that essentially something that does the following for each of the frame in the document. I'm pretty new to the scripting.

if image.width > image.height then

     frame.width = x

     frame.width = y

endif

if image.height > image.width then

     frame.width = a

     frame.width = b

endif

fit image proportionally in frame

TOPICS
Scripting

Views

171

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
no replies

Have something to add?

Join the conversation