QML SystemTrayIcon application name
Solved
QML and Qt Quick
-
Hi,
I use SystemTrayIcon to display notifications using showMessage. The notifications are shown on MacOS and Windows 10. My problem is Windows 10, the notifications shows the name of executable file (myapp.exe, image attached), I need to show a custom application name. I tried changing qml window title, using QApplication::setApplicationName, setting icon.name: "My App Name": but none works. Is there a way to do this?
Using Qt version 5.12.0 in C:/Qt/5.12.0/msvc2017/lib
Minimal example
import QtQuick 2.12 import QtQuick.Window 2.12 import Qt.labs.platform 1.1 ApplicationWindow { title: "My App Name" SystemTrayIcon { visible: true icon.source: "qrc:/icons/myicon.ico" icon.name: "My App Name" } }
-
@convexbytes It turns out I only needed to set the qmake variable QMAKE_TARGET_PRODUCT