简体   繁体   English

iOS App-LaunchScreen.storyboard 在 ios 14.2 上显示白色

[英]iOS App- LaunchScreen.storyboard displays white on ios 14.2

I have Xcode version 12.0.1.我有 Xcode 版本 12.0.1。 I have run the app on simulator with ios 14, the launch screen working fine it shows the image I want to show(splash Screen), but when I run the app on real device which has ios 14.2 the launch screen just appeared to be white.我已经使用 ios 14 在模拟器上运行了该应用程序,启动屏幕工作正常,它显示了我想要显示的图像(启动屏幕),但是当我在具有 ios 14.2 的真实设备上运行该应用程序时,启动屏幕似乎是白色的. can some one help me with this thanks in advance.有人可以帮我提前谢谢。

Faced the same problem.面临同样的问题。 The issue was the size of the image used in the launch screen storyboard.问题在于启动屏幕 storyboard 中使用的图像大小。 This lead to the whole launch screen just being black.这导致整个启动屏幕都是黑色的。

Solution 1: What fixed it in our case was:解决方案 1:在我们的案例中解决的问题是:

  1. Choose a smaller size image选择较小尺寸的图像
  2. Delete App from device/simulator (Sometimes required)从设备/模拟器中删除应用程序(有时需要)
  3. Restart device/simulator (Sometimes required)重启设备/模拟器(有时需要)

The main reason is the larger image so just replace it with a smaller one.主要原因是图像较大,因此只需将其替换为较小的图像。

Solution 2: Place your splash screen image outside the Images.xcassets folder.解决方案 2:将初始屏幕图像放在 Images.xcassets 文件夹之外。 (But the issue with this approach is if you are supporting Dark Mode then it's not possible anymore to set a different image for dark and light mode.) (但这种方法的问题是,如果您支持暗模式,则无法再为暗模式和亮模式设置不同的图像。)

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

相关问题 如何为Flutter应用程序创建iOS LaunchScreen.storyboard? - How to create an iOS LaunchScreen.storyboard for a flutter app? iOS:LaunchScreen.storyboard上的新图像未显示更新应用 - iOS: new image on LaunchScreen.storyboard not showing updating app ios 应用程序在 ipad 上运行,launchscreen.storyboard 旋转屏幕问题 - ios app run on ipad, launchscreen.storyboard Rotate screen issue iOS App-适用于wCompact hRegular的LaunchScreen.storyboard - iOS App - LaunchScreen.storyboard for wCompact hRegular double the size of everything iOS Launchscreen.storyboard图像未显示 - iOS Launchscreen.storyboard Image not showing iOS禁用Landscape LaunchScreen.storyboard - iOS Disabling Landscape LaunchScreen.storyboard iOS中的LaunchScreen.storyboard和Main.storyboard有什么不同? - what's different LaunchScreen.storyboard and Main.storyboard in iOS? Xamarin IOS LaunchScreen.Storyboard无法为“图像”视图选择图像 - Xamarin IOS LaunchScreen.Storyboard cant select image for Image view 在 iOS LaunchScreen.storyboard 中放置图像会完全禁用启动屏幕 - Placing Image in iOS LaunchScreen.storyboard disables launch screen completely LaunchScreen.storyboard中的SuperScript(适用于iOS的Xamarin.Forms中的AttributedString) - SuperScript in LaunchScreen.storyboard (AttributedString in Xamarin.Forms for iOS)
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM