xcode 资产目录编译器警告:针对 IOS 7.0 及更高版本的 iPad 应用程序需要 76x76@2x 应用程序图标
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/19891448/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
Asset Catalogue compiler warning: a 76x76@2x app icon is required for iPad apps targeting IOS 7.0 and later
提问by Bernie
I've been having this warning for ages, and I just can't seem to get rid of it.
我已经收到这个警告多年了,我似乎无法摆脱它。
The warning is:
警告是:
/Images.xcassets: A 76x76@2x app icon is required for iPad apps targeting iOS 7.0 and later
I've tried completely replacing the asset catalogue with a brand new one, and copying in ones which work on other projects. I've even tried simply not using asset catalogues, but I can't seem to shake this warning.
我尝试用全新的资产目录完全替换资产目录,并复制适用于其他项目的资产目录。我什至尝试过不使用资产目录,但我似乎无法摆脱这个警告。
I can't see any reason as to why it's appearing, especially when I do have a 152x152 app icon in there.
我看不出它出现的任何原因,尤其是当我有一个 152x152 的应用程序图标时。
Note, I'm trying to do an icon for iPad IOS 7.
请注意,我正在尝试为 iPad IOS 7 制作一个图标。
Is there something I'm missing?
有什么我想念的吗?
回答by Jalakoo
Alex's answer didn't work for me when targeting environments below 7.0, but did prompt me to look at the utilities panel, if you open it you'll see checkbox options for "iOS 6.1 and prior sizes". Check this on to reveal the missing icon assets.
当以低于 7.0 的环境为目标时,Alex 的回答对我不起作用,但确实提示我查看实用程序面板,如果打开它,您将看到“iOS 6.1 和先前尺寸”的复选框选项。选中此项以显示丢失的图标资产。
回答by Alex Nevsky
Oh... It's a pain.
啊……好痛。
You have to set enough width for Xcode and you will see all images assets.
您必须为 Xcode 设置足够的宽度,您将看到所有图像资产。
回答by Alex Nevsky
I was having this same problem. Made sure that the Attributes Inspector for AppIcon had iPad unchecked, and made sure that Deployment Info -> Devices was set for iPhone, then hit Shift-Cmd-K to clean. Went right away, then I was able to add them and the deployment setting again like normal. Worked great.
我遇到了同样的问题。确保 AppIcon 的属性检查器没有选中 iPad,并确保为 iPhone 设置了部署信息 -> 设备,然后按 Shift-Cmd-K 进行清理。马上就去,然后我就可以像往常一样再次添加它们和部署设置。工作得很好。
回答by Akshay Sunderwani
I was having the same problem, i was missing icon for iOS 6.1 and earlier. So i found a important guide on app icon by apple you can found it here.
我遇到了同样的问题,我缺少 iOS 6.1 及更早版本的图标。所以我找到了一份关于苹果应用程序图标的重要指南,你可以在这里找到它。
Hope this will help you.
希望这会帮助你。
Edit: Your name of icon must be same os of apple icon naming mentioned on the link.
编辑:您的图标名称必须与链接上提到的苹果图标命名相同。
回答by PJ_Finnegan
Xcode 9/Swift 4
Xcode 9/斯威夫特 4
Same issue here. I only had a 152x152 icon in the "iPad App iOS 7-11 76 pt @2x" slot and I solved by adding a 76x76 icon in the @1x slot.
同样的问题在这里。我在“iPad App iOS 7-11 76 pt @2x”插槽中只有一个 152x152 图标,我通过在 @1x 插槽中添加一个 76x76 图标来解决。