Set the label to expand, so it actually fills
the width that we allocated for it, instead
of shrinking back to the minimum width for
its height.
Fixes: #5521
Setting max-width-chars to the number of characters
in the string works ok only as long as the average
char width we get from Pango matches reality. Sadly
that seems not always the case, and this code was
causing short Chinese tooltips to always be broken
into two lines.
Fixes: #4470
When transitioning from internal to malloc, the strings were placed in
the wrong order to g_strconcat(). This fixes an issue with undo where
if you hit the boundary in just the right way, your undo stack will do
unexpected things.
Fixes#5506
When the model button just has a text label and accel text,
the button fills and the accel label is implicitly aigned to end.
When there's also a icon, even though it's not shown (because
icons are only shown if there's no text), the button doesn't fill
and the accel ends up not aligned (assuming one of the other buttons
is longer). Ensure that the accel label is aligned to the end.
Fixes: https://gitlab.gnome.org/GNOME/gtk/-/issues/5504
Use the fallback logic to generate the base path for the GtkAtSpiRoot
if the GApplication has no DBus object path to guarantee that
the base path will not stay NULL.
`gtk_at_spi_cache_add_context()` checks if the GtkAtSpiContext's path
is NULL before inserting the context object into the hash table.
Do the same in `gtk_at_spi_cache_remove_context()` to avoid a NULL
pointer dereference in `g_str_hash()` during the hash table lookup
if a context with NULL path is removed. That can happen when the
GtkAtSpiRoot::base_path is NULL, which, in turn, can happen if
`g_application_get_dbus_object_path()` returns NULL.
==394047==ERROR: AddressSanitizer: SEGV on unknown address 0x000000000000 (pc 0x7fd1966f8b84 bp 0x7fff11e3ded0 sp 0x7fff11e3de58 T0)
==394047==The signal is caused by a READ memory access.
==394047==Hint: address points to the zero page.
#0 0x7fd1966f8b84 in g_str_hash (/usr/lib/libglib-2.0.so.0+0x37b84)
#1 0x7fd1966f9c09 in g_hash_table_contains (/usr/lib/libglib-2.0.so.0+0x38c09)
#2 0x7fd196062c10 in gtk_at_spi_cache_remove_context ../gtk/a11y/gtkatspicache.c:447
#3 0x7fd19606e0a9 in gtk_at_spi_root_unregister ../gtk/a11y/gtkatspiroot.c:653
#4 0x7fd196067f58 in gtk_at_spi_context_unrealize ../gtk/a11y/gtkatspicontext.c:1559
#5 0x7fd195ced97f in gtk_at_context_unrealize ../gtk/gtkatcontext.c:668
#6 0x7fd195f5576e in gtk_widget_unroot_at_context ../gtk/gtkwidget.c:2399
#7 0x7fd195f55bd2 in gtk_widget_unroot ../gtk/gtkwidget.c:2499
...
The marked days are set only as part of gtk_calendar_select_day().
This is insufficient, especially because the day-selected signal
is emitted after the marked days are set in gtk_calendar_select_day().
The marked day gets applied to the current month, and either the previous
or subsequent month if they are visible within the current month.
This doesn't make any sense and likely was an accidental regression
in a6f9052cf1. Clarify the docs.
As part of a6f9052cf1, marked days lost
their style, essentially making that function worthless. Previously,
they were simply bolded, but that doesn't give them proper justice.
The value property is only getting notified when it's unset
or when it's set from gdk_drop_real_value_async(). Make sure
to always notify :value when its changed
A screen reader user is not interested in GTK internals, for example,
he does not care whether a button is an image button or not,
and a screen reader will report the fact that it is a button anyway.
Same applies for GtkEntry widgets, for example.
This actually is sufficient to fix gnome-control-center#2244.
And, according to the discussion in #5145, it should be fine.
We no longer need to make much distinction between multiple logical
devices, plus it breaks esp. with the Xwayland input device distribution.
Just iterate across all devices and reset their scroll valuators.
Closes: https://gitlab.gnome.org/GNOME/gtk/-/issues/4160
(cherry picked from commit 824e983372)
This was causing animation and transition to stop randomly and reset
their state to initial state.
This issue has existed since commit
7b68bdb831.
Closes#4426
tests/testmountoperation.c: Fix build on Windows
See merge request GNOME/gtk!5126
(cherry picked from commit b4db48935d)
1a5a65ac tests/testmountoperation.c: Fix build on Windows
listitemwidget: Setup factory only once the widget is visible
See merge request GNOME/gtk!5374
(cherry picked from commit 188f9269b7)
7ad693f8 gtkcolumnviewcolumn: Only create cells when the column is visible
The owner_events=TRUE grab makes GDK on X11 see events happening
outside every client window as received on the grab window.
Additionally check that the pointer is inside the grab window
(i.e. it received GDK_CROSSING_NORMAL crossing events for the
core pointer) in order to handle clicks happening outside client
windows.
These new paths are expected to be a no-op on Wayland, and to
also work for touchscreen input on X11, due to emulated pointer
events.
listbase: Cancel rubberband if not handling drag
See merge request GNOME/gtk!4831
(cherry picked from commit ae097d9674)
efbd2289 listbase: Cancel rubberband if not handling drag
listbase: Use set_focus_child properly
Closes#5433 and #5432
See merge request GNOME/gtk!5169
(cherry picked from commit 1f001a8f6a)
7081bfc6 listbase: Split scroll_to_item for reuse
93e591fd listbase: Use set_focus_child properly