silx.app.view: Fix Ubuntu taskbar icon by setting app.setDesktopFileName#4475
Conversation
|
|
||
| app = qt.QApplication([]) | ||
| if hasattr(app, "setDesktopFileName"): | ||
| app.setDesktopFileName("org.silx.SilxView") |
There was a problem hiding this comment.
Unless I miss something, this relies on what's in package/desktop to be installed on the host. So one must have installed silx as an Ubuntu package to have the icon... Did you tested on a computer without silx installed on the system?
There was a problem hiding this comment.
Indeed, it does not work if we just pip install...
There was a problem hiding this comment.
From what I tested/searched, there seems to be no neat solution to display the icon in the menu bar that only relies on the application code.
However this fix is needed even if it is not the only required step: It makes it work when the icon and .desktop file are already available on the host. So it is required to install the .desktop and icon another way.
19e68c8 to
32440aa
Compare
<Module or Topic>: <Action> <Summary>(see contributing guidelines)This helps desktop environments (notably Ubuntu/GNOME) match the running app window with the installed desktop entry, so the correct taskbar icon is used.
Should not impact any other distros.