Commit Graph

39630 Commits

Author SHA1 Message Date
Matthias Clasen
f9a3f13702 Merge branch 'main' into 'main'
GtkIMContextSimple: array bounds was not correctly checked

Closes #4771

See merge request GNOME/gtk!4748
2022-05-27 14:24:54 +00:00
Sebastian Keller
6e3dbc42a8 a11y: Realize GtkStackPage parent context before trying to get a ref
If a context is not realized, calling gtk_at_spi_context_to_ref() will
return a null ref, because its path has not been initialized yet. This
was already done for all other cases in get_parent_context_ref(), but
was missing for the GtkStackPage case.

Fixes: https://gitlab.gnome.org/GNOME/gtk/-/issues/4944
2022-05-25 14:56:05 +02:00
Matthias Clasen
393893b8db Merge branch 'blink-assertion' into 'main'
Remove an assertion that we hit

See merge request GNOME/gtk!4753
2022-05-23 14:08:43 +00:00
Matthias Clasen
b3e65bfdc1 Remove an assertion that we hit
It appears that we mess up accounting for blinking
cursors sometimes, and can hit blink_cb when there
is a nonempty selection.

Instead of asserting, warn and stop blinking.

Related: #4767
2022-05-23 08:28:00 -04:00
Benjamin Otte
72fe406c4d gesturedrag: Fix docs
Leftover from GTK3. Coordinates are widget relative everywhere now.
2022-05-22 12:45:28 +00:00
Víctor Marzo
3955633aa8 GtkIMContextSimple: array bounds was not correctly checked
Fixes #4771
2022-05-19 11:35:14 +02:00
Matthias Clasen
1fbca7a76a Merge branch 'let_selectable_label_mnemonic_self_focus' into 'main'
Allow selectable labels contents to be selected by mnemonic

See merge request GNOME/gtk!4741
2022-05-18 13:55:33 +00:00
Caolán McNamara
3f49d335d1 Allow selectable labels contents to be selected by mnemonic
expecially by the mnemonic of another label that targets it.

https://gitlab.gnome.org/GNOME/gtk/-/issues/4927

see also https://bugs.documentfoundation.org/show_bug.cgi?id=137748
2022-05-18 12:40:40 +01:00
Christian Hergert
b9574e119b checkbutton: fix critical when setting use-underline
This needs to make sure that we've created the label before applying the
setting on a child widget.

Fixes #4934
2022-05-17 12:28:25 -07:00
Matthias Clasen
c0747f2c2e Add an explicit harfbuzz dependency
We are using Harfbuzz api in the file chooser,
so lets make this official.
2022-05-15 10:37:24 -04:00
Benjamin Otte
61bb9bb935 listitemmanager: Clarify warning
Lars doesn't have an opinion on this problem anymore.

And when people see this warning, they should know what to do.
2022-05-14 16:53:44 +02:00
Matthias Clasen
8bd77441a9 Cosmetic fixes to objcopy hack
Preserve the elf section name that we would get
without the objcopy hack. Minimizing the differences
2022-05-14 07:53:47 -04:00
Luca Bacci
e1159dab93 GtkFileChooserWidget: Propagate keys from external entry to fcwidget at the BUBBLE phase
Now that we use event controllers we can forward keybindings from the
external entry to the filechooserwidget at the bubble phase.

Fixes #4905

References:
 * commit 1fb075dbca
 * commit 686116ba61
2022-05-13 14:19:14 +02:00
Matthias Clasen
122fa679a8 Merge branch 'wip/sophie-h/remove-param-nicks-blurbs' into 'main'
gtk: Remove all nicks and blurbs from param specs

Closes #4904

See merge request GNOME/gtk!4717
2022-05-12 02:18:02 +00:00
Matthias Clasen
7302407880 Merge branch 'wip/exalm/color-scales' into 'main'
Redesign GtkColorScale

See merge request GNOME/gtk!4720
2022-05-12 02:01:03 +00:00
Alexander Mikhaylenko
0f7d93492d theme: Redesign color scales
See https://gitlab.gnome.org/GNOME/libadwaita/-/issues/469

Since this style needs changes in color scales themselves, it makes sense
to have it in GTK as well.
2022-05-12 02:22:52 +04:00
Alexander Mikhaylenko
aee4475c0f range: Support border-radius for GtkColorScale troughs
With how this hack is organized, it's simpler to add more code here than
to pass it to GtkColorScale itself.
2022-05-12 02:21:51 +04:00
Alexander Mikhaylenko
1f61cb2251 coloreditor: Stop adding marks style to color scales 2022-05-12 02:21:34 +04:00
Christian Hergert
0382e3b46c actionmuxer: check for observer before unregistering
This can happen if the group can be resolved even when doing the initial
registration of an action as observer will not yet be in the GSList of
watchers (and therefore has no weak references).

Fixes a warning like the following:

 g_object_weak_unref: couldn't find weak ref
2022-05-11 14:43:31 -07:00
Christian Hergert
547b2891cb actionmuxer: set handler ids initially to zero
These were getting created with possible non-zero values and then inserted
into a hashtable where the readers may not know the state of the group.

Ensure those values are set to zero until we assign them below.
2022-05-11 14:43:24 -07:00
Sophie Herold
89614f5f72 inspector: Stop using blurb as tooltip
Does not make sense any longer if we don't set blurbs.
2022-05-11 18:16:44 +02:00
Sophie Herold
a546ae32d7 Remove all nicks and blurbs from param specs
Those property features don't seem to be in use anywhere.
They are redundant since the docs cover the same information
and more. They also created unnecessary translation work.

Closes #4904
2022-05-11 18:16:29 +02:00
Sonny Piers
5a0d6e3fc8 dropdown: Add UI definition example 2022-05-08 22:52:05 +02:00
Matthias Clasen
a6c3e440f6 printdialog: Handle nonexisting files better
When a non-existing file is selected in the file chooser
for print-to-file, we weren't updating the button label
to show the new filename. Fix that.

Also, use newer file chooser api.
2022-05-07 20:31:46 -04:00
Matthias Clasen
fadeda61e5 listitemwidget: Avoid more paramspec lookups
We can use the same helper function in all
places where we notify all three listitem
properties.
2022-05-06 22:28:14 -04:00
Matthias Clasen
3307b8ce88 listitemwidget: Avoid some unnecessary work
Only update widget and accessible state if the
selected property actually changed.
2022-05-06 21:36:22 -04:00
Benjamin Otte
bd9c491076 Merge branch 'list-item-factory-notify-by-pspec' into 'main'
list-item: Use notify_by_pspec instead of by name

See merge request GNOME/gtk!4697
2022-05-06 16:11:21 +00:00
Matthias Clasen
93d62acdf3 Merge branch 'builder-treestore-data' into 'main'
Add buildable data support to GtkTreeStore

See merge request GNOME/gtk!4695
2022-05-06 15:22:41 +00:00
Ivan Molodetskikh
8328bd9f96 list-item: Use notify_by_pspec instead of by name
This is a hot path when scrolling a ColumnView, and
g_param_spec_pool_lookup () was taking a measurable part in this hot
path. Instead, notify using pspecs to avoid the name lookup.

Related: https://gitlab.gnome.org/GNOME/gtk/-/issues/3334
2022-05-06 18:05:03 +03:00
Ivan Molodetskikh
d65e7c9d05 listitemfactory: Track notify manually instead of freeze/thaw
freeze/thaw_notify () showed up on the perf trace for rapid ColumnView
scrolling. Track the three properties manually to make it a little
faster.

Related: https://gitlab.gnome.org/GNOME/gtk/-/issues/3334
2022-05-06 17:31:24 +03:00
Matthias Clasen
08154c41f9 treestore: support nested data in builder
This allows <row> elements to be nested.
Note that the child rows must come after
the data for the row itself.
2022-05-06 09:29:44 -04:00
Matthias Clasen
f880d24f2a builder: Allow checking for multiple parents 2022-05-06 09:29:44 -04:00
Matthias Clasen
c2e8604805 treestore: Copy liststore buildable implementation
This add support for data, but does not allow
nesting yet.
2022-05-06 09:29:44 -04:00
Matthias Clasen
1a488722fa treestore: Cosmetics
Some renaming in the buildable code to make it more
similar to the liststore implementation.
2022-05-06 09:29:44 -04:00
Benjamin Otte
c29bf115f2 Don't invalidate parent if it didn't change
This looks like a leftover excess invalidation from when the surrounding
code was refactored to not just be called on parent changes but also
when repositioning inside the same parent in commit
507016cafc

Ivan Molodetskikh found this problem in
https://gitlab.gnome.org/GNOME/gtk/-/issues/3334#note_1445873 which
contains a longer analysis of this problem and the performance
reductions it causes.

Related: #3334
2022-05-06 11:50:55 +00:00
Matthias Clasen
25069cf233 editablelabel: Make :editing writable
This does not hurt, and lets us start editing from
a ui file, which is useful for documentation screenshots.
2022-05-05 17:33:24 -04:00
Matthias Clasen
19fa7d513d theme: Fix editable label selection
When the editable label is in editing mode,
selections should appear the same as in other
entries.
2022-05-05 12:44:40 -04:00
Matthias Clasen
a0374334d4 Merge branch 'matthiasc/for-main' into 'main'
docs: Fix a spinbutton example

See merge request GNOME/gtk!4686
2022-05-04 12:28:32 +00:00
Matthias Clasen
3bae7f540e docs: Fix a spinbutton example
We need to use editable api for editable functionality.
2022-05-04 07:42:45 -04:00
Benjamin Otte
23fc3d9ecd Merge branch 'checkbutton-label' into 'main'
Expose GtkCheckButton label child for manipulation

Closes #4698

See merge request GNOME/gtk!4489
2022-05-03 22:05:47 +00:00
Matthias Clasen
c645da00dc Merge branch 'wrap-mode-invalid-cast' into 'main'
Don't cast GtkWrapMode to the incompatible enum PangoWrapMode

Closes #4869

See merge request GNOME/gtk!4671
2022-05-03 17:46:51 +00:00
Matthias Clasen
4867ac653a Merge branch 'wip/exalm/eye-icons' into 'main'
icons: Use the proper eye icons

See merge request GNOME/gtk!4663
2022-05-03 17:37:54 +00:00
Matthias Clasen
b0ccfce1d6 Merge branch 'wip/carlosg/ignore-null-preedit' into 'main'
imcontextwayland: Ignore preedit updates from NULL to NULL

See merge request GNOME/gtk!4667
2022-05-03 17:37:36 +00:00
Matthias Clasen
3f6b5ccf4a Merge branch 'ebassi/issue-4883' into 'main'
Keep FileChooserNative alive while a portal is running

Closes #4883

See merge request GNOME/gtk!4675
2022-05-03 16:37:27 +00:00
Pablo Correa Gómez
07299dd9c7 Expose GtkCheckButton label as a child for manipulation
This allows consumers greater control over the label without the need
to expose each of the label properties as part of GtkCheckButton interface.
Specifically, motivation for this commit is to be able to wrap the label.

Closes #4698
2022-05-03 16:25:55 +02:00
Luca Bacci
981981dc46 Merge branch 'fix-list-model-checks-null-vs-empty' into 'main'
GtkFileChooserWidget: fixes for NULL vs empty GListModel

Closes #4851 and #4858

See merge request GNOME/gtk!4678
2022-05-02 18:53:27 +00:00
Matthias Clasen
2b183a9f4e Reject compose tables that are too large
The fixed-size format we use currently can only handle up
to 32768 bytes of string data. If a compose file contains
more, reject it with a warning.

Fixes: #4873
2022-05-02 16:03:45 +08:00
Matthias Clasen
5df314fa8f composetable: Add a missing NULL check
gtk_compose_table_parse can return NULL. Handle it.
2022-05-02 15:39:03 +08:00
Luca Bacci
5a1396d38e GtkFileChooserWidget: return empty GListModel in get_files () instead of NULL 2022-05-01 16:52:13 +02:00
Luca Bacci
6ce36e6a7d GtkFileChooserWidget: check for empty instead of NULL GListModel
While porting GtkFileChooserWidget from GList to GListModel we did not
change some checks for NULL to checks for empty list.

Fixes #4851, #4858
2022-05-01 16:52:13 +02:00