No icns for compiled app

Mac OSX specific forum
User avatar
thinkitsimple
User
User
Posts: 89
Joined: Mon Aug 13, 2012 6:12 pm
Location: Berlin, Germany
Contact:

No icns for compiled app

Post by thinkitsimple »

Hi,

I tried to set the app icon in the info.plist like this:

Code: Select all

<key>CFBundleIconFile</key>
<string>dungeon.icns</string>
but the icon is not shown after starting the app. Where do i have to place the icon in the app-package? PureBasic placed the icns-file in the Contents/Resources Folder. The Icon works inside the IDE.

How to i get my icon work with my compile mac-app?
Michael

PureBasic 5.51, macOS 10.12.2 Sierra
User avatar
deeproot
Enthusiast
Enthusiast
Posts: 290
Joined: Thu Dec 17, 2009 12:00 pm
Location: Llangadog, Wales, UK
Contact:

Re: No icns for compiled app

Post by deeproot »

Hi Michael,

The experts here might be able to explain this better? However, as a 'Mac newbie' my app icon worked with no trouble. I do not think you need to edit the info.list!

As far as I remember, I simply used Icon Composer to create my icns file (256, 128, 32 and 16 pixel variations) and saved it in a sub-folder of my source-files project folder. Then just set the icon file name in the PB IDE Compiler Options. As you correctly say, the icns file is copied into the Resources folder of the app when it is compiled. It shows up fine when the app is run or installed to another location.
( PB 5.22 LTS, OSX 10.6.8 )
User avatar
thinkitsimple
User
User
Posts: 89
Joined: Mon Aug 13, 2012 6:12 pm
Location: Berlin, Germany
Contact:

Re: No icns for compiled app

Post by thinkitsimple »

It seems, that it was a cache-problem within OS X. I deleted the compiled app and then compiled it again and the app-icon is there.

Thank you.
Michael

PureBasic 5.51, macOS 10.12.2 Sierra
Post Reply