Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct
No picture in system tray
Kurby last edited by
I try to implement a System Tray Icon in my application
After using the search and several tutorials I already have an Icon, but without any kind of picture. The Icon in the bar is empty.
I am using the following code in the resource file:
The file is saved in my project directionally where the other files are saved.
I included the resource file via my .pro file,
@RESOURCES += res.qrc@
The creation of the System Tray Icon is in the constructor
@trayIcon = new QSystemTrayIcon(this);
As said the icon in already in the bar in the corner of the desktop, but without the picture (favicon.ico).
Do you have any idea?
Thank you very much in advance for your help!
Hi and welcome to devnet,
You should add some check to ensure your image is found and loads.
Also what OS/Qt combo are you using ?