简体   繁体   中英

iOS 7 simulator vs device vs Storyboard UI differences

Upgrading my app for iOS 7 is a challenge. The UI is built from IB but does not use auto layout.

On IB I unchecked the Extend Edges boxes for my view controllers. Now in IB it all looks correct for iOS 7 and iOS 6.

Extend Edges unchecked:

IB扩展边缘

Storyboard appearance:

IB按钮在此输入图像描述

Segmented Control tint:

在此输入图像描述

On Simulator the content still extends behind the navbar unless I make the navbar opaque. It seems to just ignore the fact the Extend Edges where unchecked.

Simulator Appearance:

在此输入图像描述在此输入图像描述

On an iPhone 5 running iOS 7 the content also extends under the navbar. In addition, all the navbar buttons have iOS 6 look. The segmented control also seems to be ignoring the tint and displaying black on black.

iPhone 5 running iOS 7 Appearance:

在此输入图像描述在此输入图像描述

Can someone explain what's happening here and how I can get the iOS 7 appearance on IB, Simulator, and device to match?

I spent days on this and was astounded by the variety of displays I saw. Not only were the buttons not displaying correctly but I also was getting different UIView frame dimensions on the simulator between iOS 6 & 7. I also saw differences in the frame between the simulator and iOS 7 device.

I was tracking down a different problem and realized my iOS device showed up twice on Xcode 5's destination menu. I found out that occurs when you have more than one iOS SDK installed in Xcode. I removed the iOS 6.1 SDK from the Xcode 5 application and all my issues went away.

I can't be sure it wasn't related to me picking a different device from the menu each time. I understand one shows up for each SDK installed. They were named the same so I never knew which one to choose.

Again, not sure this caused all my problems but I don't have them now. Hopefully this will save someone a ton of time tracking down UI anomalies.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM