After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 784314 - entry completion regression on wayland
entry completion regression on wayland
Status: RESOLVED OBSOLETE
Product: gtk+
Classification: Platform
Component: Backend: Wayland
3.22.x
Other Linux
: Normal normal
: ---
Assigned To: gtk-bugs
gtk-bugs
: 784488 788140 789031 789127 (view as bug list)
Depends on:
Blocks:
 
 
Reported: 2017-06-29 01:23 UTC by Christian Hergert
Modified: 2018-05-02 18:39 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
wayland: Queue empty area redraws if there was no damage area (1.94 KB, patch)
2017-10-04 14:41 UTC, Carlos Garnacho
reviewed Details | Review
gdk/wayland: Avoid idempotent wl_subsurface.set_position calls (1.09 KB, patch)
2017-10-05 23:11 UTC, Carlos Garnacho
committed Details | Review
screenshot issue (1.62 MB, image/png)
2017-10-17 22:57 UTC, Lionel Landwerlin
  Details

Description Christian Hergert 2017-06-29 01:23:02 UTC
I've noticed with Epiphany while on Rawhide that the URL entry completion exhibits some weird behavior. I tested on Xorg and did not have the same behavior, so I'm assuming this is an issue in Gtk+ directly and not Epiphany.

 gtk3-3.22.16-1.fc27.x86_64
 epiphany-3.25.2-1.fc27.x86_64

When typing in the URL entry a website I have previously visited, things start out fine. So say I start typing "twitter.". Everything is good, I see various completion items in the GtkEntryCompletion window.

Then i type "twitter.f", which has no entries to match. Still, things are fine in that I can see the text I'm typing.

Now it gets weird. If I continue to type "twitter.fffff" I only see "twitter.f". But if I move my mouse over the GtkEntryCompletion window, the resulting "ffff" text will show up.

Again, this doesn't happen under Xorg, so I'd guess it has to do with some of the weirdness in GtkEntry w/ Wayland/subsurface/popup-window type stuff.

I'd submit a test-case, but "just run Epiphany on Wayland" is probably enough?
Comment 1 Carlos Garnacho 2017-07-24 10:34:25 UTC
This seems caused by commit 5cb5baa7d on Mutter.
Comment 2 Guillaume Ayoub 2017-07-24 10:41:42 UTC
(In reply to Carlos Garnacho from comment #1)
> This seems caused by commit 5cb5baa7d on Mutter.

Reverting 5cb5baa7d fixes the issue for me too.
Comment 3 Guillaume Ayoub 2017-07-24 10:42:31 UTC
*** Bug 784488 has been marked as a duplicate of this bug. ***
Comment 4 Michael Catanzaro 2017-09-30 13:13:46 UTC
*** Bug 788140 has been marked as a duplicate of this bug. ***
Comment 5 Carlos Garnacho 2017-10-04 14:41:48 UTC
Created attachment 360912 [details] [review]
wayland: Queue empty area redraws if there was no damage area

After wl_surface.commit, a surface actor may be redrawn if there was a
pending wl_surface.damage, resized if any other property resulted in a
different layout, or none of the above if whatever state is applied
results in the same size.

For this last case, Clutter won't hit the repaint machinery, so there
may be frame callbacks that won't be dispatched until anything is actually
redrawn on screen.

Since we want these frame callbacks to run after wl_surface.commit, queue
a redraw on the surface actor with an empty clip area, in order to ensure
a stage redraw will be queued.
Comment 6 Jonas Ådahl 2017-10-05 14:26:45 UTC
Review of attachment 360912 [details] [review]:

This doesn't look right to me. Applying a state shouldn't imply we always will redraw, as applying a state can mean things that doesn't affect drawing at all (such as changing the title, asking to be maximized, etc). If there is no damage attached, I don't think a client should be able to rely on getting a frame callback since there is no reason for the compositor to redraw anything.
Comment 7 Carlos Garnacho 2017-10-05 23:11:42 UTC
Created attachment 361003 [details] [review]
gdk/wayland: Avoid idempotent wl_subsurface.set_position calls

These may not result on wl_surface.frame callbacks, yet we do trigger
a frame clock tick that would get stuck on the lack of such callback.
Comment 8 Carlos Garnacho 2017-10-05 23:12:39 UTC
This fixes it on the gtk+ side, although it's funny that it also used to work on weston...
Comment 9 Jeremy Bicha 2017-10-14 20:41:35 UTC
I confirm the 361003 gtk3 patch fixes the Epiphany issue for me.
Comment 10 Michael Catanzaro 2017-10-14 23:22:51 UTC
So we really need mutter fixed ASAP, like several weeks ago. Any problems with pushing this and making a release?
Comment 11 Jeremy Bicha 2017-10-15 23:58:28 UTC
*** Bug 789031 has been marked as a duplicate of this bug. ***
Comment 12 Jonas Ådahl 2017-10-16 02:32:46 UTC
Review of attachment 361003 [details] [review]:

lgtm.
Comment 13 Jonas Ådahl 2017-10-16 02:33:56 UTC
(In reply to Carlos Garnacho from comment #8)
> This fixes it on the gtk+ side, although it's funny that it also used to
> work on weston...

My suspicion would be that weston is more redraw prone.

(In reply to Michael Catanzaro from comment #10)
> So we really need mutter fixed ASAP, like several weeks ago. Any problems
> with pushing this and making a release?

FWIW, the patch that fixes the issue is for GTK+.
Comment 14 Carlos Garnacho 2017-10-16 09:30:07 UTC
Attachment 361003 [details] pushed as 8aa6d59 - gdk/wayland: Avoid idempotent wl_subsurface.set_position calls
Comment 15 Lionel Landwerlin 2017-10-17 22:56:35 UTC
This commits break totem's subsurface positioning.
Comment 16 Lionel Landwerlin 2017-10-17 22:57:17 UTC
Created attachment 361772 [details]
screenshot issue

This seems to only happen when the window is maximized or fullscreen.
Comment 17 Michael Catanzaro 2017-10-17 23:30:27 UTC
OK, can I ask that the mutter optimization be reverted until we figure this out? This is the sort of thing that needs to be sorted out in the current development cycle at this point, not at the expense of GNOME 3.26 users.
Comment 18 Lionel Landwerlin 2017-10-19 21:18:10 UTC
Any plans on reverting 8aa6d59b7a214ba03a83bcae8c43712f8e402927 while people investigate the popup issue?
Comment 19 Michael Catanzaro 2017-10-20 00:57:58 UTC
(In reply to Lionel Landwerlin from comment #18)
> Any plans on reverting 8aa6d59b7a214ba03a83bcae8c43712f8e402927 while people
> investigate the popup issue?

Due to the severity and urgency of the issue, I've reverted that commit on both gtk-3-22 and master, and also reverted mutter 5cb5baa7d on both gnome-3-26 and master.
Comment 20 Jeremy Bicha 2017-10-21 23:45:03 UTC
And as a followup, I reverted a test change for mutter that depended on 5cb5aa7d on both the gnome-3-26 and master branches.
Comment 21 Carlos Garnacho 2017-10-22 10:50:57 UTC
(In reply to Lionel Landwerlin from comment #16)
> Created attachment 361772 [details]
> screenshot issue
> 
> This seems to only happen when the window is maximized or fullscreen.

Does it also happen on weston? If such patch results on mispositioned subsurfaces, it would seem mutter is failing to propagate the position change to subsurfaces.
Comment 22 Lionel Landwerlin 2017-10-22 13:26:48 UTC
(In reply to Carlos Garnacho from comment #21)
> (In reply to Lionel Landwerlin from comment #16)
> > Created attachment 361772 [details]
> > screenshot issue
> > 
> > This seems to only happen when the window is maximized or fullscreen.
> 
> Does it also happen on weston? If such patch results on mispositioned
> subsurfaces, it would seem mutter is failing to propagate the position
> change to subsurfaces.

Same problem on weston. Again, just when the windows is fullscreen.
Comment 23 fakey 2017-11-01 17:07:43 UTC
*** Bug 789127 has been marked as a duplicate of this bug. ***
Comment 24 GNOME Infrastructure Team 2018-05-02 18:39:21 UTC
-- GitLab Migration Automatic Message --

This bug has been migrated to GNOME's GitLab instance and has been closed from further activity.

You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.gnome.org/GNOME/gtk/issues/844.