当我验证我的应用程序时,我收到此错误:
应用程序包不包含ICNS格式的图标,包含a
512x512
和512x512@2x
图像.
我用Img2icns应用程序制作icns图标,直到今天它始终正常工作.但现在我收到了这个错误,没有办法让它发挥作用.我试图将两个PNG文件放在一起(512x512
和1024x1024
)在Img2icns中,但我总是得到那个错误.我也尝试按照Apple的OS X人机界面指南中的说明进行操作,但是当我尝试制作图标集时,我收到此终端错误:
-bash:意外标记'newline'附近的语法错误
我对终端命令不是很好,所以也许我做错了.我写:
iconutil -c icns </Users/myname/SDK Mac Apps/MyApp/grafica/icon.iconset>
Run Code Online (Sandbox Code Playgroud)
如果有人能提供帮助,我将非常感激.谢谢,马西.
我正在尝试为应用程序创建一个iconset,但是当我创建它时继续出错: Hexchat.iconset:error: Failed to generate ICNS.
我尝试从Illustrator单独导出.png文件,以及使用脚本.使用1024x1024 png文件的当前脚本Hexchat_8.png
:
mkdir Hexchat.iconset
sips -z 16 16 Hexchat_8.png --out Hexchat.iconset/hexchat_16x16.png
sips -z 32 32 Hexchat_8.png --out Hexchat.iconset/hexchat_16x16@2x.png
sips -z 32 32 Hexchat_8.png --out Hexchat.iconset/hexchat_32x32.png
sips -z 64 64 Hexchat_8.png --out Hexchat.iconset/hexchat_32x32@2x.png
sips -z 128 128 Hexchat_8.png --out Hexchat.iconset/hexchat_128x128.png
sips -z 256 256 Hexchat_8.png --out Hexchat.iconset/hexchat_128x128@2x.png
sips -z 256 256 Hexchat_8.png --out Hexchat.iconset/hexchat_256x256.png
sips -z 512 512 Hexchat_8.png --out Hexchat.iconset/hexchat_256x256@2x.png
sips -z 512 512 Hexchat_8.png --out Hexchat.iconset/hexchat_512x512.png
cp Hexchat_8.png Hexchat.iconset/hexchat_512x512@2x.png
iconutil -c …
Run Code Online (Sandbox Code Playgroud) 我使用iconutil
命令行工具将 iconset 文件夹转换为icns
文件:
iconutil -c icns /path/to/my.iconset
Run Code Online (Sandbox Code Playgroud)
我在 Xcode 中运行它作为构建阶段。
我得到了 my.icns 文件,但是当我尝试打开它时,我从预览应用程序收到一条错误消息:
无法打开文件“my.icns”。
它可能已损坏或使用了 Preview 无法识别的文件格式。
我有最新的 macOS High Sierra 版本 10.13,内部版本 17A365。
有没有人遇到过这个问题?关于如何解决这个问题的任何想法?
我一直在尝试使用iconutil从文件夹"folderthumb.iconset"中的.png图像生成.icns图标,使用以下命令:
iconutil -c icns folderthumb.iconset
Run Code Online (Sandbox Code Playgroud)
当源png具有alpha透明度时,一切顺利.但是,当PNG不透明时(来自sips,hasAlpha = no),iconutil会返回错误:
不受欢迎的图像格式
我的libpng是v1.6,安装有brew
.
有没有人提出如何解决这个问题的提示?
我有XCode 4.2,需要向App Store提交Mac应用程序.我已经尝试了各种建议的方法来获取多分辨率图标,所以你不需要通知我.
剩下的方法是使用iconutil
.我在Spotlight中搜索过,在Finder中搜索了我的Mac硬盘.dmg
,sudo find
在终端中搜索了两个后来的XCode 图像,并在网上寻找路径.Xcode的4.4.1 .dmg
有Iconutil.strings
和Iconutil.xcspecs
,但是这是据我已经来了.
有没有我可以下载的软件包来获取这个命令或工具,所以我可以转换.iconset
?如果有设置我可以在XCode中更改以允许旧.icns
文件(之前1024x1024
和之前512x512@2x
),这将是我可以暂时接受的解决方案.我有OS 10.6.8.
编辑
我会接受一个答案,确认命令是否存在于10.6.8中以及它在哪里.我会接受一个链接到有效.icns
文件的答案,该文件最近已被App Store验证批准,512x512
并且512x512@2x
(最好是未压缩的.png
内部).