启动屏幕故事板不显示图像 [英] Launch Screen storyboard not displaying image

查看:110
本文介绍了启动屏幕故事板不显示图像的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试从Launch Screen.storyboard文件中将图像显示为启动屏幕,但图像永远不会显示。我的标签显示正常,但图像没有出现。

I'm trying to get an image to display as the launch screen from my Launch Screen.storyboard file, however the image never displays. I have labels that show up fine, but the image doesn't appear.

这是启动屏幕在Launch Screen.storyboard文件中的外观:

This is how the launch screen looks in the Launch Screen.storyboard file:

然而,当我在模拟器(以及物理设备)上运行应用程序时,这就是显示的内容:

However when I run the app on the simulator (as well as on the physical device) this is what shows up:

如您所见,标签测试显示正常,但图像不显示。我真的不确定为什么会这样,我尝试的任何东西似乎都没有用。如果有人对如何解决这个问题有任何想法,将不胜感激。

As you can see, the label "Test" shows up fine, however the image does not display. I'm really not sure why this is happening and nothing I try seems to work. If anyone has any ideas of how to fix this it would be greatly appreciated.

推荐答案

重新启动Xcode后,清除构建以及有关此问题的其他一些建议。实际上为我修复的是设备的硬重启。 (我在这上面浪费了一个多小时)

After restarting Xcode, cleaning the build and a number of the other suggestions on SO about this problem. What actually fixed it for me was a hard reboot of the device. (I wasted over an hour on this)

我想这只是为了证明那句老话让你把它关掉再打开仍然适用于最新的小工具!

I suppose it just goes to show that the old saying have you turned it off and on again is still true for the latest gadgets!

这篇关于启动屏幕故事板不显示图像的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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