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

查看:108
本文介绍了如何使用Xocde 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.

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

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