Gala: Context menus improperly positioned in Firefox

Created on 23 Jan 2019  ·  12Comments  ·  Source: elementary/gala

Since Juno, dropdown and context menus in Firefox always pop up some two dozen pixels up relative to where they should be. See for yourself - the cursor wasn't moved:

menu-problem

This is very likely to be caused by the overlapping dropdown menu trick EOS uses. I also had no such problem with Loki, so it's a recent regression. I believe this is a window manager issue as switching to Adwaita theme didn't help any. It was reported at least twice on Reddit late last year and once here (#403).

Incomplete Out of Scope

Most helpful comment

Having Firefox use CSD works around the issue, but not everyone wants to use (or even knows about) Firefox CSD.

All 12 comments

@far-echo what do you mean by “overlapping dropdown menu trick”? I don't believe that's anything we're doing in Gala…

I mean just that - on Windows, dropdown menus are attached to the dropdown menu button:
no-overlap

Elementary opts to display the menu over the button instead:
overlap

If the dropdown opens at the bottom of the screen, it instead, well, drops up and fails embarassingly? Anyway, look at the screenshot below, then take a look at the one at the first post, they're clearly related, as the unwanted offset is roughly the same in size:
overlap-fail

I'm short of culpruits at the moment: it's either a css style (maybe switching to Adwaita didn't override some styles), or the window manager. It's most likely the latter, as the offset isn't static - it's calculated so that the button is overlapped by the currently selected item. I don't know if this is achievable using CSS alone:
big-menu-overlap

I've also skimmed .css files for negative margins and didn't find any.

@far-echo that's not anything elementary OS is doing specifically, though—that's GTK-standard behavior. I have a feeling this is just a bug in Firefox.

@cassidyjames I've used Firefox with all Ubuntu versions since 16.04, never had any issues like that. If you insist the WM is not to blame, I'll take a deeper look at .css then. Please note that this isn't unimportant as it looks - the Epiphany is a joke for any power user, and Firefox being glitched means people freaking out and maybe never returning, as I almost did.

Having Firefox use CSD works around the issue, but not everyone wants to use (or even knows about) Firefox CSD.

@cassidyjames I've used Firefox with all Ubuntu versions since 16.04, never had any issues like that. If you insist the WM is not to blame, I'll take a deeper look at .css then. Please note that this isn't unimportant as it looks - the Epiphany is a joke for any power user, and Firefox being glitched means people freaking out and maybe never returning, as I almost did.

I'm not sure but I think I have similar issues. When I write something in a text field FF puts the "suggestion box" right onto the textfield hiding everything I type. It annoys the crap out of me and I considered it to be an FF bug.

For the record, I've installed FVWM and Metacity on my Elementary box and run those in separate sessions and the Firefox issue goes away. Logging into Pantheon brings the issue back. It's somehow related to either Gala or the GTK stylesheet...

menu-problem

On this image, the separators are white on a grey background. Anyone knows if this a Mozilla or a elementary's issue?

I'm getting a similar issue on the check marks of Libreoffice menus. Check marks are white on light grey menu's.

@Blast-City my ff-menu looks like yours but my libreoffice writer menus look fine (a shadow effect)

@Blast-City my ff-menu looks like yours but my libreoffice writer menus look fine (a shadow effect)

Hi.

Thanks for you reply.

What colour are the check marks on the view menu? The problem that i have is that the check marks are white which makes it difficult to view since it have a low contrast against a grey background. The same problem that menu separators on Firefox have.

Thanks.

Please file separate issues against the affected projects. This issue has unhelpfully become a catch-all for anything related to menus. Consequently, I'm going to close this as out of scope.

Was this page helpful?
0 / 5 - 0 ratings