1

This problem occurs when I perform transformations on my images. I can reposition a UIImageView by resetting its center using CGPointMake, but when I go to rotate it with a line like,

image1.transform = CGAffineTransformRotate([image1 transform],angle);

the UIImage moves back to its original position (the place where I put it in my StoryBoard editor).

This person has my exact problem in his post: Rotating uiimageview moves image back to original storyboard position

rmaddy
  • 314,917
  • 42
  • 532
  • 579
Nerdatope
  • 127
  • 4
  • Probably because auto layout is fighting you. See my "essay" here: http://stackoverflow.com/questions/12943107/how-do-i-adjust-the-anchor-point-of-a-calayer-when-auto-layout-is-being-used/14105757#14105757 – matt May 30 '14 at 01:17
  • Thanks for that info, now I understand what the matter is. – Nerdatope May 30 '14 at 18:29

1 Answers1

0

Going to the File inspector in interface builder, and unticking "Use Auto Layout" seems to solve the problem, however constraints are turned off when one does this. It is a good temporary solution, however. The first comment under my question also has some great info on the matter.

Nerdatope
  • 127
  • 4