I would like Firefox to use the global menu on KDE Plasma 5.19 running on X11.

  • The widget set for both GTK and KDE is Breeze.
  • I am currently using Kubuntu 20.10, but also have machines running 18.04 and 20.04. Global menu does work on 18.04, but not 20.04 or 20.10.
  • Existing questions on the topic are outdated, mostly related to issues with appmenu on Unity.

The global menu has never worked for me with Firefox. The global menu does work with other applications that have menus.

  • GTK2: xournal
  • GTK3: geany, geeqie
  • KDE: Falkon, Konsole
  • Others: Google Chrome, LibreOffice

The following potentially relevant services are running:

  • Application menus daemon
  • GNOME/GTK Settings Synchronization Service

The following do not work:

  • plasma-browser-integration package and associated add-on.

  • xdg-desktop-portal-* packages.

  • Wayland. The global menu of GTK apps do not work in Wayland. Wayland also has too many other defects.

  • Restarting Firefox with a fresh profile.

  • Installing the following packages. Most of them were not necessary for other applications to use the global menu.

    appmenu-gtk2-module appmenu-gtk3-module appmenu-gtk-module-common appmenu-registrar gir1.2-dbusmenu-glib-0.4 gir1.2-dbusmenu-gtk-0.4 gir1.2-dbusmenu-gtk3-0.4 indicator-appmenu indicator-appmenu-tools libappindicator1 libappindicator3-1 libappmenu-gtk2-parser0 libappmenu-gtk3-parser0 libdbusmenu-glib4 libdbusmenu-gtk3-4 libdbusmenu-gtk4 libdbusmenu-qt5-2 libdbusmenu-tools libindicator3-7 libindicator3-tools libindicator7

What needs to be done to get Firefox to use the global menus?

  • 3
    Global menu used to work with Firefox in KDE Neon 18.04 (and probably Kubuntu 18.04 as well), because (as far as I know) Ubuntu developers used patch it for compatibility with Unity (which also had global menu). As Unity was dropped, the patch was discontinued – Archisman Panigrahi Oct 31 '20 at 14:33
  • 1
    I only know that the patch was dropped, but don't know how to use global menu with KDE. What I have found so far (in Manjaro Forum) is that OpenSUSE still has a patched version of firefox with global menu. Although it can be installed in Arch based OS (I have not tested it though), I don't know how to install it in Ubuntu. One possible solution would be to download the Firefox .deb file from Ubuntu 18.04 and run it in 20.04 (but be aware that this may create serious dependency issues). – Archisman Panigrahi Nov 1 '20 at 16:06
  • 2
    You can certainly write your own answer. However, writing an answer like "It was dropped, and therefore global menu cannot be used anymore" may forever close the question (that's why I did not want to write an answer). It may be good idea to keep the question open (that is, don't accept your own answer until you find a real solution to the problem) so that someone capable of bringing back the global menu in Firefox would want to work on this feature, if they find this. The issue with the PPA is that it may soon loose support, and Ubuntu 18.04 won't be available after a few more years. – Archisman Panigrahi Nov 1 '20 at 16:35

To use the global menu with Firefox currently requires a patch. Archisman Panigrahi explains:

Global menu used to work with Firefox in KDE Neon 18.04 (and probably Kubuntu 18.04 as well), because (as far as I know) Ubuntu developers used [to] patch it for compatibility with Unity (which also had global menu). As Unity was dropped, the patch was discontinued

Specifically, the patch exports the menu via dbus. Without it, Firefox does not export the menu, so other applications can't access it. No global menu.

The current options:

  • Use the method described in this answer to install the latest version of firefox from repository of Ubuntu 18.04. You don't need to use apt-mark or find updates manually (unlike the next bullet point) if you use this method.

In this method, you would receive firefox updates normally as you did before (at least, until 18.04 is supported).

Results global menu in action

  • Find and use patched binaries. Firefox in 18.04 repositories continue to apply the menu patch. There are other patched and renamed versions of Firefox, but they should probably be avoided for various reasons. You can prevent the package from upgrading to an unpatched version with sudo apt-mark hold firefox.

  • Recompile the source with the patch. This is the "safest" option. A minimal development toolset can be installed to upload the source to launchpad.net for compilation and inclusion in a PPA.

  • Live without Firefox global menus, and hope they're eventually implemented upstream. (Is there anything in the menu that you really need?)

See also:

  • Hey, I found a way to use Bionic Firefox with in the normal way (automatic updates). I followed this answer. There's no need to manually grab .deb files and run apt-mark hold. And the global menu works. Shall I edit parts of your answer appropriately. – Archisman Panigrahi Jan 3 at 7:08
  • @ArchismanPanigrahi Thanks... I think it would be fine as a bullet point with short description and link to the other question. I personally decided to just do without global menus for Firefox. – xiota Jan 3 at 8:09

Partial success on my side (and it was running on 20.04 until upgrading):

Based on https://forum.manjaro.org/t/howto-enabling-kde-global-menu-support-in-mozilla-firefox-and-thunderbird/7405 I created /etc/profile.d/mozilla-common.sh:

export MOZ_PLUGIN_PATH="/usr/lib/mozilla/plugins"

Starting Firefox will show the global menu. Switching to another window and back to Firefox and the global menu is gone.

  • 1
    This does not work for me. What does happen is the global menu of the terminal emulator persists after the firefox window appears. Switching windows seems to clear out the glitch. Most of the info on that page discusses using a patched version of firefox. – xiota Oct 31 '20 at 20:49

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.