Firefox shows only a close button in more than one Wayland compositor, even across different distributions. The other buttons appeared after installing XFCE. What controls this, and can I change it?
Why does Firefox only show a close button on Wayland?
Answers
Firefox can draw its own window decorations rather than leaving them to the compositor. In that case, the button layout can come from desktop settings, so changing compositors doesn't necessarily change the buttons Firefox draws.
Try right-clicking the tab bar and opening the toolbar customization screen. Enabling the title bar or native system decorations may let the window manager provide the decorations instead. The exact option and result can depend on the Firefox version and compositor.
Reply to this answer
For Firefox's own decorations, check the GTK button layout. If gsettings is available, you can try setting org.gnome.desktop.wm.preferences button-layout to 'appmenu:minimize,maximize,close'. This can affect other GTK applications too, not just Firefox.
Read the current value first with gsettings get org.gnome.desktop.wm.preferences button-layout so you can restore it if you don't like the result. Restart Firefox if the change doesn't appear immediately.
Caldo:
That setting controls the layout Firefox may use when drawing its own buttons. It won't necessarily change decorations supplied by the compositor.
Reply to this answer
The XFCE result is a useful clue, but it doesn't prove the distro was the cause. Installing a desktop environment can change which settings or decoration services are available to applications. Compare the button layout settings in the two sessions before assuming Firefox itself changed.
Reply to this answer
Add your answer
Answers are reviewed before publication.
_r46+vexnaro.8:
That explains why switching compositors didn't necessarily change the layout. What makes Firefox choose only the close button?
_x72+fendrix.4:
It may be picking up a GNOME-style button layout from GTK settings, or a default used when those settings aren't available. The close-only layout isn't necessarily a compositor rule.