Closed Bug 1722767 Opened 3 years ago Closed 3 years ago

[Scale 1.5] Popups are broken in sway

Categories

(Core :: Widget: Gtk, defect, P3)

x86_64
Linux
defect

Tracking

()

RESOLVED MOVED
Tracking Status
firefox-esr78 --- unaffected
firefox-esr91 --- unaffected
firefox90 --- unaffected
firefox91 --- unaffected
firefox92 --- fix-optional

People

(Reporter: ojab, Unassigned)

References

(Blocks 1 open bug, Regression)

Details

(Keywords: regression)

Attachments

(6 files, 1 obsolete file)

Regressed by: 1718507
Has Regression Range: --- → yes
Attached video Screen recording

Looks like there are no popups instead of popups are not shown until hover.

Component: General → Widget: Gtk
Product: Firefox → Core

Please run with MOZ_LOG="WidgetScreen:5 WidgetPopup:5" env variable and attach the log here.
Thanks.

Flags: needinfo?(ojab)
Priority: -- → P3
Attachment #9233570 - Attachment is obsolete: true
Flags: needinfo?(ojab)

Here's both the log and a screen recording as I reproduce this. I believe it's the same behavior, but the popups do sometimes flicker into view.

This is on Wayfire (also based on wlroots), running on wlroots git from 3 days ago.

Is there any additional logging that would be helpful?

Screen recording of behavior: https://drive.google.com/file/d/1pVtA3zUDGAWtVigJuvCtCjvC0LBgmmev/view?usp=sharing

Maybe it would be more clear with additional sway debug logging.

I just tested that on Fedora 34 / sway-1.6-1.fc34.x86_64 / latest trunk but I can't reproduce it - popups are shown correctly.
I see lots of nsWindow::OnScaleChanged() signals - do you use multi monitor system? Is the popup missing on second monitor or so?

Flags: needinfo?(ojab)

I am running a multi monitor setup, but it also happens when laptop is undocked. Popups don't show on any display. The issue where addon popups wouldn't show on some outputs seems to have got worse.

Just to point out this issue is new on current nightly. FF 91 and earlier show the old issue with popups not showing on some outputs when they had different scales.

Single monitor with 1.5 scale here (and log from this config), tested with scale=1 and popups shows fine. So I guess enabled scaling is the culprit?

Flags: needinfo?(ojab)

How can I set the 1.5 scale please?
Thanks.

swaymsg output '*' scale 1.5 in the running session or output * scale 1.5 in config.

I can reproduce it with the scale, Thanks.

Summary: Popups are broken in sway → [Scale 1.5] Popups are broken in sway

BTW, tested with scale 2 and popups also missing, looks like it's about scaling and not about fractional scaling in particular.

I'm also using sway, not using any scaling, and have been experiencing this issue these past weeks on FF nightly.

I also found this, mozregression pointing me to the patch from bug 1718507 as the cause of the regression.

Arch Linux, sway-hidpi-git (AUR, a package that includes patches for high-DPI XWayland), scale 1.5. Also reproducible with scale 2, same symptoms exactly.

While bisecting, though, I noticed an interesting related issue: before the 1718507 patch, popups weren’t entirely visually reliable; sometimes they wouldn’t render, or would render a bit late. e.g. press Alt+H to open the Help menu, then keep tapping Left to cycle through the menus, and quite often it doesn’t render the menu. But in that case, it’s fully interactive, it just didn’t draw; do something like pressing Up/Down or hovering over another menu item and it redraws and draws properly. That issue is still reproducible, though less often, at scale 1 today.

At first I thought that might be related to a root cause and that the 1718507 patch might just be triggering that, but since then the failure is definitely somewhat different, so I’m not sure if there’s a common root cause or not. The popup that is broken is still keyboard- and mouse-interactive: Alt+H A opens the About Nightly window (… which is still not a floating window as it should be, per bug 1681158), and Alt+H followed by clicking in the place where that About Nightly menu item should be works as well. But it won’t redraw on hover like it used to, and the Left trick to cycle through menus is mostly broken, e.g. {Alt+H Left Escape I} opens Tools → Page Info, compared with {Alt+H Left I} before the patch. So I’m pretty sure there’s something concretely wonky about the popup windows now, even if the two issues happen to be related. But they’re still similar enough that I figured I’d at least mention it.

Another detail I accidentally deleted from my comment: bug 1717230 may be related, being something about popup windows consistently not rendering under Sway on a high-DPI output, but it’s from a month before the specific breakage here.

This is a bug on Sway side - we don't get xdg_positioner callback from wayland compositor. Let's track that at https://github.com/swaywm/sway/issues/6426

Status: UNCONFIRMED → RESOLVED
Closed: 3 years ago
Resolution: --- → MOVED

I think Bug 1727836 is a variant of this one.

You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: