Qt Creator - how to set application icon for ubuntu linux?

前端 未结 1 1761
盖世英雄少女心
盖世英雄少女心 2020-12-16 03:29

I have seen the original question qt-creator-how-to-set-application-icon

but it did not help me because i am building an app in ubuntu and the Qt`s

相关标签:
1条回答
  • 2020-12-16 04:15

    Linux does not have any standard for reading embedded resources, so there is no way to embed the icon in the application binary itself and have it display in the menu and launcher. You will have to install your icon in the appropriate pixmaps directory and a .desktop file in appropriate apps directory pointing to your application and respective icon.

    The Qt documentation you quoted refers to icon theme specification, which describes where the files should be installed. Look for the Installing Application Icons towards the end for summary of what needs to be done.

    You will have to install the files in the "install" target of your build system (qmake or cmake or what you use) and possibly create a Debian package on top of that. The Qt Creator is unlikely to help you with these.

    0 讨论(0)
提交回复
热议问题