Created attachment 155255 [details] bug related screenshot SUMMARY *** NOTE: If you are reporting a crash, please try to attach a backtrace with debug symbols. See https://community.kde.org/Guidelines_and_HOWTOs/Debugging/How_to_create_useful_crash_reports *** Please see the attached screenshot, using the normally displayed software "konversation" for comparison. STEPS TO REPRODUCE 1. Launch kleopatra 2. See the main window OBSERVED RESULT The software icon does not exist on the mainwindow. EXPECTED RESULT The software icon exists on the mainwindow. SOFTWARE/OS VERSIONS Windows: NO macOS: NO Linux/KDE Plasma: NO (available in About System) KDE Plasma Version: NO KDE Frameworks Version: 5.100.0 Qt Version: 5.15.6 ADDITIONAL INFORMATION It seems that setWindowIcon() is needed in the main(). Maybe this is helpful: https://invent.kde.org/network/konversation/-/blob/master/src/main.cpp#L99 .
As commented on irc, I suspect the cause is that the window manager used here is an X11 one which only fetches the window icons from the X properties directly, does not map the _KDE_NET_WM_DESKTOP_FILE to a desktop file to fetch metadata like the app icon. For those one still needs to set the window icon directly, e.g. by adding app.setWindowIcon(QIcon::fromTheme(QStringLiteral("kleopatra"), app.windowIcon())); to https://invent.kde.org/pim/kleopatra/-/blob/master/src/main.cpp#L128 While at it, all the app metadata setting is better moved to before the "// Initialize GpgME" section, otherwise e.g. the text in the warning message will not be translated properly I expect as well as the window again missing needed metadata to be nicely shown as Kleopatra window.
Git commit 9dfe6709cff75f777310968bb30151599e68dd0c by Ingo Klöcker, on behalf of Ingo Klöcker. Committed on 20/01/2023 at 14:14. Pushed by kloecker into branch 'master'. Explicitly set the window icon Apparently, some window managers need the icon to be set explicitly. M +2 -0 src/main.cpp https://invent.kde.org/pim/kleopatra/commit/9dfe6709cff75f777310968bb30151599e68dd0c
Which version will this change be included in?