Firefox minimise and full-screen buttons missing since switch to Wayland

I will post this as a bug if someone could kindly point me in the right direction – is this a bug with plasma? Which part of plasma? (I would guess kwayland-integration.) Sorry, not a fan of KDE’s bug submission system, as I don’t know KDE’s architecture well enough to tell developers which part of their software is buggy.

But maybe it isn’t quite a bug as a misconfiguration…
Started on 22.10, upgraded to 23.04 and then 23.10. Decided to switch to Wayland yesterday. everything smoother and faster, but Firefox’s windows control buttons look like they’re from Gnome, in that there is a close button but no minimise or full-screen buttons (since, on Gnome, they’d not be in the window, but across the top toolbar of Gnome).
Without going back to X11 or enabling the title bar in Firefox, how might I fix this?

1 Like

Try regenerating GTK styles: systemsettings - appearance - application style - gnome/gtk - select a different style (e.g. adwaita) and apply, then select back to breeze and apply

Jinliu, that has changed the appearance that it now has buttons, but that is a patch to solve a small issue with a greater problem, I believe. I’ve found another symptom of the underlying cause, if not the cause itself; Plasma integration isn’t working. Error message on the integration plugin is: Failed to connect to the native host. I’m using the snap version of Firefox.

Backstory: Two similar devices: laptop and desktop. Both loaded with Kubuntu 22.10 in Jan/ Feb, upgraded to 23.04 and then 23.10. Post 23.10 upgrade, the laptop demonstrated graphics glitches on X11, opening Firefox and Chrome with glitch that looked like, imagine the dice face for 5, create a b&w tile of that about 8x8 pixel, repeat the tiles, created a transparency mask out of that pattern and applied it to Firefox and Chromium windows. I switched from X11 to Wayland on the laptop and now everything on the laptop seems correct, graphics glitch gone. Liking Wayland and the laptop’s improved responsiveness, I decided to switch to Wayland on the desktop PC, and it is here that the plasma integration will not work with Firefox. Biggest difference between laptop and desktop is one is AMD, other is Intel/NVidia.

Anyway, more digging until I find the fix for both devices to be stable and fully operational on Wayland.

It sounds like your Firefox is using client-side decoration, i.e. drawing its own decoration instead of letting the system do it.

That’s not really a Plasma bug in any way, rather a decision from Firefox.

In about:config you can disable this by setting browser.tabs.inTitlebar to 0

  1. Set Breeze theme for GTK apps

  1. Disable titlebar in Firefox and remove any extension like “Firefox Color”

  2. sudo apt -y install xdg-desktop-portal-gtk then reboot.

1 Like

Thanks for your suggestions, but a couple have missed that in my original question , I ask how to fix without enabling the title bar in Firefox.

I think I’m on to something with the Plasma Integration plug-in not working. Will keep you posted. Any more suggestions appreciated.

I ask how to fix without enabling the title bar in Firefox

Did you try the 3 steps above, it didn’t say to activate titlebar but to disable it.

Sorry medin, I was too quick to say you’re suggesting I turn it on, you were suggesting I check that it is off. Alas, made no difference.

I purged snap Firefox and reinstalled, then I tested with Flatpak Firefox, same error. Using Mozilla’s PPA I got the deb version and that worked as intended, both the Plasma Integration, and the correct minimise and full-screen buttons.

Why my laptop’s snap version of Firefox behaves when the PC doesn’t… meh.

Sorry, I forgot you are not using native version, so the main culprit is surely xdg-desktop-portal-gtk, did you install it and reboot ?

Thank you very much. I had this bug like a 10 months or so and it was make me crazy. I hope it will fix soon :hearts:

1 Like

I’m still experiencing this problem and it’s very frustrating.

xdg-desktop-portal-gtk is already installed.

1 Like

For any of you in here reading this, and is using the snap version (from ubuntu).
Mozilla pretty much said “do not use canonicals repackaged version of firefox, it is bugged and we do not provide support for it” a few months ago.

The reason they did that was because of stuff like this:

Mozilla has no control over the snap, that is CANONICAL (Ubuntu).
But where does the bug reports go you think?

So people made posts like this instead: Can't install Firefox snap | Firefox Support Forum | Mozilla Support
Again, not anything mozilla can do. 100% on canonical.

On specifically Ubuntu, even if you used apt to install, THEY LINKED THAT TO THEIR SNAP WITHOUT LETTING THE USER KNOW!
I do not know if they still are, but the point is, do not use firefox snap (not sure if flatpak has the same problems, cant find much about it).

Steam also did something similar. Do not use snap.
Flatpak version I think is working ok.