Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

iOS Simulator/Interface Builder off-center

In interface builder I placed a button here:

However when I run the iOS Simulator (device: iPhone 5s) it appears here:

I am using Xcode 6 Beta 4

like image 467
josmek Avatar asked Jul 25 '14 00:07

josmek


People also ask

How do I change orientation in iOS simulator?

iOS Simulator - You can rotate the simulator under the Hardware menu with the Rotate Left or Rotate Right option.


1 Answers

I would recommend you to use size classes due to new iOS screen sizes, but you still can disable size classes on the interface builder in the file inspector as you can see on the image:

If you would like to use Autolayout you can do it adding the next constraints (see the first image) in the corresponding View. In the second step you should use the width and height corresponding to your View. In the second image you can see a recapitulation of all the constraints and a simulator screenshot. Images:

like image 174
CarlosGz Avatar answered Oct 14 '22 22:10

CarlosGz