views:

192

answers:

1

In wxPython on Mac OS X is it possible to display a custom icon when an application is launched. Right now when I launch the app I wrote, a blank white icon is displayed in the dock. How would I go about changing it?

+1  A: 

I have this in my setup file to add an icon:

from setuptools import setup

APP = ['MyApp.py']
DATA_FILES = []
OPTIONS = {'argv_emulation': True, 
    'iconfile': 'MyAppIcon.icns' }

setup(
    app=APP,
    data_files=DATA_FILES,
    options={'py2app': OPTIONS},
    setup_requires=['py2app'],
)

I think you have to use an icns file. I used img2icns to create one.

Loïc Wolff