Closed probonopd closed 3 years ago
It does work e.g., with AppImages of Qt-based applications:
It also works for GoLang (Java based):
However, I could not get it to work for Firefox yet, which is a pity:
It even works for the Scribus Nightly AppImage which bundles practically everything:
So this seems to be a really robust, interesting solution
But then, it does not work for the Inkscape AppImage, a Gtk based application. Why?
Didn't Inkscape have global menus in Ubuntu Unity?
I don't quite understand Ubuntu's terminology, what does "indicator" mean? Is a way to say/get "global menu bar at the top of the screen"?
This code seems to be related: https://launchpad.net/indicator-appmenu
It works for the Xfce desktop itself:
But not for its own Thunar file manager:
_Why?__
It seems that for MATE, one needs a separate plugin:
https://packages.debian.org/buster/mate-applet-appmenu
For this to work with XFCE applications (Thunar, Parole, Ristretto, etc.), it seems Appmenu needs to be enabled [1][2]:
xfconf-query -c xsettings -p /Gtk/ShellShowsMenubar -n -t bool -s true
xfconf-query -c xsettings -p /Gtk/ShellShowsAppmenu -n -t bool -s true
xfconf-query -c xsettings -p /Gtk/Modules -n -t string -s "unity-gtk-module"
For good measure, it'd be a good idea to do add the following:
~/.gtkrc-2.0
:gtk-modules="unity-gtk-module"
~/.config/gtk-3.0/settings.ini
:gtk-modules=unity-gtk-module
gtk-shell-shows-app-menu=true
gtk-shell-shows-menubar=true
~/.xprofile
:if [ -n "$GTK_MODULES" ]; then
GTK_MODULES="${GTK_MODULES}:unity-gtk-module"
else
GTK_MODULES="unity-gtk-module"
fi
if [ -z "$UBUNTU_MENUPROXY" ]; then
UBUNTU_MENUPROXY=1
fi
export GTK_MODULES
export UBUNTU_MENUPROXY
This is for Ubuntu-based distros, otherwise just replace unity-gtk-module
with appmenu-gtk-module
.
Even with all these changes, GTK AppImages don't seem to work (e.g. GIMP and Inkscape):
Although LibreOffice's AppImage does work:
For comparison, these are GIMP and Inkscape working when using the distro's packages:
Regarding Firefox, I know for a fact that it used to work with older LTS versions of Ubuntu since they used a patched version. Here you can see it working in Ubuntu 18.04 LTS:
But alas, it doesn't work in Ubuntu 20.04 LTS:
For reference, you can find some patched version in Arch's User repository [1][2], although I haven't tested them.
Just extracted Arch's firefox-appmenu-bin [1] in Ubuntu 20.04 LTS and it works as expected:
Could this be packaged as an AppImage or pull and apply the patch before packaging?
BTW, all this magic seems to be achieved by using Dbusmenu [1]. I gather that the AppImages that don't have a working AppMenu are not packaging the appropriate dbusmenu libraries.
@aguslr you rock. Would you like to start working on this with me for real?
Focusing on Qt-based https://github.com/probonopd/panda-statusbar for now which is basically the KDE Plasma global menu system without Plasma dependencies.
@FreezyKaif do you realize that you are asking in a helloSystem bugtracker?
While I can't help you debug this issue on what certainly seems not to be helloSystem, here is the summary of my research into how Global Menus work: https://hellosystem.github.io/docs/developer/menu.html
Maybe it is helpful as a starting point for your debugging. Good luck! (Maybe you'd just like to try helloSystem where the global menu is a first-class citizen and enabled by default?)
Add "AppMenu Plugin" to the panel.
Also check out the Unity protocol and libraries and see if we can use this in a pure Qt desktop.