Dock application icon in wxPython

In wxPython on Mac OS X, it is possible to display a custom icon when starting an application. Right now, when I launch an application I wrote, a blank white icon is displayed on the dock. How can I change it?

+1


source to share


1 answer


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 need to use the icns file. I used img2icns to create it.

+1


source







All Articles