如何使用Xcode 4.5为iPhone 4和iPhone 5创建Xib [英] How can I create xibs for both iPhone 4 and iPhone 5 using Xcode 4.5

查看:79
本文介绍了如何使用Xcode 4.5为iPhone 4和iPhone 5创建Xib的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已将部署目标设置为iOS 4.3,并使用xib创建了viewcontroller.但是XCode 4.5仅为iPhone 5(4英寸)创建了xib.如何为iPhone 4创建单独的xib?

I have set deployment target as iOS 4.3 and creating viewcontroller with xib. But XCode 4.5 is creating xib for iPhone 5 (4 inch) only. How can I create a seperate xib for iPhone 4?

推荐答案

在视图的属性检查器的模拟度量"部分中,可以选择3,5或4"大小.选择3,5,并调整视图和子视图的大小,iOS将自动缩放视图以适合iPhone 5的屏幕.

In 'Simulated Metrics' section of view's attributes inspector, you can choose between 3,5" or 4" sizes. Choose 3,5", and make your views and subviews resizable, iOS will automatically scale your view to fit iPhone 5's screen.

这篇关于如何使用Xcode 4.5为iPhone 4和iPhone 5创建Xib的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆