启动iPhoneX的图像名称?

lau*_*573 23 iphone xcode ios11 xcode9 iphone-x

关于iPhoneX的问题.我想把iPhoneX的启动图像(1125px×2436px)放在普通文件夹中.不在LaunchImage源中.什么是iPhoneX的Launch Image名称?就像'Default-iOS8-736h @ 3x'一样,我在https://developer.apple.com/ios/human-interface-guidelines/icons-and-images/launch-screen/中找不到该名称 .

小智 22

您可以为iPhone X添加静态启动图像,只需添加:Default-375w-812h@3x.png


Val*_*gin 14

按照惯例,它应该命名为Default-812h@3x.png(和Default-Landscape-812h@3x.png)(812是点的实际高度).而且看起来目前没有办法使用故事板驱动的启动画面,并且iPhone X和旧版加尺寸型号都具有像素完美图像.


Dzu*_*gPV 8

您可以使用简单的步骤为旧项目添加iPhone X的静态启动映像:

1, Select Assets.xcassets select launch image folder.
2, Check "iOS 8.0 and later" in the right Attribute inspector panel.
3, An iPhone X place holder will appear, drag an image 375w812h @ 3x to it and you are done.
Run Code Online (Sandbox Code Playgroud)


iam*_*ite 6

如果launchImage源名称为“ LaunchImage”。 常规标签中的设置

名字应该是 [UIImage imageNamed:@"LaunchImage-1100-2436h@3x.png"]

PS:如何找到它?

  1. 步骤1.打开bundle目录,如 /Users/hite/Library/Developer/CoreSimulator/Devices/5CFE3CFA-94F8-45EC-BAC5-xxx2/
  2. 找到您的应用程序文件,例如myFit.appShow Package Contents
  3. 搜索3x.png以获取图像名称。

  • 按照这种方法,iPhone X面向纵向的启动图像为“ LaunchImage-1100-Portrait-2436h@3x.png”。 (2认同)