我有一个 xib 文件,我正在尝试为 iPhone 5 调整大小 [英] I have a xib file that I am trying to resize for iPhone 5

查看:27
本文介绍了我有一个 xib 文件,我正在尝试为 iPhone 5 调整大小的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我尝试了很多不同的方法,如果有人能给我一个对你有用的方法,请帮助我.

I have tried many different methods, if anyone can give me a method that worked for you please help me.

推荐答案

不要为 iPhone 5 创建单独的 Xib.而是添加一个名为 Default-568h@2x.png 的启动图像.这会将您的应用标识为支持 iPhone 5 指标的应用.

Don't create a separate Xib for iPhone 5. Instead, add a splash image named Default-568h@2x.png. That will identify your app as one that supports iPhone 5 metrics.

当应用加载时 - 无论是在 iPhone 5 设备上 - 还是在配备 Retina 4 英寸显示屏的 SIM 卡上,您都会看到您的应用在全 568 像素高度模式下运行.

When the app is loaded - either on an iPhone 5 device - or on the sim with Retina 4-inch display, you will see your app running in full 568 pixel height mode.

您可能会在错误的位置看到一些空白区域或按钮等.那是因为您没有在 Interface Builder 中正确配置 autosizing 属性.一定要这样做,使用下面的控件来指定控件的粘性",以及它们应该如何扩展到额外的空间.

You may see some empty spaces, or buttons in the wrong place, and so on. That's because you have not configured the autosizing properties correctly in Interface Builder. Be sure to do that, using the controls below to specify the "sticky-ness" of the the controls, and how they should expand into the additional space.

这篇关于我有一个 xib 文件,我正在尝试为 iPhone 5 调整大小的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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