看起来 Apple 尚未针对新的发布图像尺寸更新文档,但您可以从 Xcode 中找到它们。如果按照 Maddy 的说明添加新的启动图像,则可以在检查器面板中查看新尺寸。 iOS 8 包含三个新图像,如果状态栏在启动时被隐藏,则不需要不同的图像。尺寸是:
iOS 8 iPhone Portrait
Retina HD 5.5 1242x2208
Retina HD 4.7 750x1334
iOS 8 Landscape
Retina HD 5.5 2208x1242
您可以在 Xcode 中添加它们或编辑 .xcassets 文件中的 json 文件并将图像放入包中。如果您选择编辑包,请将这些行添加到文件顶部:
{
"extent" : "full-screen",
"idiom" : "iphone",
"subtype" : "736h",
"filename" : "Default-736h@3x.png",
"minimum-system-version" : "8.0",
"orientation" : "portrait",
"scale" : "3x"
},
{
"extent" : "full-screen",
"idiom" : "iphone",
"subtype" : "736h",
"filename" : "Default-Landscape@3x.png",
"minimum-system-version" : "8.0",
"orientation" : "landscape",
"scale" : "3x"
},
{
"extent" : "full-screen",
"idiom" : "iphone",
"subtype" : "667h",
"filename" : "Default-667h@2x.png",
"minimum-system-version" : "8.0",
"orientation" : "portrait",
"scale" : "2x"
}
我保留了他们之前对肖像文件使用的命名约定。以前手机上从来没有横向选项,所以我保留了 iPad 的命名约定。当然,您可以随意命名它们。
编辑:请注意,唯一将以横向模式启动的手机是 iPhone 6 Plus。其余手机将仅以纵向模式启动。