rotate graphics in InDesign CS 3

Hi all,

i am trying to rotate an image in InDesign CS 3 - but whatever I try, it always affects also the shear angle.
I tried setting the property (rotation angle or absolute rotation angle) directly and i also tried using a transformation matrix - it had the same effect:
when rotating by an angle of -0.8° the result was a rotation of -0.698° ans a shear angle of 0.219°, even when I set the shear angle to zero in my transformation:

set thematrix to make transformation matrix with properties {counterclockwise rotation angle:-0.8, clockwise shear angle:0.0}

What am I doing wrong? Many thanks for your help in advance.

D.

Maybe answering my own question … might it be the reason that the image is scaled unproportionally? Probably … but then i have an other question - how can I calculate the correct shear and rotate value for the given angle an the horizontal and vertial scale factors of the image?

Hi Dominik

this is working for me without affecting other parameters. (that i can tell)

tell application "Adobe InDesign CS3"
	tell document 1
		tell rectangle 1 -- one placed image in doc
			set rotation angle to -0.8
		end tell
	end tell
end tell

Many thanks, pidge1 - unfortunately this has not the same effect. I wanted to rotate only the graphic inside it’s enclosing rectangle. Your script rotates the whole rectangle.

Hi Dominik

Oops! :confused: Maybe should have read a little bit better Sorry.
Your right this is a little tricky the closest i’ve been able to get is this.

tell application "Adobe InDesign CS3"
	tell document 1
		tell every EPS of rectangle 1
			set rotation angle to -90
		end tell
	end tell
end tell

Couldn’t get it to work with image but if your image is a Photoshop eps for example this should work without affecting the outer rectangle.

This works for me.

tell application "Adobe InDesign CS3"
	tell document 1
		set rotation angle of image 1 of rectangle 1 of page 1 to 30
	end tell
end tell

Many thanks for your answers!

I found the solution meanwhile - I made the mistake that I altered the bounds of the image after rotating it. The image was scaled by different horizontal and vertical factors. That’s why it was sheared in the result. (The same effect can be reproduced in ‘real life’ when you drag-resize a rotated image’s rectangle.)

So … sorry for the noise …