简体   繁体   English

旧iPhone的ui设计可以在iphone4上使用吗?

[英]can the ui design for old iphone be used on iphone4?

我正在开发软件,所有ui都是基于480x320尺寸的屏幕绘制的,我的软件可以在iphone4上运行而无需进行任何修改吗?

Yes it can run with no modification. 是的,它无需修改即可运行。

If you'd like to create "retina" assets you can create all of your images at the double resolution and include copies with '@2x' appended to the filename in your Application bundle. 如果您想创建“视网膜”资产,则可以以双分辨率创建所有图像,并在应用程序捆绑包中添加在文件名后附加“ @ 2x”的副本。 The iPhone will automatically load the correct images. iPhone将自动加载正确的图像。

Example: existing image - myImage.png new up-sampled image - myImage@2x.png 示例:现有图像-myImage.png新的上采样图像-myImage@2x.png

是的,但是与自定义设计的iPhone 4图像相比,适用于早期iPhone型号的任何尺寸的图像看起来都显得矮胖。

Both the iPhone 4 and older devices are 320x480 points in size, which is the coordinate system that Core Graphics and UIKit uses. iPhone 4和旧版设备的尺寸均为320x480点,这是Core Graphics和UIKit使用的坐标系。 So your software will run the same. 因此,您的软件将以相同的方式运行。

Only the automatic scaling between your bitmaps and the display will be different. 只有位图和显示之间的自动缩放会有所不同。 If you have bitmapped content or images, you can optionally provide @2x sized versions that will look somewhat smoother without the 2X scaling on iPhone 4 devices. 如果您具有位图内容或图像,则可以选择提供@ 2x大小的版本,在没有iPhone 4设备上2倍缩放的情况下,看起来会更加平滑。 This is nice, but optional. 这很好,但是是可选的。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

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