Details
-
Bug
-
Resolution: Cannot Reproduce
-
Not Evaluated
-
4.8.0
-
None
-
GNOME/X11
Description
In GNOME/X11 environments, there's a hardcoded check in QApplication for a specific GNOME config setting ("/desktop/gnome/interface/menus_have_icons") during initialization. If this setting is disabled, the Qt::AA_DontShowIconsInMenus attribute is set, globally disabling icons in menus (by default).
Although applications that want to blend in with a GNOME desktop environment want to match the user's preference, those with highly customized styles may require more specific behavior. In our case, important icons simply disappeared when we upgraded to a newer desktop environment that had a different default value for this GNOME setting.
The workaround is simple: force the Qt::AA_DontShowIconsInMenus attribute to true after initializing the application.
But really, it seems wrong for this to be a global attribute in the first place; this should be driven by the style, like virtually every other aspect of a menu's visual appearance.