Re: InDesign CS2 Find Scale of Images
Re: InDesign CS2 Find Scale of Images
- Subject: Re: InDesign CS2 Find Scale of Images
- From: Stan Cleveland <email@hidden>
- Date: Thu, 29 Nov 2007 18:03:59 -0800
- Thread-topic: InDesign CS2 Find Scale of Images
On 11/29/07 4:19 PM, Mark Esser wrote:
> Curious if anyone knows of a way to find the scale of all images placed in an
> InDesign layout, through AppleScript -- for example; CoverImage.tiff is scaled
> at 120%, etc.
>
> Knew how to do this in QuarkXpress, but InDesign is unfamiliar territory.
This should get you going in the right direction:
tell application "Adobe InDesign CS3"
tell document 1
set allRects to rectangles
repeat with thisRect in allRects
set foundImage to all graphics of thisRect
if foundImage is {} then
-- there's no image
else
-- get image name and scaling
set foundImage to contents of item 1 of foundImage
set imageName to name of item link of foundImage
set hScale to horizontal scale of foundImage
set vScale to vertical scale of foundImage
-- now do something with the data
return {imageName, hScale, vScale}
--> {"CoverImage.tiff", 120.0, 120.0}
end if
end repeat
end tell
end tell
Stan C.
_______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users
This email sent to email@hidden