Monthly Archives: May 2013

Rotational transform and edge constraint

When I was working on bible app, auto layout was working fine in portrait mode. However, there was an exception when I switched to landscape mode.

“Autolayout doesn’t support crossing rotational bounds transforms with edge layout constraints, such as right, left, top, bottom”

I had no idea what did it mean. When I dumped the view hiehrary I found that there was a view called “UILayoutContainerView” which was applied a transformation.

The problem was that I tried to add view with edge constraints to self.view’s parent view, which is “UILayoutContainerView”.

In conclusion, we should only put everything on self.view when using autolayout.

Tagged ,