Reputation: 2822
I have a basic question regarding springs/struts (I'm working on a legacy codebase that prefers it over auto layout), and since I started iOS using auto layout I am trying to understand why this doesnt work. I am wanting to simply center this UIView in superview.
What I have (notice my springs/struts settings):
So with that, it views just fine on an iPhone 5 screen.
Here is what iPhone 4 screen displays though:
As you can see, it is much lower than what it should be. How can I achieve this?
Thanks.
Upvotes: 0
Views: 128
Reputation: 9944
That's because you set the top and bottom margin to be fixed. Try removing them from the storyboard, and you'll see that your view will be centered vertically.
Upvotes: 1