How can i make Popover appears outside application window like menu in gnome-shell panel? Or should i use another GTK widget?
Gtk3 Popover outside the window
Asked Answered
If I recall correctly, this is a limitation of GTK+; sorry. –
Chromo
@Chromo But how gnome-shell panel works? –
Marra
Gnome-shell isn't GTK. It renders the desktop, so it can draw outside of windows if it likes. –
Xeroderma
@ptomato, I dig in source, and think that Gnome-shell uses Clutter as container for GTK Widget. I made undecorated transparent window with this stack, but still not found good method for embedding gtk widget. –
Marra
I believe on Wayland GtkPopovers can go beyond the window though. –
Finnougric
Exactly, this is an X11 implementation limitation one of GTK+. There could easily be a workaround, but nobody has implemented it and all manpower now goes to wayland. –
Melloney
On sway, it appears that popovers can go beyond the window, but then they do not receive any mouse events :/ –
Disjoint
So necro. Much post –
Marra
There is no "necro" when it comes to useful information. People update old content all the time - see wikipedia. You don't need to tell others about that br. - many old answers can still be partially correct but simply require more information to work. Perhaps things have changed in GTK4 now, I would not be surprised. –
Scudo
This should be possible (at least on wayland). gtk_popover_set_constrain_to (GtkPopover *popover, GtkPopoverConstraint constraint); "GTK_POPOVER_CONSTRAINT_NONE"
and
gtk_popover_set_pointing_to (GtkPopover *popover, const GdkRectangle *rect);
© 2022 - 2024 — McMap. All rights reserved.