How to get widgets under the mouse position?

Depending on your actual use case, you can rely either on gtk_widget_pick or gdk_device_get_surface_at_position in combination with gdk_seat_get_pointer.

1 Like