Details
-
Bug
-
Resolution: Unresolved
-
P2: Important
-
None
-
5.15, 6.5, 6.8, 6.9
-
None
Description
gtk-fallback-icon-theme used by QGtk3Theme was deprecated in GTK 3.10 by https://gitlab.gnome.org/GNOME/gtk/-/commit/aa78c888eb6ee2c66598318d8befe4176164ddac and returns an empty string since then. The gnome value used by QGnomeTheme refers to gnome-icon-theme that is abandoned after GNOME 3.12 and isn't shipped by modern distros.
GTK just falls back to hicolor since then (which is exactly what QGenericUnixTheme does but not QGtk3Theme/QGnomeTheme):
https://gitlab.gnome.org/GNOME/gtk/-/blob/main/gtk/gtkicontheme.c?ref_type=heads#L289
https://gitlab.gnome.org/GNOME/gtk/-/blob/main/gtk/gtkicontheme.c?ref_type=heads#L1973
Wrong SystemIconFallbackThemeName leads to a bugged behavior when the preferred icon theme is unavailable: normally the toolkit should fallback to hicolor that provides icons installed by applications themselves but this doesn't happen due to the wrong SystemIconFallbackThemeName.
This is especially annoying when application is distributed via snap package: snap has only a bunch of icon themes provided by the gtk-common-themes snap and if the user uses some other theme not present in the snap, Qt doesn't use any icons, even those installed by the application itself to hicolor.