开发者

pyqt4 Button image doesnt appear in .app

I create an .app using py2app, and the GUI was made with pyqt4, and one of the buttons has an image on ti, but when i run the app the image doesnt appear and wh开发者_JAVA技巧en i run it on the terminal it appears, how can I solve this?

Thank you in advance


when you launch python setup.py py2app you can pass two extra arguments:

--iconfile path/to/icon.icns 
--resources path/to/other/required/stuff

With the first one you set the Dock and App icon, with the second one you embed other needed resources into the .app folder, so that they are available when the app is started.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜