GNOME Bugzilla – Bug 756670
Popover is shown below clutter widget after tab switch from Gtk.Notebook
Last modified: 2015-11-03 12:26:28 UTC
Created attachment 313405 [details] ust click on "Mini-Mode" in the popover to see that it is drawn behind the black stage of the GtkClutter.Embed. After switching the Tab of a Gtk.Notebook the popover is shown below the gtk clutter embed. Examplecode see attachments. Just click on "Mini-Mode" in the popover to see that it is drawn behind the black stage of the GtkClutter.Embed. The popover should stay on top of it. To compile use: valac --pkg gtk+-3.0 --pkg clutter-gtk-1.0 test.vala
Created attachment 313877 [details] [review] GtkWindow: make popover stacking explicit The list of popovers will specify the stacking order, a _gtk_window_raise_popover() private call has been added so popover widgets can request being on top. Also, the stacking on popovers is ensured on gtk_window_size_allocate(), after the size/stacking changes on the child widget have finished, this will ensure popovers are kept on top of window contents.
Created attachment 313878 [details] [review] popover: Request raise on ::show This way latest shown popovers are ensured to be on top.
Created attachment 313879 [details] [review] texthandle: Request raising of text handle popovers.
These patches fix the bug on X11, not on wayland yet... there's a number of problems there: - The wayland backend is not restacking subsurfaces on ::raise/::lower - raise() semantics are hard to implement over wl_subsurface.place_above(), we may not have the full list of subsurfaces on gdk (and this testcase is also good at showing that, GtkClutterEmbed creates its own wl_subsurface, hidden from GDK for most purposes), so it's not possible to pick one in order to place ours above. This IMO goes through making it possible to request raising past all windows without knowing beforehand the previous one, it is already possible to implement ::lower knowing nothing else than the subsurface and parent windows.
Review of attachment 313877 [details] [review]: ok
Review of attachment 313878 [details] [review]: ok
Review of attachment 313879 [details] [review]: ok
Pushed with a slight fix for the second patch (added a NULL check) Attachment 313877 [details] pushed as fa3e0be - GtkWindow: make popover stacking explicit Attachment 313878 [details] pushed as 9d1b8df - popover: Request raise on ::show Attachment 313879 [details] pushed as 4f61fd0 - texthandle: Request raising of text handle popovers.