We were forwarding key events to the search entry
and unconditionally considered search started
afterwards. That is not correct, since things
like a Ctrl key press should not trigger search.
Fix this by only switching to search mode when
the event was actually consumed.
Closes: https://gitlab.gnome.org/GNOME/gtk/issues/1829
The key capture was interfering with other
entries in the dialog, so be smarter about
when we want to capture keys and when we
don't.
Closes: https://gitlab.gnome.org/GNOME/gtk/issues/1842
Apparently genTextures and friends only "reserves names", initializing
them will actually create them. Using glObjectLabel on textures before
initializing them will throw a GL_INVALID_VALUE error.
Just measuring it (so the warning goes away) but then not using the
values will later underallocate the text widget.
Instead, always reserve space for the icon (which will inevitable be
visible as soon as the searchentry is actually being used).
Fixes#1831
When rendering to a texture, collecting the render ops might bind a
different framebuffer, so bind the one we want again before doing the
actual rendering.
This adds debug groups in various places, including the debug
nodes if those are in use. This makes the traces in tools like
renderdoc much easier to read.
GL keeps the unoform state per-program, but not per-frame. So, we can't
pretend that this works for us. Keep the RenderOpBuilder around for the
entire lifetime of the renderer instead.
Added two new private GtkWidget API:
* gtk_widget_add_surface_transform_changed_callback()
* gtk_widget_remove_surface_transform_changed_callback()
The intention is to let the user know when a widget transform relative
to the surface changes. It works by calculating the surface relative
transform during allocation, and notifying the callbacks if it changed
since last time. Each widget adds itself as a listener to its parent
widget, thus will be triggered if a parents surface relative transform
changes.
This is a meson test, not a GTest thing. So:
- Use g_print(), not g_test_message
That makes meson test --verbose print the actual log messsages.
- Don't g_assert() all the time
Instead, run tests through to the end and just return a non-0 exit
status.
This fixes rendering to a texture on intel hardware. The glClear calls
would throw a GL_FRAMEBUFFER_INCOMPLETE error here, because the
gsk_gl_driver_begin_frame() call in do_render() reset the framebuffer
object in use.
Save the information whether the cursor in use is the default one, and
don't create a new cursor object in that case.
We previously created a new cursor object every frame just to compare it
to the current cursor in use and then throw it away.