Matthias Clasen
3090fbac82
4.4.1
2021-11-01 09:20:12 -04:00
Matthias Clasen
56e61fc645
NEWS: Updates
2021-10-31 18:23:10 -04:00
Maxim Zakharov
f41d98d104
gtk: Hold reference on controller until events are fully handled
...
Fixes premature controller unreferencing in
gtk_event_controller_handle_event() if the controller itself is being
removed while handling the event.
2021-10-31 17:52:05 -04:00
Alexander Mikhaylenko
b1943e03e6
levelbar: Fill the whole space for discrete level bars
...
Ideally this would be using box layout, but it overrides measure() so it's
not possible - so reimplement it instead. Fix an accidentally int division
along the way.
2021-10-31 17:52:05 -04:00
Christian Hergert
63583c15db
macos: fix scale on macOS 12 beta
...
This is a port of the fix in the quartz backend to the new macOS backend.
From the original commit:
In macOS-12.sdk CGContextConverSizeToDeviceSpace returns a negative
height and passing that to CGContextScaleCTM in turn causes the cairo
surface to draw outside the window where it can't be seen. Passing the
absolute values of the scale factors fixes the display on macOS 12 without
affecting earlier macOS versions.
2021-10-31 17:52:05 -04:00
Chun-wei Fan
0028267228
tools/generate-uac-manifest.py: Fix UAC manifest .rc
...
The resource compiler in the Windows 11 SDK does not allow one to include
winuser.h directly in resource scripts (.rc) with a rather cryptic error
message, so fix generating the .rc file to embed the UAC manifest by including
windows.h with WIN32_LEAN_AND_MEAN instead.
2021-10-31 17:52:05 -04:00
Chun-wei Fan
9cdc332e8a
gtk: Fix version resource on for Windows 11 SDK
...
The rc.exe that comes with the Windows 11 SDK does not allow one to include
winuser.h directly in the .rc scripts, so make sure that it is not included
by gtk-win32.rc.body.in, but instead include windows.h with WIN32_LEAN_AND_MEAN
defined.
2021-10-31 17:52:05 -04:00
Niels De Graef
c0fc8f796b
calendar: Add an explanatory comment
...
On the magic numbers used to get the abbreviated day names.
2021-10-31 17:52:04 -04:00
Niels De Graef
5a2f94b7ef
calendar: Fix abbreviated day names
...
... if the current locale has a different starting day than Sunday.
This needed 2 fixes:
* We need to take into account `calendar->week_start` when
creating/adding the appropriate `day_name_labels` field
* we were only calculating `calendar->week_start` _after_ attaching the
`day_name_labels`, so it was still set to 0 (the default value).
Fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/4338
2021-10-31 17:52:04 -04:00
Bastien Nocera
59dd0dccbf
broadway: Quiet initialisation failures
...
Broadway is the only GTK+ backend that throws an error on stderr for a
"display server" connection failure.
This causes problems when gtk_init_check() is used and unexpected error
output is generated such as with hotdoc, which fails when generating a
GTK plugin's documentation instead of overlooking the issue.
"Unable to init server: Could not connect: Connection refused"
2021-10-31 17:52:04 -04:00
Bastien Nocera
78d5f16bf7
broadway: Quiet initialisation failures
...
Broadway is the only GTK+ backend that throws an error on stderr when
failing to initialise, which causes problems when gtk_init_check() is
used and unexpected error output is generated.
This causes hotdoc to fail when generating a GTK plugin's documentation
instead of failing quietly.
"Unable to init server: Could not connect: Connection refused"
2021-10-31 17:52:04 -04:00
David Edmundson
faba065161
wayland: Mark opaque_region as dirty on hide
...
Otherwise if we hide and show a window we recreate a new surface,
breaking the compositor's association, but potentially not resend this
data for the new surface.
This matches what we do for input_region.
2021-10-31 17:52:04 -04:00
Matthias Clasen
19adb3b8b3
filechooserportal: Take a ref on transient-for
...
This may fix a crash that has been reported in
file_chooser_portal_data_free.
Fixes : #4314
2021-10-31 17:52:04 -04:00
Matthias Clasen
4c9c180e27
inspector: Export gtk_inspector_init
...
Quietly export this function mainly for the benefit
of libadwaita, which can can use this to install its
implementation of the gtk-inspector-page extension
point.
2021-10-31 17:52:04 -04:00
Pierre Ossman
41a662ad2a
searchenginemodel: finalize search results
...
It is necessary to signal the search engine that we are finished and
that we found something for it to reliably show the results. It would
sometimes work anyway since it is sufficient if any backend signals
completion. However if GtkSearchEngineModel was the only backend
returning results then things would break.
2021-10-31 17:52:04 -04:00
Matthias Clasen
c12d398fa2
contentdeserializer: Plug a small memleak
...
Found by asan in ci. We intern the mimetypes
when they are registered, so there is no need
to leak this string.
2021-10-31 17:52:04 -04:00
Matthias Clasen
ca4bf8b0d1
a11y: Simplify atspi context a bit
...
We don't really need a bus-address property
that gets copied for every single object.
We keep the address in object data on the
display anyway. Just use it from there.
This gets rid of a nice amount of strdups
at startup.
2021-10-31 17:52:04 -04:00
Matthias Clasen
16c3864e4a
docs: Mention popovers in the migration guide
...
Things have changed around popovers, we should mention
that.
2021-10-31 17:52:04 -04:00
Matthias Clasen
1fa97e1808
entry: Clarify docs
...
Mention that max length is in characters.
2021-10-31 17:52:04 -04:00
Matthias Clasen
a107ebdc0d
coloreditor: Don't unref unless we own it
...
Calling gtk_widget_class_bind_template_child does
*not* give you a reference that you need to unref.
It manages the reference for you. So calling
g_clear_object on such a member is wrong.
2021-10-31 17:52:04 -04:00
Matthias Clasen
161259e9ea
builder: Don't leak refs
...
We sometimes end up setting an object on a GValue
that we are then not interested in. We need to
unset it, or we'll leak the ref.
2021-10-31 17:52:04 -04:00
Jordan Yelloz
cc5a7b153d
gtktextview: Fixed arrow key crash.
...
When pressing the keyboard arrows to move around when the insertion point is
hidden, it causes an assertion error in blink_cb.
Insertion point blinks should only be scheduled when blinking is enabled and the
insertion point is visible.
Closes #4275
2021-10-31 17:52:04 -04:00
Martin Kühl
0476b5a34c
gtkcomposetable: Accept long replacement strings
...
This change removes the assertions limiting replacement strings in the compose table to be less than 20 characters.
The limit seems arbitrary, is not required, will break some users' setups, and problems with it result in applications not launching.
Fixes #4273
2021-10-31 17:52:04 -04:00
Lukáš Tyrychtr
4b25b43f83
Mention that after setting a button child the user is responsible for a11y relations
2021-10-31 17:52:04 -04:00
Matthias Clasen
0d94a4fcc8
resources: Treat svgs as xml
...
They can have their whitespace removed just the same.
2021-10-31 17:52:04 -04:00
Matthias Clasen
bcf062a578
Clean up gesture icons
...
These had duplicate drawing in them, and were
saved with all the extra Inkscape data.
2021-10-31 17:52:04 -04:00
Timm Bäder
252ce5a5c7
stackswitcher: Expand child buttons
...
Fixes #4196
2021-10-31 17:52:04 -04:00
Georges Basile Stavracas Neto
ac7bdabe95
filechooserwidget: Return an id in get_choice()
...
gtk_file_chooser_widget_get_choice() is supposed to return the option
id of the choice, but it currently is returning the option label.
Return the option id instead.
2021-10-31 17:52:04 -04:00
Georges Basile Stavracas Neto
d94ebd469e
filechooserwidget: Match choice id from "options"
...
When choices are added to the file chooser widget, the options of
that choice are stored object data under the "options" key. However,
gtk_file_chooser_widget_set_choice() was checking for "choices".
Retrieve the options from the "options" key stored data object data.
2021-10-31 17:52:04 -04:00
Matthias Clasen
de17c618fc
gsk: Add a test for transform_bounds
2021-10-31 17:52:04 -04:00
James Westman
1133bff614
gtkcolorbutton: Fix documentation
2021-10-31 17:52:04 -04:00
Benjamin Otte
aa07cb4f64
testsuite: remove box-order test
...
The test used to test that GtkBox ordered it's children left-to-right in
CSS, no matter the text direction or pack-type.
But there is neither a pack-type anymore nor does GTK4 do that.
So that test has been broken for yers, it just didn't render anything
wrong.
2021-10-31 17:52:04 -04:00
muradm
f99b35162c
Do not require wayland-protocols as dependency in the .pc file
...
Basically, I was building some packages on Guix. I figured out that
wayland-protocols was listed among propagated-inputs for gtk+ package
(gtk-3-24). propagated-inputs holds a list of runtime dependencies,
that should be available to any other package that depends on gtk+.
While discussing we clarified that wayland-protocols is not runtime
dependency. So I moved it to native-inputs of gtk+ package, which
means that, this dependency will be available only to gtk+ package and
only at build time. Once moved, building of other applications that
depening on gtk+ started to fail.
Investigation showed that, all .pc (pkg-config) files prepared by gtk+
package, was including:
Requires.private: ... wayland-protocols ...
Since it becomes requirement, other applications was failing with
missing dependency wayland-protocols of dependency gtk+, for instance:
-- Checking for module 'gtk+-3.0'
-- Package 'wayland-protocols', required by 'gdk-3.0', not found
While actually wayland-protocols is not even a build time dependency
of application that depends on gtk+. Advertisement of such
requirement, is a bit misleading, because one does not need it at
runtime, especially applications based on gtk.
2021-10-31 17:52:04 -04:00
Jakub Steiner
3ae2ebac67
theme: make toggled tbuttons in toolbars visible
...
- do what Alex does in libadwaita
Fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/4264
2021-10-31 17:52:04 -04:00
Matthias Clasen
4cf9f6382f
Update the README
...
Remove the mention of GNU (since that has not been case
for a long time, effectively), state that GTK is hosted
by the GNOME project, and point to GNOME as a place
for donations.
2021-10-31 17:52:04 -04:00
Matthias Clasen
9ffb3e5ece
testsuite: Call g_test_init in test binaries
...
Without it, we mess out on G_DEBUG=fatal-warnings,
so our ci does not alert us that we run a bunch of
tests which spit out warnings.
2021-10-31 17:52:04 -04:00
Lukáš Tyrychtr
72ffe46e74
Fix generation of accessible description in presence of described by relations
...
The loop going through the relation list should have stopped on the NULL sentinel value, however it never accesed the next list element.
2021-10-31 17:52:04 -04:00
Matthias Clasen
f7b5c886b3
testsuite: Fix a few memory leaks
...
These are keeping the asan build in ci from passing.
2021-10-31 17:52:04 -04:00
Lukáš Tyrychtr
5b186fab1a
Set correct accessible relations for GtkMenuButton
...
Up until now, as the focus was moved to the inner button, it was not possible for
assistive technologies to determine the correct labels and descriptions
because developers could set them only for the parent widget.
Now, the proper relations are added so the labels should be picked up properly.
Fixes #4254
2021-10-31 17:52:04 -04:00
Alexander Mikhaylenko
d2c610148e
media-controls: Make play button flat
...
Match the volume button.
2021-10-31 17:52:04 -04:00
Alexander Mikhaylenko
66ef08921d
searchbar: Vertically center the close button
2021-10-31 17:52:04 -04:00
Julian Sparber
137a62cb94
stack: Dispose children before emitting items-changed
...
This makes sure that the `GListModel` returned by
`gtk_stack_get_pages()` actually has the items removed before
`items-changed` is emitted.
Fixes: https://gitlab.gnome.org/GNOME/gtk/-/issues/4255
2021-10-31 17:52:04 -04:00
Matthias Clasen
022b396a06
GtkApplication: Call setlocale early
...
If we don't call setlocale early enough,
--help output may come out misformatted.
Fixes : #4234
2021-10-31 17:52:04 -04:00
Matthias Clasen
afb9378405
textview: Invalidate Pango contexts
...
We need to invalidate the Pango contexts when
font settings change. Use the new helper
gtk_widget_update_pango_context to make it less
likely that we forget to update some things.
2021-10-31 17:52:04 -04:00
Matthias Clasen
abe7407abe
widget: Provide a helper for updating pango contexts
2021-10-31 17:52:04 -04:00
Matthias Clasen
1038b94ab1
Rename an internal function
...
It occupies a name I want to reuse for something else.
2021-10-31 17:52:04 -04:00
Emmanuele Bassi
07381e2b14
Improve the gtk_accelerator_parse() docs
...
We need to escape the modifiers in angular brackets, or Markdown will
consider them as HTML tags.
We also should document the modifiers we're parsing.
2021-10-31 17:52:04 -04:00
Matthias Clasen
965ca1b607
widget: Redraw when font options change
...
Its the right thing to do, even if it is a rare event.
2021-10-31 17:52:04 -04:00
Simon McVittie
e67e51be14
reftest-compare: Treat colour channels as undefined if alpha is zero
...
If the alpha channel is zero, it doesn't matter what the values of the
red, green and blue channels are: the pixel is still fully transparent.
On most architectures, fully transparent pixels end up all-zeroes
(fully transparent black), matching what's in the reference PNG file;
but on mips*el the blend-difference and blend-normal tests get all-ones
(fully transparent white) and a test failure.
Resolves: https://gitlab.gnome.org/GNOME/gtk/-/issues/4227
Signed-off-by: Simon McVittie <smcv@debian.org >
2021-10-31 17:52:04 -04:00
Christoph Reiter
eab7c19dfb
build: fix implicit-fallthrough errors with clang
...
The clang build fails due to -Werror=implicit-fallthrough being
on by default and some fallthrough cases not being marked as such.
Use G_GNUC_FALLTHROUGH or duplicate the code in those cases.
2021-10-31 17:52:04 -04:00
Rafał Dzięgiel
66804b9b49
Fix wrong gettext ITS target
...
The installed ITS rule filename is "gtk4builder.its". The .loc file
is wrongly pointing to old "gtkbuilder.its" which makes gettext fail
on systems without GTK3 installed.
2021-10-31 17:52:04 -04:00
Emmanuele Bassi
b48e158ef8
Release an extra reference on GtkExpander:child
...
The child of a GtkExpander is owned directly by the expander whenever
the "expanded" flag is unset.
We are adding an additional reference to the child of an expander when
expander is not expanded.
Additionally, if a GtkExpander is disposed while not expanded, we need
to explicitly release the reference on the child widget that we own.
This reference leak was masked in GTK3 by GtkContainer removing each
child from the parent container by recursively calling
gtk_widget_destroy().
2021-10-31 17:52:04 -04:00
Qiu Wenbo
4e42006d41
docs: Fix documentation for gtk_icon_view_create_drag_icon
...
Fixes : #4190
2021-10-31 17:52:04 -04:00
Kalev Lember
946914a2d0
build: Fix detection for pre-compiled css files
...
The default theme changed from Adwaita to Default and this tripped up
the logic to detect if the tarball builds contain pre-built css files or
not. Fix this by looking at pre-compiled css files in themes/Default/
instead of themes/Adwaita/.
2021-10-31 17:52:04 -04:00
Benjamin Otte
9c1bce629d
docs: Expand gdk_clipboard_set() docs
2021-10-31 17:52:04 -04:00
Rūdolfs Mazurs
d67982d5e0
Update Latvian translation
2021-10-31 14:59:22 +00:00
Jordi Mas i Hernandez
ca02700a63
Update Catalan translation
2021-10-29 11:45:56 +00:00
Alexey Rubtsov
65b955fe26
Update Russian translation
2021-10-29 11:06:26 +00:00
Benjamin Otte
4a884ed706
Merge branch 'cherry-pick-ac8c4245' into 'gtk-4-4'
...
css: Don't throw warnings on broken URL in image css
See merge request GNOME/gtk!4098
2021-10-27 01:02:45 +00:00
Benjamin Otte
36cb2e932c
css: Don't throw warnings on broken URL in image css
...
If a URL can't be loaded, we might end up with a NULL file. Handle that
case properly by creating an invalid image instead and don't crash or
complain to stderr when files are NULL.
This was broken since 0886ade182
A new reftest has been included. We need a reftest instead of a
CSS parser test, because the error only becomes visible when
compute()ing the actual image.
Fixes #4373
(cherry picked from commit ac8c4245b2 )
2021-10-26 23:44:38 +00:00
Rūdolfs Mazurs
4f5264d1b7
Update Latvian translation
2021-10-25 16:59:50 +00:00
Benjamin Otte
ff2345a8f8
Merge branch 'cherry-pick-3c9c7a0e' into 'gtk-4-4'
...
build: Make sure ifuncs exist when using fp16
See merge request GNOME/gtk!4089
2021-10-22 18:17:42 +00:00
Benjamin Otte
2a4b90a81c
build: Make sure ifuncs exist when using fp16
...
Fixes msys compiles on Windows (and everywhere else hopefully).
Fixes #4285
(cherry picked from commit 3c9c7a0e72 )
2021-10-22 16:32:55 +00:00
Goran Vidović
6aa6ab85f6
Update Croatian translation
2021-10-21 10:51:24 +00:00
Matthias Clasen
c293a243d9
Merge branch 'gtk-4-4nodate' into 'gtk-4-4'
...
Drop date attribute from our appdata files
See merge request GNOME/gtk!4077
2021-10-19 11:36:44 +00:00
Bernhard M. Wiedemann
6681bbf8d2
Drop date attribute from our appdata files
...
in order to make builds reproducible.
See https://reproducible-builds.org/ for why this is good
This was suggested by Matthias Clasen as an alternative to MR !3929
2021-10-19 09:38:36 +02:00
Benjamin Otte
5b2aa196e0
Merge branch 'backport-mr-3930-to-gtk-4-4' into 'gtk-4-4'
...
Fix DND coordinates on Windows
See merge request GNOME/gtk!4049
2021-10-16 17:04:55 +00:00
Sveinn í Felli
83b3c7d826
Update Icelandic translation
2021-10-12 22:48:01 +00:00
Rafael Fontenelle
4b9260608a
Update Brazilian Portuguese translation
2021-10-12 17:33:41 +00:00
Benjamin Otte
7f0d7aff0b
Merge branch 'cherry-pick-d89e82d4' into 'gtk-4-4'
...
Merge branch 'wip/otte/for-master' into 'gtk-4-4'
See merge request GNOME/gtk!4055
2021-10-11 19:47:37 +00:00
Benjamin Otte
3c90385716
Merge branch 'wip/otte/for-master' into 'master'
...
x11: Don't try to move destroyed windows
See merge request GNOME/gtk!4054
(cherry picked from commit d89e82d4a0 )
f40ce51a x11: Don't try to move destroyed windows
2021-10-11 18:37:15 +00:00
Asier Sarasua Garmendia
2492729238
Update Basque translation
2021-10-08 17:44:18 +00:00
Luca Bacci
b7988d869d
Fix DND coordinates on Windows
2021-10-08 14:24:29 +02:00
Luca Bacci
d79b52ce55
Make the DND indicator not interfere with the drag and drop operation
2021-10-08 14:24:04 +02:00
Dušan Kazik
14f31183b8
Update Slovak translation
2021-10-04 13:20:03 +00:00
Asier Sarasua Garmendia
5959dcc112
Update Basque translation
2021-10-03 07:12:30 +00:00
Daniel Șerbănescu
dc77823787
Update Romanian translation
2021-09-30 12:40:26 +00:00
Sveinn í Felli
4e08ec0ea1
Update Icelandic translation
2021-09-29 12:04:41 +00:00
Kukuh Syafaat
cc70eaca93
Update Indonesian translation
2021-09-29 05:57:08 +00:00
Matthias Clasen
fbf09f6e31
Merge branch 'cherry-pick-d61c71c3' into 'gtk-4-4'
...
macos: Actually set the vfuncs
See merge request GNOME/gtk!4007
2021-09-29 00:36:34 +00:00
Benjamin Otte
c0c18459f5
macos: Actually set the vfuncs
...
(cherry picked from commit d61c71c378 )
2021-09-29 00:05:14 +00:00
Yaron Shahrabani
e230579149
Update Hebrew translation
2021-09-28 20:27:52 +00:00
Daniel Mustieles
2155486ffd
Updated Spanish translation
2021-09-28 12:31:04 +02:00
Hugo Carvalho
73861c1178
Update Portuguese translation
2021-09-26 19:58:52 +00:00
Goran Vidović
db82ff6ae2
Update Croatian translation
2021-09-26 16:40:30 +00:00
Goran Vidović
6fd90929b4
Update Croatian translation
2021-09-26 16:38:22 +00:00
Piotr Drąg
a48e978b39
Update Polish translation
2021-09-26 17:22:36 +02:00
Aurimas Černius
7b967e1f4a
Updated Lithuanian translation
2021-09-26 17:22:50 +03:00
Emin Tufan Çetin
b245e8c9ef
Update Turkish translation
2021-09-26 12:21:46 +00:00
Matej Urbančič
77572104a6
Update Slovenian translation
2021-09-26 11:03:51 +00:00
Мирослав Николић
1a70c49acd
Update Serbian translation
2021-09-26 05:51:31 +00:00
Мирослав Николић
ea63309512
Update Serbian translation
2021-09-26 05:33:02 +00:00
Rafael Fontenelle
df0f886e77
Update Brazilian Portuguese translation
2021-09-25 13:57:40 +00:00
Danial Behzadi
9b7147e085
Update Persian translation
2021-09-25 10:21:18 +00:00
Charles Monzat
75e35cf646
Update French translation
2021-09-25 07:04:51 +00:00
Christian Hergert
c08ba636d4
textview: improve undo grouping when overwriting
...
We want to group in more than one undo group when removing a selection
and replacing it with a new character or characters, unless we're
replacing a single character. In that case, the natural thing is to treat
it as an atomic change.
2021-09-24 16:37:59 -07:00
Christian Hergert
f8cd883e0d
texthistory: add barriers after final grouping
...
We don't want to allow new items to be grouped into a previous action
group after the end_user_action() is called. This ensures that we add a
barrier action in those conditions.
Fixes #4276
2021-09-24 16:37:59 -07:00
Fran Dieguez
d198754ce8
Update Galician translation
2021-09-24 22:37:55 +00:00
Yuri Chornoivan
3a0d4d3d13
Update Ukrainian translation
2021-09-24 17:06:11 +00:00
Anders Jonsson
9f393f8a33
Update Swedish translation
2021-09-24 14:40:07 +00:00
Marek Černocký
8b5b02454e
Updated Czech translation
2021-09-24 15:23:33 +02:00
Benjamin Otte
6d1233d3a6
Merge branch 'wip/otte/for-4-4' into 'gtk-4-4'
...
GL: improve intiialization
See merge request GNOME/gtk!3993
2021-09-24 12:22:19 +00:00
Benjamin Otte
21cd0f942e
gdk: Make sure only one GL backend is used
...
Creative people managed to create an X11 display and a Wayland display
at once, thereby getting EGL and GLX involved in a fight to the death
over the ownership of the glFoo() symbolspace.
A way to force such a fight with available tools here is (on Wayland)
running something like:
GTK_INSPECTOR_DISPLAY=:1 GTK_DEBUG=interactive gtk4-demo
Related: xdg-desktop-portal-gnome#5
2021-09-24 13:54:17 +02:00
Benjamin Otte
345b06bbbf
wayland: Better error on eglGetDisplay() failure
...
Goals:
1. Provide as much information as possible in the error message, so
users can try to fix their system themselves.
2. Try to formulate the error message in a way that explains that this
is not something GTK can fix, but a lower layer problem.
Related: #4193
2021-09-24 13:54:12 +02:00
Emin Tufan Çetin
cbd3d5a4aa
Update Turkish translation
2021-09-19 17:15:24 +00:00
Matthias Clasen
7f5cbc2234
Merge branch 'fix-win32-shader-check' into 'gtk-4-4'
...
gdkglcontext-win32-wgl.c: Fix Cairo fallback check
See merge request GNOME/gtk!3964
2021-09-17 11:21:36 +00:00
Chun-wei Fan
b57e70fdaf
gdkdisplay-win32.c: Don't retry WGL initialization
...
On Windows, GLES is not that widely available unless one installs wrapper
libraries such as libANGLE, so GLES/EGL support on Windows is used more like
a fallback mode if Desktop OpenGL (WGL) support is inadequate on the system.
Hence, unless one forces WGL or EGL, we will first try to initialize WGL, and
then try to initialize GLES if enabled and if WGL initialization failed, and
then just return whatever the last result we can obtain from these
initialization attempts, since unlike X11 EGL contexts, we do not have
separate modes for WGL except for legacy and non-legacy contexts.
2021-09-17 17:08:23 +08:00
Chun-wei Fan
75aa1a757b
gdkglcontext-win32-wgl.c: Fix Cairo fallback check
...
We were setting the WGL pixel format in GdkWin32Display too early, so the code
does not bail out correctly when we retry establishing the WGL context.
Fix this by pushing back setting the WGL pixel format only after it passes the
shader availability check.
Should fix issue #4257 .
2021-09-17 11:19:30 +08:00
Boyuan Yang
362208523d
Update Chinese (China) translation
2021-09-15 18:56:14 +00:00
Dz Chen
dc7dc6285d
Update Chinese (China) translation
2021-09-15 15:37:48 +00:00
Daniel Mustieles
f2c92f7e8b
Updated Spanish translation
2021-09-15 08:43:45 +02:00
Daniel Mustieles
301e72cb23
Updated Spanish translation
2021-09-15 08:29:59 +02:00
Alan Mortensen
4cbfd49456
Updated Danish translation of gtk-properties
2021-09-13 20:48:55 +02:00
Alan Mortensen
c3cb16126a
Updated Danish translation
2021-09-13 20:48:52 +02:00
Philipp Kiemle
9cfa472cde
Update German translation
2021-09-12 21:48:01 +00:00
Philipp Kiemle
f4ef0c61a0
Update German translation
2021-09-12 16:27:27 +00:00
Balázs Meskó
fe30ac8e6b
Update Hungarian translation
2021-09-12 05:57:57 +00:00
Balázs Meskó
baa4c12322
Update Hungarian translation
2021-09-11 23:38:52 +00:00
Guillaume Bernard
8ffd7e9f87
Update French translation
2021-09-11 09:41:11 +00:00
Guillaume Bernard
f433c543fe
Update French translation
2021-09-11 09:36:29 +00:00
Goran Vidović
33e00c9087
Update Croatian translation
2021-09-10 15:58:48 +00:00
Goran Vidović
e507ff96ac
Update Croatian translation
2021-09-10 15:56:27 +00:00
Goran Vidović
4b19e5d58d
Update Croatian translation
2021-09-10 15:43:42 +00:00
Emin Tufan Çetin
7a6a1c8f32
Update Turkish translation
2021-09-10 06:29:45 +00:00
Matej Urbančič
1742de2f2d
Update Slovenian translation
2021-09-07 18:25:03 +00:00
Matej Urbančič
9c8b297223
Update Slovenian translation
2021-09-07 18:20:01 +00:00
Danial Behzadi
462115a57e
Update Persian translation
2021-09-06 13:18:07 +00:00
Daniel Șerbănescu
bb72acf9cd
Update Romanian translation
2021-09-05 18:43:29 +00:00
Daniel Șerbănescu
63d829bbc1
Update Romanian translation
2021-09-05 18:34:20 +00:00
Anders Jonsson
19af960163
Update Swedish translation
2021-09-05 14:11:36 +00:00
Asier Sarasua Garmendia
0768addbb3
Update Basque translation
2021-09-04 20:54:26 +00:00
Asier Sarasua Garmendia
edbcd7d36e
Update Basque translation
2021-09-04 20:50:17 +00:00
Changwoo Ryu
8ae31322a0
Update Korean translation
2021-09-04 14:55:06 +00:00
Changwoo Ryu
0a5af76932
Update Korean translation
2021-09-04 08:59:22 +00:00
Anders Jonsson
2dbcad428a
Update Swedish translation
2021-09-03 22:59:22 +00:00
Matthias Clasen
817cfcacce
Merge branch 'backports-for-4-4' into 'gtk-4-4'
...
windowhandle: Quiet a compiler warning
See merge request GNOME/gtk!3915
2021-09-03 00:55:54 +00:00
Matthias Clasen
5053e9917e
Fix build against pango main
...
Handle (and ignore) new Pango attributes.
2021-09-02 19:59:41 -04:00
Xavier Claessens
4f5d959a94
media: Check for gstreamer verion instead of using cc.links()
...
This fix error when gstgl_dep comes from a subproject because in that
case it cannot be used in compiler checks.
2021-09-02 19:59:41 -04:00
Matthias Clasen
8407ebe1d8
editable: Clarify the docs
...
Make it clear that your class must have all the editable properties
already before you call the (confusingly named) function
gtk_editable_install_properties.
2021-09-02 19:59:41 -04:00
Matthias Clasen
d2efdaba59
gdk: Make GDK_DEBUG=default-settings unconditional
...
Our tests use this settings, so we should respect it
in non-debug builds as well.
2021-09-02 19:59:41 -04:00
Simon McVittie
da12386faf
compose: Update sequences from libX11 1.7.2
...
This adds support for sequences like <Compose>,G,u -> capital G with
breve. Previously, only a capital U was accepted for E, G, I and O
(but a lower-case u was accepted for A and U for some reason).
Signed-off-by: Simon McVittie <smcv@debian.org >
2021-09-02 19:59:41 -04:00
Simon McVittie
7f9f097c3d
compose: Document how to get compose-parse input from libX11 source
...
Signed-off-by: Simon McVittie <smcv@debian.org >
2021-09-02 19:59:41 -04:00
Simon McVittie
71f6ba92ee
compose: Generate endian-dependent compact Compose data
...
The GtkComposeTable cache is always in big-endian format and is
byteswapped on load for the more common little-endian CPUs, but
init_builtin_table() in GtkIMContextSimple can't byteswap the built-in
data without copying it, which is undesirable. Pregenerate both big-
and little-endian compose data, and compile the correct flavour into
each build of GTK. This fixes failure of the composetable test when
building for a big-endian architecture such as s390x and (traditional,
big-endian) powerpc.
Resolves: https://gitlab.gnome.org/GNOME/gtk/-/issues/4217
Signed-off-by: Simon McVittie <smcv@debian.org >
2021-09-02 19:59:41 -04:00
Benjamin Otte
11c1b97d5c
stylecontext: Remove unneeded headers
2021-09-02 19:59:41 -04:00
Benjamin Otte
d36b27cc3a
fontbutton: Destroy dialog in unrealize()
...
This way, we can be sure it's always using the right display.
We can also be sure that it doesn't leak.
2021-09-02 19:59:41 -04:00
Benjamin Otte
eec783b922
fontbutton: Make sure the window is on the same display
...
We don't want the font buttons created by the inspector to run on the
default display.
2021-09-02 19:59:41 -04:00
Benjamin Otte
edebd48b24
build: Check that introspection is enabled for docs build
2021-09-02 19:59:41 -04:00
Benjamin Otte
ede1348cd8
docs: Fix vfunc references
...
vfunc references should just use the object name, not the
class/interface/iface name.
2021-09-02 19:59:41 -04:00
Matthias Clasen
951844a0f5
ngl: Avoid a coordinate overflow
...
This was showing up as big text selections going
missing sporadically.
Fixes : #4214
2021-09-02 19:59:41 -04:00
Ian Douglas Scott
ddbafa4d1a
x11: Fix handling of RRScreenChangeNotify/RRNotify events
...
It seems these are sent with `xwindow` set to the root window, so this
was failing to find a surface and get the screen from that.
I'm not sure if there's a reason not to get the screen this way
elsewhere in the function, but it seems this should be correct.
This fixes the behavior of `gdk_x11_display_get_monitors()`, which
wasn't correctly changing when monitors were added or removed. For
instance, this python code was always showing the same number of
monitors when one was turned off and on, but updates correctly with this
change applied:
```python
import gi
gi.require_version("GLib", "2.0")
gi.require_version("Gdk", "4.0")
gi.require_version("Gtk", "4.0")
from gi.repository import GLib, Gdk, Gtk
def f():
print(len(Gdk.Display.get_default().get_monitors()))
return True
GLib.timeout_add_seconds(1, f)
GLib.MainLoop().run()
```
2021-09-02 19:59:41 -04:00
Florian Müllner
d0d982e2ed
window: Prefer menu bars when handling F10
...
Focusing the first widget in the titlebar is a good fallback,
but a "real" menubar or :primary menu button should take
precedence.
2021-09-02 19:59:41 -04:00
Matthias Clasen
6ad047ab79
textview: Apply font features from css
...
We were forgetting to propagate these values from
CSS to the default attributes. Share the code for
getting these values out of a GtkCssStyle.
2021-09-02 19:59:41 -04:00
Matthias Clasen
e7479db2ba
textview: Apply line decoration from css
...
We were forgetting to propagate these values from
CSS to the default attributes.
2021-09-02 19:08:19 -04:00
Matthias Clasen
3799c9d51e
textview: Don't forget to collect css letterspacing
...
There are more properties missing, this is just the start.
Fixes : #4207
2021-09-02 19:08:05 -04:00
Matthias Clasen
4bb230d7d7
windowhandle: Quiet a compiler warning
...
gesture was left uninitialized in the default case.
2021-09-02 18:22:58 -04:00
Jiri Grönroos
33a4ae12ef
Update Finnish translation
2021-09-02 16:06:39 +00:00
Aurimas Černius
0c343d3aad
Updated Lithuanian translation
2021-09-02 13:49:47 +03:00
Danial Behzadi
6697b738ad
Update Persian translation
2021-09-01 09:43:59 +00:00
Daniel Mustieles
e441f75ca6
Updated Spanish translation
2021-09-01 11:02:05 +02:00
Baurzhan Muftakhidinov
581004aa7d
Update Kazakh translation
2021-08-29 17:11:04 +00:00
Baurzhan Muftakhidinov
e1fbcbb93e
Update Kazakh translation
2021-08-29 14:42:01 +00:00
Enrico Nicoletto
cd9735eab1
Update Brazilian Portuguese translation
2021-08-28 01:00:26 +00:00
Enrico Nicoletto
8f5a1471cc
Update Brazilian Portuguese translation
2021-08-28 00:44:25 +00:00
Andika Triwidada
f9efd103a9
Update Indonesian translation
2021-08-26 14:45:38 +00:00
Andika Triwidada
85ad1db8ef
Update Indonesian translation
2021-08-26 14:40:03 +00:00
Hugo Carvalho
6e467de751
Update Portuguese translation
2021-08-26 14:29:50 +00:00
Hugo Carvalho
ae5b6395ad
Update Portuguese translation
2021-08-26 14:12:47 +00:00
Andika Triwidada
dcc899b621
Update Indonesian translation
2021-08-26 13:38:46 +00:00
Marek Černocký
16ad555709
Updated Czech translation
2021-08-26 14:48:55 +02:00
Marek Černocký
f6387a636c
Updated Czech translation
2021-08-26 14:35:37 +02:00
Jordi Mas
9ac48a3b67
Update Catalan translation
2021-08-26 13:10:52 +02:00
Jordi Mas
ba33e80cad
Update Catalan translation
2021-08-26 12:48:56 +02:00
Emmanuele Bassi
6f3535f35f
Merge branch '4195-backport-gtk-4-4' into 'gtk-4-4'
...
gdkmacoseventsource: Include "gdk-private.h" (Backport to gtk-4-4)
See merge request GNOME/gtk!3884
2021-08-25 16:22:28 +00:00
Daniel Mustieles
434ffd16ce
Updated Spanish translation
2021-08-25 17:36:56 +02:00
Daniel Mustieles
58fb124afb
Updated Spanish translation
2021-08-25 17:36:49 +02:00
Peter Bloomfield
50c81dfc91
gdkmacoseventsource: Include "gdk-private.h"
...
_gdk_macos_event_source_new() calls g_source_set_static_name(), which
for GLib versions before 2.69.1 is a macro defined in gdk-private.h.
Fixes #4195
2021-08-25 10:47:24 -04:00
Fran Dieguez
410ea1049b
Update Galician translation
2021-08-25 07:26:42 +00:00
Fran Dieguez
09a5828ccf
Update Galician translation
2021-08-25 06:12:31 +00:00
Yuri Chornoivan
6377b23bd6
Update Ukrainian translation
2021-08-24 17:28:48 +00:00
Matthias Clasen
210a709246
Merge branch 'matthiasc/for-master' into 'master'
...
Handle new pango attribute type
See merge request GNOME/gtk!3866
2021-08-22 15:22:14 +00:00
Matthias Clasen
5feba67a3d
Handle new pango attribute type
...
Update all the places where we switch over
PangoAttrType to handle PANGO_ATTR_TEXT_TRANSFORM,
and do nothing for now - text-transform support
will land in 4.6.
2021-08-22 11:04:28 -04:00
Matthias Clasen
f1f197e3b9
4.4.0
2021-08-20 15:10:25 -04:00
Matthias Clasen
cedb6183e9
Fix imcontext tests
...
We should force our internal im context for these
tests, so we don't depend on the environment.
2021-08-20 15:10:25 -04:00
Matthias Clasen
0415d46c0f
Merge branch 'matthiasc/for-master' into 'master'
...
NEWS: Updates
See merge request GNOME/gtk!3861
2021-08-20 14:21:39 +00:00
Matthias Clasen
68388331c7
NEWS: Updates
2021-08-20 09:54:02 -04:00
Matthias Clasen
92817b0603
Merge branch 'cut-shortcut-activation-short' into 'master'
...
shortcutcontroller: Only do round-robin for mnemonics
Closes #4130
See merge request GNOME/gtk!3824
2021-08-20 13:50:51 +00:00
Matthias Clasen
f8a1726ffa
shortcutcontroller: Only do round-robin for mnemonics
...
Don't do round-robin activation unless we are looking
for mnemonics, where this is an expected feature.
Fixes : #4130
2021-08-20 09:26:37 -04:00
Matthias Clasen
be34f27026
Merge branch 'matthiasc/for-master' into 'master'
...
gdk: Add a missing annotation
Closes #4097
See merge request GNOME/gtk!3860
2021-08-20 13:22:01 +00:00
Emmanuele Bassi
12c5518e2b
Merge branch 'master' into 'master'
...
a11y: Send correct object reference for the root accessible
See merge request GNOME/gtk!3800
2021-08-20 13:18:37 +00:00
Matthias Clasen
d8ab5c3c45
gdk: Add a missing annotation
...
Mark an array as zero-terminated.
Fixes : #4097
2021-08-20 08:57:27 -04:00
Matthias Clasen
36d1c9e8b7
Merge branch 'add-support-for-windows-pointer-input-stack-gtk4' into 'master'
...
Add support for Windows Pointer Input Stack
Closes #262 , #3162 , #729 , and #537
See merge request GNOME/gtk!3684
2021-08-20 11:31:16 +00:00
Matthias Clasen
45c047f5c0
Merge branch 'block-cursor-fixes' into 'master'
...
textview: Don't eat block cursors
See merge request GNOME/gtk!3857
2021-08-20 06:18:07 +00:00
Matthias Clasen
da1232caaf
textview: Don't eat block cursors
...
We need to render even an empty paragraph when
it has a block cursor at the end. This fixes block
cursors not showing up in empty lines.
2021-08-20 01:57:31 -04:00
Matthias Clasen
fff5a83957
Merge branch 'matthiasc/for-master' into 'master'
...
window: Make resizeability changes work
See merge request GNOME/gtk!3856
2021-08-19 21:19:40 +00:00
Matthias Clasen
f5b6488eb2
window: Make resizeability changes work
...
We were forgetting to update the toplevel
properties here.
2021-08-19 16:03:58 -04:00
Luca Bacci
c02bae9e08
Move the _gdk_win32_pointer_input_api global variable into GdkWin32Display
2021-08-19 16:29:45 +02:00
Matthias Clasen
58e65ae7dd
windows: Update the docs for env vars
...
We've replaced some env vars with a new one.
Update the docs to match.
2021-08-19 15:57:44 +02:00
Luca Bacci
3977518f00
Fix typo
2021-08-19 15:57:44 +02:00
Luca Bacci
8adee3dace
Disable visual feedback for pen ad touch
2021-08-19 15:57:43 +02:00
Luca Bacci
09ad930da4
Filter out spurious mouse messages while handling pen or touch input
2021-08-19 15:57:43 +02:00
Luca Bacci
52f7bb6950
Add _gdk_win32_get_cursor_pos utility
2021-08-19 15:57:42 +02:00
Luca Bacci
68db945e47
Handle WinPointer input
2021-08-19 15:57:41 +02:00
Luca Bacci
b54f4cf5d4
Initialize WinPointer and enumerate devices
2021-08-19 15:57:41 +02:00
Luca Bacci
9a8a9451b1
Add new GdkDeviceWinpointer type
2021-08-19 15:57:40 +02:00
Luca Bacci
fffa903ce9
Add winpointer.h header file for type declarations
2021-08-19 15:57:39 +02:00
Luca Bacci
ab08885a32
Add entry for WinPointer in GdkWin32TabletInputAPI enum
2021-08-19 15:57:38 +02:00
Luca Bacci
ad3995b1b9
Make room for other API's than Wintab
2021-08-19 15:57:38 +02:00
Luca Bacci
75cc0710ac
Remove _gdk_input_ignore_wintab variable
...
Also remove unused variable _gdk_max_colors
2021-08-19 15:57:37 +02:00
Luca Bacci
7cec7054e2
Rename some Wintab-related functions
2021-08-19 15:57:36 +02:00
Luca Bacci
fe280e578f
Set active physical device when using the mouse
2021-08-19 15:57:36 +02:00
Luca Bacci
a32973f56b
Move use of _gdk_win32_get_next_tick from synthesize_crossing_events to its callers
2021-08-19 15:57:35 +02:00
Luca Bacci
7762311911
Add a physical_device argument to send_crossing_event et al
2021-08-19 15:57:34 +02:00
Luca Bacci
edd73ffbed
Raise _WIN32_WINNT macro to target Windows 7 API
2021-08-19 15:57:33 +02:00
Matthias Clasen
fca87d93e9
Updates
2021-08-19 01:47:43 -04:00
Matthias Clasen
c2fe2c0385
Merge branch 'better-word-selection' into 'master'
...
textview: Improve word selection
Closes #4177
See merge request GNOME/gtk!3855
2021-08-19 04:51:11 +00:00
Matthias Clasen
8aa25046dc
textview: Improve word selection
...
Avoid selecting a whole extra paragraph when a select-by-words
selection is extended beyond the end of the previous paragraph.
Fixes : #4177
2021-08-19 00:33:03 -04:00
Matthias Clasen
27a07ed89c
Merge branch 'matthiasc/for-master' into 'master'
...
Cosmetics
See merge request GNOME/gtk!3854
2021-08-19 02:49:23 +00:00
Matthias Clasen
071a6bcc06
Cosmetics
2021-08-18 22:33:23 -04:00
Benjamin Otte
f98ac6590d
Merge branch 'wip/otte/for-master' into 'master'
...
demo: Add a dnd special-case for textures
See merge request GNOME/gtk!3853
2021-08-19 01:42:26 +00:00
Benjamin Otte
6b733d2943
gtk-demo: Make clipboard demo paste from clipboard
...
The old code was just pasting local clipboard data that we put there
ourselves and was causing criticals on remote clipboard data. Now the
code does the proper async paste.
2021-08-19 03:16:48 +02:00
Benjamin Otte
6f165efcdb
contentprovider: Switch wrong order in type check
...
We can provide textures as a paintable - we can't provide paintables as
textures.
2021-08-19 03:16:48 +02:00
Benjamin Otte
7bc1c9a562
demo: Add a dnd special-case for textures
...
If the DND/clipboard machinery knows a texture is a texture, it will try
to serialize it. Paintables can't be serialized, so it wouldn't try.
2021-08-19 03:16:48 +02:00
Matthias Clasen
1596fdeba3
Merge branch 'matthiasc/for-master' into 'master'
...
infobar: Update buildable docs
Closes #4164
See merge request GNOME/gtk!3852
2021-08-18 22:05:07 +00:00
Matthias Clasen
1599b659cf
infobar: Update buildable docs
...
Document the current state of GtkBuilder support in
GtkInfoBar, not what we had in GTK3.
Fixes : #4164
2021-08-18 17:42:54 -04:00
Matthias Clasen
bb65564c7d
Merge branch 'seat-v7' into 'master'
...
gdk/wayland: add support for wl_seat version 7
See merge request GNOME/gtk!3842
2021-08-18 21:10:30 +00:00
Matthias Clasen
03031b3dc1
Merge branch 'fix/wm_class2' into 'master'
...
x11: ensure WM class is not null even if display is initialized early
See merge request GNOME/gtk!3808
2021-08-18 18:24:37 +00:00
Benjamin Otte
b7636ebbc0
Merge branch 'win32-drop-local-dnd' into 'master'
...
gdk/win32: Drop local DnD protocol
See merge request GNOME/gtk!3830
2021-08-18 14:27:14 +00:00
Matthias Clasen
5707b80a69
Merge branch 'win32-check-shader-support' into 'master'
...
GDK-Win32: Reject GL context if shaders aren't supported (fix issue #4165 )
Closes #4165
See merge request GNOME/gtk!3850
2021-08-18 12:19:57 +00:00
Matthias Clasen
81e5d4c327
Merge branch 'master' into 'master'
...
gtkbuilderparser: Fix duplicate object id detection
See merge request GNOME/gtk!3848
2021-08-18 12:00:41 +00:00
Ye Moran
f8111125ef
gtkbuilderparser: Fix duplicate object id detection
2021-08-18 12:00:40 +00:00
Matthias Clasen
c020e83890
Merge branch 'matthiasc/for-master' into 'master'
...
Add a custom input test
See merge request GNOME/gtk!3851
2021-08-18 03:24:41 +00:00
Matthias Clasen
f6659fea8d
imcontext: Improve docs
...
Add some more docs around GtkIMContext.
2021-08-17 22:33:26 -04:00
Matthias Clasen
a06858ccd9
Add a custom input test
...
This shows the minimal work required to hook up an
im context to a custom widget.
2021-08-17 22:33:26 -04:00
Emmanuele Bassi
c6c48d327c
Merge branch 'wip/exalm/query-action-transfer' into 'master'
...
widget: Fix gtk_widget_class_query_action() annotations
See merge request GNOME/gtk!3843
2021-08-17 17:56:40 +00:00
Chun-wei Fan
5d0f188615
GDK-Win32: Reject WGL context if shaders aren't supported
...
When we initialize OpenGL, check whether we have OpenGL 2.0 or later; if not,
check whether we have the 'GL_ARB_shader_objects' extension, since we must be
able to support shaders if using OpenGL for GTK.
If we don't support shaders, as some Windows graphics drivers do not support
OpenGL adequately, notably older Intel drivers, reject and destroy the GL
context that we created, and so fallback to the Cairo GSK renderer, so that
things continue to run, albeit with an expected warning message that the GL
context cannot be realized.
Also, when we could not make the created dummy WGL context current during
initialization, make sure that we destroy the dummy WGL context as well.
Fixes issue #4165 .
2021-08-17 16:25:09 +08:00
Benjamin Otte
78fcc8feb8
Merge branch 'wip/otte/for-master' into 'master'
...
gdk: Include Vulkan error code in vulkan_strerror()
See merge request GNOME/gtk!3844
2021-08-12 12:36:28 +00:00
Benjamin Otte
27cad85247
gdk: Include Vulkan error code in vulkan_strerror()
2021-08-12 14:19:30 +02:00
Simon Ser
ad0c1d4dbe
gdk/wayland: add support for wl_seat version 7
...
Version 7 requires wl_keyboard keymaps to be mapped with
MAP_PRIVATE, so that the compositor can share the same keymap
file between multiple clients.
2021-08-11 16:37:03 +02:00
Simon Ser
00abaed89a
gdk/wayland: add support for wl_seat version 6
...
Version 6 adds two new wl_touch events, which can be ignored.
2021-08-11 16:36:57 +02:00
Alexander Mikhaylenko
342f02711b
widget: Fix gtk_widget_class_query_action() annotations
...
Add transfer none on all out values as they aren't being copied.
2021-08-11 14:33:38 +05:00
Matthias Clasen
d9c48a8d01
Merge branch 'matthiasc/for-master' into 'master'
...
Handle the new line height pango attribute
See merge request GNOME/gtk!3840
2021-08-10 15:08:20 +00:00
Matthias Clasen
d757696116
ci: Add libjpeg-turbo-devel to the Fedora image
...
This was getting downloaded from sourceforge every
time for the docs build, and that started failing.
2021-08-10 08:22:52 -04:00
Matthias Clasen
528ebfabf0
Handle the new line height pango attribute
...
Update all the places where we switch over PangoAttributeType
to handle (and ignore, for now) the new line height attribute.
2021-08-10 08:22:52 -04:00
Vincent Bernat
2ebde276d1
x11: ensure WM class is not null even if display is initialized early
...
With gtkmm, when using `Application()`, the display is initialized
before we know the application name and therefore, the program class
associated to the display is NULL.
Instead of providing a default value, we set it equal to program name
when NULL. Moreover, we give up on capitalizing the class name to keep
the code super simple. Also, not using a capitalized name is
consistent with `gdk_x11_display_open()`. If someone has a good reason
to use a capitalized name, here is how to do it.
```c
class_hint = XAllocClassHint ();
class_hint->res_name = (char *) g_get_prgname ();
if (display_x11->program_class)
{
class_hint->res_class = (char *) g_strdup (display_x11->program_class);
}
else if (class_hint->res_name && class_hint->res_name[0])
{
class_hint->res_class = (char *) g_strdup (class_hint->res_name);
class_hint->res_class[0] = g_ascii_toupper (class_hint->res_class[0]);
}
XSetClassHint (xdisplay, impl->xid, class_hint);
g_free (class_hint->res_class);
XFree (class_hint);
```
Fix eff53c023a ("x11: set a default value for program_class")
2021-08-10 09:14:36 +02:00
Matthias Clasen
04f3c8054b
Merge branch 'callback-annotation-again' into 'master'
...
widget: Change callback scope
See merge request GNOME/gtk!3796
2021-08-10 01:16:56 +00:00
Benjamin Otte
ea07bf7536
Merge branch 'wip/otte/for-master' into 'master'
...
ngl: Make current when unrealizing
See merge request GNOME/gtk!3835
2021-08-08 01:09:31 +00:00
Benjamin Otte
80e6f1ca8c
ngl: Make current when unrealizing
...
The profiler (at least) discards GL objects and we want to discard them
on the right context.
2021-08-08 02:17:08 +02:00
Matthias Clasen
54d29568ec
Merge branch 'matthiasc/for-master' into 'master'
...
Cosmetics: Tweak css parser error messages
See merge request GNOME/gtk!3834
2021-08-07 22:48:32 +00:00
Matthias Clasen
4e1ea58503
Cosmetics: Tweak css parser error messages
...
These show up in tooltips, so they should a) be capitalized
and b) not end with a period.
2021-08-07 18:18:10 -04:00
Andre Klapper
90c429a91c
Belarusian translation: Remove broken translation string
2021-08-07 19:10:23 +02:00
Andre Klapper
4b28e038e0
Khmer translation: Strip some invisible bytes from setting translations
2021-08-07 19:10:22 +02:00
Matthias Clasen
8df694a358
Merge branch 'matthiasc/for-master' into 'master'
...
gtk-demo: Spruce up the hypertext demo
See merge request GNOME/gtk!3832
2021-08-07 16:56:56 +00:00
Yaron Shahrabani
eb8778e1cd
Update Hebrew translation
...
(cherry picked from commit 11e6ce1751 )
2021-08-07 16:51:55 +00:00
Matthias Clasen
256f3a0d60
gtk-demo: Spruce up the hypertext demo
...
Use the newish allow-breaks pango attribute
to make the text break better.
2021-08-07 12:35:17 -04:00
Danial Behzadi
54c087e7ec
Update Persian translation
2021-08-07 14:48:55 +00:00
Danial Behzadi
69a99b89f9
Update Persian translation
...
(cherry picked from commit b467881274 )
2021-08-07 14:45:02 +00:00
Matthias Clasen
f328ab9d83
Merge branch 'wip/chergert/revert-top-margin' into 'master'
...
Revert "textview: fix yoffset position when top_margin is set"
See merge request GNOME/gtk!3828
2021-08-06 13:13:21 +00:00
Chun-wei Fan
8acce5f294
gdk/win32: Drop local DnD protocol
...
It is basically not used by default and is pretty much broken at this point, so
it's about time to drop it.
Let's focus on fixing the OLE2 DnD protocol.
2021-08-06 17:16:27 +08:00
Matthias Clasen
bdbe0acd1f
Merge branch 'matthiasc/for-master' into 'master'
...
settings: Default gtk-split-cursor to FALSE
See merge request GNOME/gtk!3827
2021-08-05 19:17:54 +00:00
Christian Hergert
fc701baef8
Revert "textview: fix yoffset position when top_margin is set"
...
This reverts commit 908b1e5e12 .
This commit broke top-margin altogether.
2021-08-05 11:52:45 -07:00
Matthias Clasen
a457a81fd9
Merge branch 'matthiasc/for-master' into 'master'
...
text: Move setup code out of a loop
See merge request GNOME/gtk!3826
2021-08-05 18:45:39 +00:00
Matthias Clasen
4cc7977d36
settings: Default gtk-split-cursor to FALSE
...
According to Owen, this was the intention when the setting
was added in 2001. It only took us 20 years to fix the
default value.
2021-08-05 14:05:28 -04:00
Matthias Clasen
e5e7f5dd88
ci: Disable treeview-headers-hidden reftest
...
Somebody needs to figure out why it fails in ci so
frequently.
2021-08-05 12:41:04 -04:00
Matthias Clasen
916886312a
Merge branch 'wip/exalm/shadow-extents' into 'master'
...
Shrink shadow extents
See merge request GNOME/gtk!3825
2021-08-05 16:39:52 +00:00
Matthias Clasen
8ff94ea1f2
text: Move setup code out of a loop
...
Just a cleanup, no functional change.
2021-08-05 12:31:18 -04:00
Matthias Clasen
053bd0cd31
Merge branch 'fix-tab-not-captured-in-popover' into 'master'
...
popovermenu: Cycle around focus also with (Shift+)Tab
Closes #3915
See merge request GNOME/gtk!3732
2021-08-05 02:07:43 +00:00
vanadiae
a3ce574193
popover: Cycle around focus with (Shift+)Tab
...
Same thing as the previous popovermenu commit, except for the base popover
because the popovermenu needs special behaviour with e.g. sides arrow so
we need to have the "cycle around" for regular popovers here too.
2021-08-04 12:11:44 +02:00
vanadiae
ef92adc87d
popovermenu: Cycle around focus also with (Shift+)Tab
...
Currently when moving the focus with (Shift+)Tab, it also traverses the window's
widgets, although it would be expected that the focus stays within the popover,
as it's (almost) like it's a separate window. This would be consistent with
the behaviour of the Up/down arrows, which do cycle around the focus once it
reaches the end.
So this commit makes the popovermenu cycle around focus in any direction, apart
from left/right because they are used to open and close submenus and it wouldn't
make sense anyway to cycle horizontally as there's usually only one widget per
line.
2021-08-04 12:11:44 +02:00
Alexander Mikhaylenko
46a9538b6a
Shrink shadow extents
...
Long time ago, Cairo shadows in both GTK3 and 4 were drawn at a size about
twice their radius. Eventually this was fixed but the shadow extents are
still calculated for the previous size and appear unreasonably large: for
example, 141px for a 50px radius shadow. This can get very noticeable in
places such as invisible window frame which gets included into screenshots.
https://gitlab.gnome.org/GNOME/gtk/-/merge_requests/3419 just divides the
radius by 2 when drawing a shadow with Cairo, do the same when calculating
extents.
See https://gitlab.gnome.org/GNOME/gtk/-/issues/3841
2021-08-04 14:47:17 +05:00
Matthias Clasen
ca547b8716
Merge branch 'combobox-keynav' into 'master'
...
treepopover: Add keynav
See merge request GNOME/gtk!3822
2021-08-03 11:20:56 +00:00
Matthias Clasen
04ea51e843
treepopover: Start adding keynav
...
Arrange for the items to be focusable, and add keyboard
activation. Still missing: cycling focus inside the
popover.
2021-08-02 23:49:05 -04:00
Matthias Clasen
f7dc0dda4e
Merge branch 'big-keysyms' into 'master'
...
imcontext: Treat keysyms as 32bit values
Closes #4149
See merge request GNOME/gtk!3819
2021-08-03 01:05:16 +00:00
Matthias Clasen
8713843022
Merge branch 'surround-test' into 'master'
...
Remove an unimplemented function
Closes #4151
See merge request GNOME/gtk!3820
2021-08-03 01:00:13 +00:00
Matthias Clasen
6563b05d60
Add some GtkIMContext tests
...
For now, these check that the surrounding handling
in GtkText and GtkTextView is sane.
Fixes : #4151
2021-08-02 20:44:40 -04:00
Matthias Clasen
d119c55b72
textview: Fix the get_surrounding implementation
...
This was, sadly, returning garbage.
2021-08-02 20:44:40 -04:00
Matthias Clasen
253e25a73c
Add a private getter for the textview key controller
...
This will be used in tests.
2021-08-02 20:44:40 -04:00
Matthias Clasen
c63774967f
Remove an unimplemented function
...
_gtk_entry_get_im_context does not exist.
2021-08-02 20:44:40 -04:00
Matthias Clasen
bbc36448fb
imcontext: Treat keysyms as 32bit values
...
Our compose table format is still limited to 16bit
values for keysyms, but what we see in key events
can be 32bit values, and we treat them as such now.
Fixes : #4149
2021-08-02 19:16:18 -04:00
Matthias Clasen
5df323fb64
Merge branch 'fix-custom-widget-menu-focus' into 'master'
...
menusectionbox: Passthrough the focus function of custom widgets' gizmo
Closes gnome-text-editor#93
See merge request GNOME/gtk!3817
2021-08-02 22:21:08 +00:00
Matthias Clasen
0f2c5f13be
Merge branch 'wip/otte/for-master' into 'master'
...
video: Use cross-fade transition to avoid resizes
See merge request GNOME/gtk!3815
2021-08-02 22:19:39 +00:00
Matthias Clasen
58180ad3be
Merge branch 'fix-4144' into 'master'
...
gtkgesturerotate: Fix assertion
Closes #4144
See merge request GNOME/gtk!3818
2021-08-02 22:17:20 +00:00
James Westman
fb0229890b
gtkgesturerotate: Fix assertion
...
Fixes #4144 . An assertion would be printed when GtkGestureRotate was
used with a touchscreen.
2021-08-02 16:38:35 -05:00
vanadiae
9099888398
menusectionbox: Passthrough the focus function of custom widgets' gizmo
...
It broke keyboard focusing any widget added through the custom widget
menu feature. So for example if you put e.g. a custom check box widget
in a menu, you won't be able to focus it.
This is because the gizmo is mostly used to custom drawing with e.g.
CSS for small visual elements like scale markers. That's probably why
gizmo's default focus overrides block the focus from going through
the children. So this commit fixes it by overriding those and passing
the focus through the children.
2021-08-02 21:20:32 +02:00
Benjamin Otte
882855f865
video: Use cross-fade transition to avoid resizes
...
Slide animations cause changes in the size requests due to the
behavior of GtkRevealer. We can avoid those by using cross-fades, which
don't have that problem.
Besides, cross-fades look better anyway.
2021-08-02 20:11:32 +02:00
Matthias Clasen
f59d2ae89d
Merge branch 'input-tweaks' into 'master'
...
imcontext: Tweak Compose sequence preedit
Closes #10 , #4127 , and #4124
See merge request GNOME/gtk!3799
2021-08-02 18:07:46 +00:00
Matthias Clasen
7c3a53a171
Merge branch 'fix-double-underscore-mnemonic' into 'master'
...
label: Ignore __ for mnemonics
Closes #4129
See merge request GNOME/gtk!3814
2021-08-02 03:54:29 +00:00
Matthias Clasen
1e22572716
Avoid pango deprecations
...
This function has been deprecated on the main
branch of pango. Since we don't want to bump our
pango dependency to 1.49 yet, ignore the deprecation.
2021-08-01 23:20:01 -04:00
Matthias Clasen
8a25f54e1f
Add more label parsing tests
...
Test various combinations of underline and markup
parsing.
2021-08-01 23:19:00 -04:00
Matthias Clasen
c51f2fc0ec
label: Ignore __ for mnemonics
...
We were not ignoring double underscores for mnemonics
in one place, as we should.
Fixes : #4129
2021-08-01 22:14:12 -04:00
Matthias Clasen
2a528df977
Merge branch 'titlebar-gesture' into 'master'
...
Delegate titlebar action to the compositor if possible
See merge request GNOME/gtk!3797
2021-08-02 01:14:08 +00:00
Piotr Drąg
84684bd56e
Update Polish translation
2021-08-01 14:21:25 +02:00
Matthias Clasen
e1606ce8eb
Merge branch 'color-glyph-fixes' into 'master'
...
gsk: Make color glyphs
Closes #4141
See merge request GNOME/gtk!3812
2021-07-31 20:54:39 +00:00
Matthias Clasen
47072e0441
Merge branch 'fix-iconhelper' into 'master'
...
iconhelper: Fix the paintable implementation
Closes #4140
See merge request GNOME/gtk!3809
2021-07-31 20:35:08 +00:00
Matthias Clasen
915c229396
gsk: Use harfbuzz for color fonts
...
harfbuzz has all the information we need, so we
can avoid poking directly at freetype apis. Also
drop the caching of color glyph information until
it turns out to be a problem.
2021-07-31 16:34:38 -04:00
Matthias Clasen
0bf46b4845
Bump the harfbuzz dep
...
We need 2.1.0, which has the hb_ot_color apis that we
are going to use in the next commit.
2021-07-31 16:34:38 -04:00
Matthias Clasen
a7a2dbc3ea
gsk: Cache per-glyph color information
...
We don't really want to load the bitmaps every time
we create a render node, so do it once and cache the
information on the PangoFont.
2021-07-31 16:34:38 -04:00
Matthias Clasen
7e8f586859
ngl: Use per-glyph color information
...
Decide per-glyph whether we need color nor not.
Fixes : #4141
2021-07-31 16:34:24 -04:00
Matthias Clasen
bb9dccd773
gsk: Mark color glyphs
...
Steal a bit from PangoGlyphVisAttr to mark glyphs
that have color.
2021-07-31 16:34:24 -04:00
Emmanuele Bassi
7b743e662e
Merge branch 'update-docs' into 'master'
...
docs: Update the URL for related documentation
See merge request GNOME/gtk!3813
2021-07-31 18:39:52 +00:00
Emmanuele Bassi
769dc53c05
docs: Update the URLs of related projects for GTK
...
And install the gi-docgen project file as well.
2021-07-31 19:08:34 +01:00
Emmanuele Bassi
1a4554daf3
docs: Update the URLs of related projects for GSK
...
And install the gi-docgen project file.
2021-07-31 19:07:18 +01:00
Emmanuele Bassi
6c0633ef61
docs: Update the URL for related documentation
...
And install the gi-docgen project files for GDK.
2021-07-31 19:05:33 +01:00
Emmanuele Bassi
4d020a3875
Merge branch 'docs-trigger' into 'master'
...
ci: Trigger a pages build
See merge request GNOME/gtk!3811
2021-07-31 17:16:26 +00:00
Emmanuele Bassi
316cc55e69
ci: Trigger a pages build
...
Do not publish the API reference directly, but trigger a CI pipeline for
the docs-gtk-org branch, which will then do the publishing.
2021-07-31 17:13:27 +01:00
Emmanuele Bassi
95f2634ea9
Merge branch 'iter-is-valid-docs' into 'master'
...
docs: Fix iter_is_valid() description
See merge request GNOME/gtk!3810
2021-07-31 13:07:07 +00:00
Emmanuele Bassi
95c032f531
docs: Fix iter_is_valid() description
...
Drop the "WARNING" and the block quote, and follow the existing
documentation style guidelines.
2021-07-31 13:41:13 +01:00
Matthias Clasen
744955753f
iconhelper: Fix the paintable implementation
...
get_current_image was recursing due to an obvious typo.
Fixes : #4140
2021-07-31 08:27:17 -04:00
Matthias Clasen
ae5e7dc65d
Merge branch 'glyph-cache-mystery' into 'master'
...
ngl: Bypass pango for glyph cache rendering
See merge request GNOME/gtk!3807
2021-07-31 00:38:41 +00:00
Matthias Clasen
ed41c46926
ngl: Bypass pango for glyph cache rendering
...
We can just use cairo directly here,
and cut out some layers of pango in the middle.
2021-07-30 19:46:07 -04:00
Matthias Clasen
a460fb2734
Merge branch 'check-activate' into 'master'
...
checkbutton: Some fixes when used with GActions
See merge request GNOME/gtk!3805
2021-07-30 23:39:17 +00:00
Matthias Clasen
39ddce6ba3
Merge branch 'fix/wm_class' into 'master'
...
x11: set a default value for program_class
Closes #4138
See merge request GNOME/gtk!3806
2021-07-30 23:25:08 +00:00
Matthias Clasen
8da7e3bdc3
Merge branch 'wip/otte/for-master' into 'master'
...
widget-factory: Expand the video to cover the whole frame
See merge request GNOME/gtk!3804
2021-07-30 22:43:29 +00:00
Vincent Bernat
eff53c023a
x11: set a default value for program_class
...
This was also the behaviour with GTK 3. We use the capitalized program
name.
Fixes #4138
Signed-off-by: Vincent Bernat <vincent@bernat.ch >
2021-07-30 23:22:32 +02:00
Benjamin Otte
99e4a6a2d6
widget-factory: Propagate natural size for text styles
...
This avoids them requiring scrolling.
2021-07-30 20:54:58 +02:00
Benjamin Otte
c06817b951
widget-factory: Make frames cooler
...
Instead of havoing a label for the video frame that clashes with the
background of the video, add a frame around the text styles box and add
a label for them. As a side benefit, it also makes it more obvious that
it is scrollable.
Note: Most of this patch is just reindenting.
2021-07-30 20:43:02 +02:00
Benjamin Otte
e765aaa3f4
widget-factory: Expand the video to cover the whole frame
...
1. This looks way cooler.
2. Since the frame is rounded, it adds a very visible test for our
clipping of rounded rectangles.
2021-07-30 20:37:34 +02:00
Florian Müllner
1728aa581c
checkbutton: Activate when moving focus
...
Currently we update the :active property on both the previous and
new focus button. That "visually activate" the button and will
emit ::toggled, but if the button is associated with an action,
the action state won't change.
Fix that by activating the new focus instead of explicitly fiddling
with the :active property.
2021-07-30 20:34:24 +02:00
Florian Müllner
c50475de34
checkbutton: Delegate ::activate to the helper if appropriate
...
If the button is associated with an action, the action is currently
only activated when the button is clicked, not when it is activated.
2021-07-30 20:34:24 +02:00
Mike Gorse
5d7ecb7a6e
a11y: Remove unneeded check
2021-07-30 08:58:27 -05:00
Matthias Clasen
06348a8517
Merge branch 'wip/chergert/fix-4134' into 'master'
...
textview: fix yoffset position when top_margin is set
Closes #4134
See merge request GNOME/gtk!3801
2021-07-30 13:41:30 +00:00
Matthias Clasen
c4dbb8f01e
imcontext: Code cleanup
2021-07-29 20:37:58 -04:00
Matthias Clasen
e67b2cb54b
composetable: Allow multiple dead keys
...
Remove the limitation on the number of dead keys
that we match, and allow the result be be multiple
characters.
Regenerate the builtin sequences, since this changes
what dead key sequences we can reproduce algorithmically.
Update tests to match.
Fixes : #10
2021-07-29 20:37:30 -04:00
Christian Hergert
908b1e5e12
textview: fix yoffset position when top_margin is set
...
This doesn't need to be included in the calculation or it will cause the
yoffset to continually shift while the window is resized.
Fixes #4134
2021-07-29 16:45:04 -07:00
Matthias Clasen
539391ce6c
composetable: Change an API
...
Make gtk_check_algorithmically take a GString
for the result. This is in preparation for allowing
multi-character results here, in the future.
Update all callers.
2021-07-29 17:29:25 -04:00
Mike Gorse
7fc90aed26
a11y: Send correct object reference for the root accessible
2021-07-29 15:55:58 -05:00
Florian Müllner
23e79d2eb2
gtk/windowhandle: Delegate titlebar action to the compositor if possible
...
Delegating the action to the compositor not only improves consistency
with server-side decorations, but also allows for actions that aren't
available client-side (like lower-in-middle-click).
https://gitlab.gnome.org/GNOME/mutter/-/issues/602
2021-07-29 21:39:32 +02:00
Florian Müllner
0c7b1431d7
gdk/toplevel: Add gdk_toplevel_titlebar_gesture()
...
Where supported, this allows delegating the titlebar action to the
compositor instead of trying to replicate its behavior client-side.
https://gitlab.gnome.org/GNOME/mutter/-/issues/602
2021-07-29 21:39:32 +02:00
Matthias Clasen
b6c0155836
imcontext: Handle Escape in Compose sequence
...
Treat Escape the same in hex sequences and in
Compose sequence: reset the state.
2021-07-29 08:39:17 -04:00
Matthias Clasen
76d67b586c
imcontext: Tweak Compose sequence handling
...
When we don't have any matches for a Compose sequence
anymore, beep, and keep the preedit as it was for the
last match.
Fixes : #4127
2021-07-29 08:24:14 -04:00
Matthias Clasen
914edb1472
composetable: Add a prefix api
...
Add a function that computes the longest prefix
of a buffer for which a compose table has matches.
2021-07-29 08:23:40 -04:00
Matthias Clasen
dbf5033f94
composetable: Reduce the scope of a variable
...
'prefix' is not a good name for a file-scope variable,
move it into the sole function using it.
2021-07-29 08:22:52 -04:00
Matthias Clasen
cc6ecc8b62
Merge branch 'source-static-name' into 'master'
...
Avoid copying static debug strings
See merge request GNOME/gtk!3789
2021-07-29 11:59:02 +00:00
Matthias Clasen
b7e6922605
imcontext: Tweak Compose sequence preedit
...
When sequences contain multiple Compose keys,
don't hide the first one. This is a very fringe
case, but it matches the behavior of IBus.
Fixes : #4124
2021-07-29 07:36:48 -04:00
Matthias Clasen
05eaffb9f2
ci: Collect tools test output
...
This should help understanding why some of them fail.
2021-07-28 22:42:46 -04:00
Matthias Clasen
67b568f464
testsuite: Set TEST_RESULT_DIR for tools tests
2021-07-28 22:42:46 -04:00
Matthias Clasen
19b534f7de
Avoid copying static debug strings
...
The g_source_set_name calls were showing up as a
major source of strdups in our profiles. Avoid that
by using new GLib api when available.
2021-07-28 22:42:46 -04:00
Florian Müllner
bc386c9a60
widget: Change callback scope
...
Look who changed his mind since commit 8e2ffb3b46 :-)
The "call" scope means that the callback is only used during the
function call itself (here: gtk_widget_class_install_action()).
That's clearly wrong here, as the callback is invoked every time
the action is activated.
Arguably the "notified" scope is a better match here, where the
lack of a GDestroyNotify parameter suggests that the callback may
be used forever (which is the case here).
Related: #3498
2021-07-28 21:48:01 +02:00
Matthias Clasen
db8b3419c2
Merge branch 'compose-parse-msvc' into 'master'
...
compose-parse.c: Include stdlib.h (fix build on Visual Studio)
See merge request GNOME/gtk!3794
2021-07-28 10:38:25 +00:00
Fabio Tomat
0f5ba5192a
Update Friulian translation
...
(cherry picked from commit 16aa8dbad7 )
2021-07-28 09:11:33 +00:00
Chun-wei Fan
108c423d70
compose-parse.c: Include stdlib.h
...
That is needed for exit(), and it may not have been included by the
other headers.
2021-07-28 15:18:36 +08:00
Emmanuele Bassi
dded10a396
Merge branch 'gi-fix' into 'master'
...
gdk: add missing Since annotation
See merge request GNOME/gtk!3790
2021-07-27 17:38:28 +00:00
Marc-André Lureau
1b080826db
gdk: add missing Since annotation
...
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com >
2021-07-27 21:01:31 +04:00
Matthias Clasen
910f23ea19
Merge branch 'wip/otte/widgetfactory-dnd' into 'master'
...
Improve DND
See merge request GNOME/gtk!3785
2021-07-27 04:12:58 +00:00
Benjamin Otte
f1b50baba1
widget-factory: Add images that support dnd
...
Just use the bottom left notebook for a GtkPicture with custom drag
source and drop target.
2021-07-27 04:40:57 +02:00
Matthias Clasen
4453597946
widget-factory: Some new backgrounds
...
Snowy wasn't ideal because of the aspect ratio.
Replace it by beach and nyc.
2021-07-27 04:40:42 +02:00
Benjamin Otte
192bfa10cb
droptarget: Make formats construct-only writable
...
This way, it can be set in GtkBuilder.
Also make sure to only ever look at the GTypes set in the formats, as
GtkDropTarget cannot deal with mime types.
2021-07-27 04:28:04 +02:00
Benjamin Otte
0781429dc5
builder: Add support for GdkContentFormats
2021-07-27 04:28:04 +02:00
Benjamin Otte
d760332f00
testsuite: Add contentformat tests
2021-07-27 04:28:04 +02:00
Benjamin Otte
131be5f2e8
contentformats: Add gdk_content_formats_parse()
2021-07-27 04:13:42 +02:00
Matthias Clasen
57a95c540c
Merge branch 'matthiasc/for-master' into 'master'
...
ngl: Cosmetics
See merge request GNOME/gtk!3786
2021-07-26 18:21:56 +00:00
Matthias Clasen
09deb1d757
ngl: Cosmetics
...
Use the macro we already have to check that colors
are fully transparent.
2021-07-26 13:42:10 -04:00
Matthias Clasen
5c4aba4b9c
Merge branch 'wip/compose-parser' into 'master'
...
Clean up the GtkComposeTable api
See merge request GNOME/gtk!3746
2021-07-26 11:51:14 +00:00
Benjamin Otte
6a5d555f58
contentformats: Change the format of gdk_content_formats_to_string()
...
Now, we just print a whitespace-separated list of GTypes and mime types.
This makes this neat for 2 things:
1. Parsing it (see next commit)
2. Using it in GtkBuilder (see commits after that)
In particular, the common case of supporting a single GType (or mime
type) looks like just printing the GType (or mime type), which in
GtkBuilder looks like
<property name="formats">GdkTexture</property>
2021-07-26 02:28:49 +02:00
Benjamin Otte
f5dc71021f
dnd: Guard drags with a reference when finishing
...
Usually the "dnd-finished" signal will be used to unref the GdkDrag. In
those cases, we would lose the object, so that when we do the final
drag_drop_done() afterwards, we wouldn't have a remaining reference.
With the reference guard, this now works.
2021-07-26 02:18:54 +02:00
Matthias Clasen
39005461c5
4.3.2
2021-07-24 22:04:49 -04:00
Matthias Clasen
4dc4c00267
Merge branch 'misc-speedups' into 'master'
...
ngl: Speed up clipping calculations a bit
See merge request GNOME/gtk!3784
2021-07-25 02:03:46 +00:00
Matthias Clasen
d76460343a
sizerequest: Simplify some code
...
Avoid some repeated MAX().
2021-07-24 18:49:41 -04:00
Matthias Clasen
0d8dd0c664
sizerequest: Keep branches in sync
...
There are some unintentional differences between
the path that uses a layout manager, and the path
that uses widget vfuncs. Sync them up.
2021-07-24 18:49:41 -04:00
Matthias Clasen
ee6491f717
widget: Avoid some unnecessary back-and-forth casting
...
Avoid some unnecessary casting and a redundant early exit.
2021-07-24 18:49:27 -04:00
Matthias Clasen
7044951dab
widget: Avoid GObject data for action muxer
...
Most widget have an action muxer now, so just
store it in GtkWidgetPrivate.
2021-07-24 18:48:10 -04:00
Matthias Clasen
98986a25f9
layoutmanager: Avoid some overhead
...
Use inline getters for some things.
2021-07-24 18:48:10 -04:00
Matthias Clasen
ae3e586714
gridlayout: Avoid some unnecessary overhead
...
Use inline functions for some things.
2021-07-24 18:48:10 -04:00
Matthias Clasen
0ef12193f9
gsk: Optimize gsk_transform_to...
...
Optimize these functions for the common cases.
2021-07-24 18:48:10 -04:00
Matthias Clasen
b695ef9168
gsk: Add a shortcut for a common transform case
...
Add a private getter for the translation part of a
transform node, to avoid pulling it out of the transform
over and over.
2021-07-24 18:48:09 -04:00
Matthias Clasen
7fb1389648
gsk: Add a private getter for container children
...
No need to get them one-by-one, in our inner loop.
2021-07-24 18:48:09 -04:00
Matthias Clasen
f88efb811b
ngl: Reduce type checking overhead
...
No need to be very careful here, these are entirely
internal types.
2021-07-24 18:48:09 -04:00
Matthias Clasen
466d33ca69
ngl: Speed up clipping calculations a bit
...
Exit as early as possible from intersect_rounded_rectilinear.
2021-07-24 18:48:09 -04:00
Piotr Drąg
d44ce1987d
Update POTFILES.in
2021-07-24 14:38:51 +02:00
Emmanuele Bassi
527b2c5ab1
Merge branch 'no-pposition' into 'master'
...
gdk/x11: Do not set PPosition hint
See merge request GNOME/gtk!3781
2021-07-24 11:45:00 +00:00
Florian Müllner
4d0c2997cf
gdk/x11: Do not set PPosition hint
...
It is good practice for (floating) window managers to respect explicit
position hints from clients (as long as the window wouldn't end up
off-screen etc.).
Before commit 13d3afa56e , GTK had a flag for setting the PPosition hint,
but now does so unconditionally. However the real intention is to *not*
request a fixed position, so don't do that.
2021-07-24 06:32:16 +02:00
Matthias Clasen
6f04ec9dae
Merge branch 'wip/exalm/gtktext-selection-fix' into 'master'
...
text: Use the widget y coordinate for gestures
See merge request GNOME/gtk!3780
2021-07-23 20:29:07 +00:00
Alexander Mikhaylenko
00cc99818d
text: Use the widget y coordinate for gestures
...
Currently we use layout coordinates and widget height when determining
where a click or drag has happened. If the widget has top padding (which it
does inside a GtkEntry, for example), the area where it's possible to select
text is shifted down, so the part of GtkText above the layout is not counted
as the draggable area and instead the equal area below the widget is counted.
Since GtkText is always single-line, there's no need to do any of that and
we can use widget coordinates. Then the draggable area matches the widget
and the problems goes away.
2021-07-23 23:37:36 +05:00
Matthias Clasen
e51fdc1c9b
Merge branch 'stack-page-name' into 'master'
...
stack: GtkStackPage:name is not construct-only
Closes #4109
See merge request GNOME/gtk!3778
2021-07-23 14:25:29 +00:00
Matthias Clasen
8d5ef4ab30
Merge branch 'matthiasc/for-master' into 'master'
...
Cosmetics
See merge request GNOME/gtk!3779
2021-07-22 21:22:55 +00:00
Matthias Clasen
7bdda15b86
Cosmetics
...
Fix a comment typo.
2021-07-22 17:03:08 -04:00
Matthias Clasen
4c41ef8de3
stack: GtkStackPage:name is not construct-only
...
We have a setter for this property, so we clearly
weren't serious when we marked it as construct-only.
Fixes : #4109
2021-07-22 16:55:15 -04:00
Matthias Clasen
7aec3b0fa1
Merge branch 'startup-profiling' into 'master'
...
Add more sysprof marks
See merge request GNOME/gtk!3777
2021-07-22 19:20:22 +00:00
Matthias Clasen
fce23c981b
Add more sysprof marks
...
Add a few more marks during gtk_init to figure out where
our startup time goes, and avoid the sysprof initialization
from distorting the first mark.
2021-07-22 14:47:02 -04:00
Matthias Clasen
351819b570
Merge branch 'startup-profiling' into 'master'
...
Add more sysprof marks
See merge request GNOME/gtk!3776
2021-07-22 17:04:27 +00:00
Matthias Clasen
a10b1b7341
Add more sysprof marks
...
Add a few more marks during gtk_init to figure out where
our startup time goes, and avoid the sysprof initialization
from distorting the first mark.
2021-07-22 12:51:32 -04:00
Benjamin Otte
02c6226741
Merge branch 'wip/otte/gleanup' into 'master'
...
reorganize GDK's GL code
See merge request GNOME/gtk!3726
2021-07-22 14:51:05 +00:00
Benjamin Otte
620ccdabb5
glx: Get rid fo DrawableInfo
...
Store the frame counter in the surface, where it belongs.
2021-07-22 16:28:16 +02:00
Chun-wei Fan
4b12dc6547
gdkdisplay-win32.c: Don't call ReleaseDC() unnecessarily
...
The dummy Win32 window that we use to capture display change events and
to create dummy WGL contexts was created with CS_OWNDC, so we really do
not need to (and should not) call ReleaseDC() on the HDC that we
obtained from it, so drop these calls.
2021-07-22 16:28:16 +02:00
Chun-wei Fan
bd69d7e23f
GDK-Win32: init_gl(): Default to WGL for now
...
Since the shaders need to be updated for using with GLES (libANGLE at
least), default to WGL for now. Unfortunately it is not that common for
Windows to have GLES support, in which the easiest way to obtain such
support is via Google's libANGLE.
2021-07-22 16:28:16 +02:00
Chun-wei Fan
8648486400
GDK-Win32: Fixup, and cleanup WGL HDC handling
...
It turns out that the problem of the WGL window not drawing was due to
the fact that I messed up where I placed SwapBuffers() during the
conversion... doh:|
At the same time, stop storing the HDC in the GdkWin32GLContextWGL, but
instead always create it along the surface we created, so that it is ready
for use for operating with WGL when we are not dealing with "surfaceless"
contexts. If we are dealing with "surfaceless" contexts, just use the
HDC of the dummy window that we created when we created the
Gdk(Win32)Display.
WGL contexts should now be in working order at this point.
2021-07-22 16:28:16 +02:00
Chun-wei Fan
6c00117119
Split out WGL/EGL stuff and simplify things
...
This commit attempts to split GdkWin32GLContext into two parts, one for
WGL and the other for EGL (ANGLE), and attempts to simplify things a
bit, by:
* We are already creating a Win32 window to capture display changes,
so we can just use that to act as our dummy window that we use to
find out the pixel format that the system supports for WGL. We also
use it to obtain the dummy legacy WGL context that we will always
require to create our more advanced Core WGL contexts.
* Like what is done in X11, store up the WGL pixel format or the
EGLConfig in our GdkWin32Display.
* Ensure we do not create the dummy WGL context unnecessarily.
In this way, we can successfully create the WGL/EGL contexts, however
there are some issues at this point:
* For WGL, the code successfully initializes and realizes the WGL
Contexts, but for some reason things became invisible. When running
gtk4-demo, this can be verified by seeing the mouse cursor changing
when moved to spots where one can resize the window, although they
were invisible.
* For EGL, the code initializes EGL but could not realize the EGL
context as shaders failed to compile. It seems like the shader issue
is definitely outside the scope of this MR.
2021-07-22 16:28:16 +02:00
Benjamin Otte
9c4c4eaaa1
gl: Fix issue with EGL + nvidia
...
nvidia sets the default draw buffer to GL_NONE if EGL contexts are
initially bound to EGL_NO_SURFACE which is exactly what we are doing. So
bind them to GL_BACK when drawing, as they should be.
See https://phabricator.services.mozilla.com/D118743 for a discussion
about EGL_NO_CONTEXT and draw buffers.
2021-07-22 16:28:16 +02:00
Chun-wei Fan
969b3257a7
GDK: Add debug option for WGL usage
...
This way, one can force using WGL on Windows even if EGL support was
enabled. Also update the help text for gl-egl as it will apply for
Windows, albeit a bit later.
2021-07-22 16:28:16 +02:00
Chun-wei Fan
65c6af31e1
GDK-Win32: Move some functions out of gdkglcontext-win32.c
...
We want these to be out of the way as we split between WGL and EGL/ANGLE
GL contexts, so that they don't get in the way.
2021-07-22 16:28:16 +02:00
Benjamin Otte
6b8bc83420
display: Move GL selection code into gdkdisplay-x11.c
...
This has the benefit that we can refactor it and make sure we deal with
GdkDisplay::init_gl() not being called at all because
GDK_DEBUG=gl-disable had been specified.
2021-07-22 16:28:16 +02:00
Benjamin Otte
30aaab5c6c
x11: Move code from GdkGLContextX11
...
It's not used there, but both backends have independent
immplementationgs for it.
I want to get rid of GdkGLContextX11 and moving code from it is the
first step.
2021-07-22 16:28:16 +02:00
Benjamin Otte
72e2a46c05
inspector: Add support for displaying GL errors
...
Also, no need to show a GL version if GL isn't available.
2021-07-22 16:27:32 +02:00
Benjamin Otte
e06e0e8555
gdk: Move GL context construction to GdkGLContext
...
Now that we have the display's context to hook into, we can use it to
construct other GL contexts and don't need a GdkSurface vfunc anymore.
This has the added benefit that backends can have different GdkGLContext
classes on the display and get new GLContexts generated from them, so
we get multiple GL backend support per GDK backend for free.
I originally wanted to make this a vfunc on GdkGLContextClass, but
it turns out all the abckends would just call g_object_new() anyway.
2021-07-22 16:27:32 +02:00
Benjamin Otte
9f1d6e1f44
gl: Move vfunc
...
Instead of
Display::make_gl_context_current()
we now have
GLContext::clear_current()
GLContext::make_current()
This fits better with the backends (we can actually implement
clearCurrent on macOS now) and makes it easier to implement different GL
backends for backends (like EGL/GLX on X11).
We also pass a surfaceless boolean to make_current() so the calling code
can decide if a surface needs to be bound or not, because the backends
were all doing whatever, which was very counterproductive.
2021-07-22 16:27:32 +02:00
Benjamin Otte
15ed1a329e
gl: Require EGL_KHR_surfaceless_context with egl
...
The code to create and manage a fake egl surface to bind to is
complex and completely untested because everyone seems to support this
extension.
nvidia and Mesa do support it and according to Mesa devs, adding support
in a new driver is rather simple and Mesa drivers gain that feature
automatically, so all future drivers shoould have it.
2021-07-22 16:27:31 +02:00
Benjamin Otte
505436340b
gdk: Get rid of paint contexts
...
... or more exactly: Only use paint contexts with
gdk_cairo_draw_from_gl().
Instead of paint contexts being the only contexts who call swapBuffer(),
any context can be used for this, when it's used with
begin_frame()/end_frame().
This removes 2 features:
1. We no longer need a big sharing hierarchy. All contexts are now
shared with gdk_display_get_gl_context().
2. There is no longer a difference between attached and non-attached
contexts. All contexts work the same way.
2021-07-22 16:27:31 +02:00
Benjamin Otte
a27434a8a7
gl: Store the context::in-frame state in the current context
...
Do not treat the context as already current when the value
of context::in-frame changes.
This is so we can bind to EGL_NO_SURFACE if context::in-frame == false
and to context::surface if context::in-frame == true.
This allows getting rid of the attached property in future commits.
2021-07-22 16:27:31 +02:00
Benjamin Otte
2c987861a6
gl: Deprecate gdk_gl_context_get_shared_context()
...
It's not used anymore. And in particular we do want to keep the display
context private, so we're not gonna return it from this function.
2021-07-22 16:27:31 +02:00
Benjamin Otte
c7320df0c9
gdk: Add gdk_gl_context_is_shared()
...
... and use it in the GL renderers.
2021-07-22 16:27:31 +02:00
Benjamin Otte
dd666e4fe4
ngl: Store the shared driver in the display
...
... instead of some random GL context.
2021-07-22 16:23:56 +02:00
Benjamin Otte
e4f0418003
gdk: Require EGL version 1.4 across the board
...
Mesa currently ships 1.5.
2021-07-22 16:23:56 +02:00
Benjamin Otte
430b6f8fb1
gdk: Add GdkDisplay::init_gl vfunc
...
The vfunc is called to initialize GL and it returns a "base" context
that GDK then uses as the context all others are shared with. So the GL
context share tree now looks like:
+ context from init_gl
- context1
- context2
...
So this is a flat tree now, the complexity is gone.
The only caveat is that backends now need to create a GL context when
initializing GL so some refactoring was needed.
Two new functions have been added:
* gdk_display_prepare_gl()
This is public API and can be used to ensure that GL has been
initialized or if not, retrieve an error to display (or debug-print).
* gdk_display_get_gl_context()
This is a private function to retrieve the base context from
init_gl(). It replaces gdk_surface_get_shared_data_context().
2021-07-22 16:23:56 +02:00
Benjamin Otte
ba3e80cbfa
wayland: Don't pass GL config to get_egl_surface()
...
There's only one GL config.
2021-07-22 16:23:56 +02:00
Benjamin Otte
7cd4282bad
wayland: Move fbconfig into the display
...
Create it during init and then reuse it for all contexts.
While doing that, also improve error reporting - that's not used yet but
will in later commits.
2021-07-22 16:23:56 +02:00
Benjamin Otte
01e9fa9adb
gdk: Allow GdkDrawContext with a %NULL surface
...
This is not used yet, but it allows surfaceless GL contexts.
For that purpose, we need to make the display a construct-only property,
so that it can be set when the surface isn't.
This adds a bunch of very picky checks in the constructor so nothing bad
can happen.
2021-07-22 16:23:56 +02:00
Benjamin Otte
581e01b2da
gdk: Add a private struct to GdkDisplay
...
... and move some members from the GdkDisplay struct.
We've always wanted to add one to isolate the display from the backends
a bit more, but so far it's never happened.
Now that I'm about to add more data to GdkDisplay, it's a good excuse to
start.
2021-07-22 16:23:56 +02:00
Benjamin Otte
5a3b4de1b7
x11: Redo choice between EGL and GLX
...
We try EGL first, but are very picky about what we accept.
If that fails, we try to go with GLX instead.
And if that also fails, we try EGL again, but this time accept anything.
The idea here is that EGL is the preferred method going forward, but GLX is
the tried and tested method that we know works. So if we detect issues with
EGL, we want to avoid using it in favor of GLX.
Also add a GDK_DEBUG=gl-egl option to force EGL at all costs and not try
GLX.
2021-07-22 16:23:56 +02:00
Benjamin Otte
74288eceaf
x11: Properly record the error when initializing GL
...
That way, we can give a useful error message when things break down for
users.
These error messages could still be improved in places (like looking at
the actual EGL error codes), but that seemed overkill.
2021-07-22 16:23:56 +02:00
Benjamin Otte
37ba057128
x11: Do not call glXQueryExtension()
...
epoxy does that already.
2021-07-22 16:23:56 +02:00
Benjamin Otte
6d5ba9590b
x11: Get Visual from EGL directly
...
Query the EGL_VISUAL_ID from the egl Config and select a config with the
matching Visual.
This is currently broken on Mesa because it does not expose any RGBA
X Visuals in any EGL config, so we always end up with opaque Windows.
https://gitlab.freedesktop.org/mesa/mesa/-/issues/149
2021-07-22 16:23:56 +02:00
Benjamin Otte
215f792851
x11: Store the GLX drawable in the surface
...
Also, stop using a dummy window for unattached GL contexts and instead
use the display's leader surface.
Again, this mirrors EGL.
2021-07-22 16:23:56 +02:00
Benjamin Otte
1c55b32879
x11: Use single GLX fbconfig and store it in the display
...
This mirrors the code for the EGL config.
2021-07-22 16:23:56 +02:00
Benjamin Otte
82eb947f41
x11: Remove glx version check
...
We only work with GLX >= 1.3 anyway, so don't explicitly check for it
and pretend to do something else that doesn't work otherwise.
2021-07-22 16:06:06 +02:00
Benjamin Otte
485dae9f25
x11: Remove unused struct member
...
We don't care if the GL context is direct at all.
2021-07-22 16:06:06 +02:00
Benjamin Otte
eb3423312f
Revert "x11: Always fall back to GLX on NVIDIA"
...
This reverts commit c35a6725b9 .
This approach doesn't work because if NVIDIA doesn't work for EGL, the
EGL implementation won't be provided by NVIDIA, so checking the vendor
doesn't work.
2021-07-22 16:06:06 +02:00
Benjamin Otte
04c2093d5c
x11: Remove the dummy surface
...
Instead, use the display's "leader surface" when no surface is required,
because we have it lying around.
Really, we want to use EGL_NO_SURFACE, but if that's not supported...
2021-07-22 16:06:06 +02:00
Benjamin Otte
ccd5992a83
x11: Remove GdkVisual
...
It's not used anymore.
2021-07-22 16:06:06 +02:00
Benjamin Otte
ca8d9fbe0b
x11: Rework Visual selection
...
Instead of going via GdkVisual, doing a preselection and letting the GL
initialization improve it, let the GL initialization pick an X Visual
directly using X Visual code directly.
The code should select the same visuals as before as it tries to apply
the same logic, but it's a rewrite, so I expect I messed something up.
2021-07-22 16:06:06 +02:00
Benjamin Otte
62bac44a21
glx: Remove Visual cache
...
1. We're using EGL most of the time anyway, so if we wanted to cache
things, we'd need to port it there.
2. Our GL handling is massively configurable, so determining when to use
the cache and when not is a challenge.
3. It makes startup nondeterministic and depend on whether a GTK4 app
has previously been started on this display and nobody thinks about
that when debugging.
4. The only benefit of the caching is delaying GL initialization - which
made sense in GTK3 where almost no app used GL but doesn't make sense
in GTK4 where almost every app uses GL.
So unless I find a big benefit to reintroducing it, this cache will be
gone for good.
2021-07-22 16:06:05 +02:00
Benjamin Otte
0ddd06113d
x11: Move GL init code into the GL context
...
No functional changes, just shuffling code.
2021-07-22 16:06:05 +02:00
Benjamin Otte
b1fbc2ef24
x11: Store the EGL surface in the GdkSurfaceX11
...
Avoids having to use private data, though the benefit is somewhat
limited as we still have to put the destructor in the egl code and can't
just put it in gdk_surface_x11_finalize().
2021-07-22 16:06:05 +02:00
Benjamin Otte
c787fe7ecb
x11: Store the EGL config in the display
...
We only have one config, because we use the same Visual everywhere.
Store this config in the GdkDisplayX11 struct for easy access.
Also do this on initialize, because if creating the config fails, we
want to switch to GLX instead of failing to do GL at all.
This also simplifies a lot of code as we can share Visual, Colormap, etc
across surfaces.
2021-07-22 16:06:05 +02:00
Benjamin Otte
bdb49720be
x11: Move the EGL display into the private struct
...
There's no need to use g_object_set_data() for it.
We can also stop caching it elsewhere because we know the display has
it.
And finally, we can remove the display->have_egl boolean and use
display->egl_display != NULL instead. We initialize the display at
startup, so that variable is the perfect indicator.
2021-07-22 16:06:05 +02:00
Benjamin Otte
1d448a2b8a
x11: Pass the display, not the screen
...
Screens are on their way out.
2021-07-22 16:06:05 +02:00
Benjamin Otte
c5df081904
x11: Simplify code
...
These variables were a lot more important in GTK3, but now we just want
to pass them through to X.
2021-07-22 16:06:05 +02:00
Benjamin Otte
8a2f3e1fe5
x11: Move function call
...
The GLX visual selection is GLX specific, so it can be handled by the GLX
code.
There should be no reordering here, the call was just moved.
2021-07-22 16:06:05 +02:00
Benjamin Otte
8dfc627e46
glx: Don't initialize GLX multiple times.
...
Either it is initialized or it isn't.
2021-07-22 16:06:05 +02:00
Benjamin Otte
0fce30070f
x11: Initialize GL at startup
...
We need to initialize GL to select the Visual we are going to use for
all our Windows.
As the Visual needs to be known before we know if we are even gonna use
GL later, we can't avoid initializing it.
Note that this previously happened, too. It was just hidden behind the
GdkScreen initialization.
2021-07-22 16:06:05 +02:00
Benjamin Otte
8bfe82f686
x11: Don't share cached GLX visuals with GTK3
...
We don't want to bind ourselves to GTK3 - both because we don't want to
accidentally cause bugs in a different codebase and because we want to
deviate from it.
While doing so, also store visuals as visuals and not as integers.
And only store one Visual because GTK4 only uses one visual.
And then remove the code that is leftover for dealing with the
compatibility Visual for GTK3.
PS: I'm kinda proud of my STRINGIFY_WITHOUT_BRACKETS hack.
2021-07-22 16:06:05 +02:00
Benjamin Otte
7d32ec51e7
x11: Reorder code
...
Initialize the GL visuals from gdkdisplay.c so the call into the GL
stack isn't hidden in gdkvisual.c
This is relevant for further commits.
2021-07-22 16:06:05 +02:00
Benjamin Otte
5784f8c2f9
x11: Stop reordering visuals
...
The old code was ordering visuals by depth, but considering that these
days we either use the default visual or a 32bit RGBA visual, that
reordering does not have an effect anymore.
In theory, the only effect is that the GLX Visual selection might select
a different replacement Visual when it checks for improved GL Visuals, but
even there I can't come up with a case where that matters, because
again, the visuals are only reordered by depth and we want to keep the
depth.
In any case, make this a separate commit so bisecting can find this
problem if it ever shows up.
2021-07-22 16:06:05 +02:00
Benjamin Otte
74e01ddec5
x11: Remove unused function
...
Now that we can't create extra GdkX11Screens anymore, this also means
that there is exactly 1 GdkX11Screen per GdkX11Display.
2021-07-22 16:06:05 +02:00
Benjamin Otte
1347573139
x11: Move code where it belongs
...
Instead of the display telling the screen to tell the visuals to tell
the display to initialize itself, just init the display directly.
What a concept.
2021-07-22 16:06:05 +02:00
Benjamin Otte
f2b41e708d
build: Build demos before tools
...
That's a sneaky trick so my edit/compile/test cycle goes faster:
I usually use demos for testing so the tools don't have to be linked for
me to start testing.
2021-07-22 16:06:05 +02:00
Matthias Clasen
a5555943ed
Merge branch 'destroy-pointer-gestures' into 'master'
...
gdk/wayland: Clean up gestures if pointer capability is withdrawn
See merge request GNOME/gtk!3697
2021-07-21 21:33:53 +00:00
Vlad Zahorodnii
2c023cdaed
gdk/wayland: Clean up gestures if pointer capability is withdrawn
...
If the pointer capability is added, pointer swipe and pinch gestures
will be created. However, if the pointer capability is removed, the
gesture objects won't be destroyed.
If the pointer capability is removed and added several times in a row,
for example due to plugging and unplugging physical mouse, this can lead
to leaking the old gesture objects.
In order to prevent that, this change makes the seat destroy swipe and
pinch gestures when the pointer capability is withdrawn.
2021-07-21 20:52:16 +03:00
Matthias Clasen
bcc7028640
Merge branch 'sync-icons' into 'master'
...
Sync included icons from adwaita-icon-theme
See merge request GNOME/gtk!3773
2021-07-21 17:49:15 +00:00
Matthias Clasen
bdee75cd0f
Sync included icons from adwaita-icon-theme
...
Make sure we stay in sync with the Adwaita.
2021-07-20 17:26:59 -04:00
Matthias Clasen
94eb3d7ac0
Merge branch 'wip/otte/build' into 'master'
...
Streamline build configuration
See merge request GNOME/gtk!3391
2021-07-20 18:25:59 +00:00
Benjamin Otte
0ae2acfb1a
x11: Remove XComposite
...
It's only used during DND to allow use of the root window's cow window
as a DND target, because apparently gnome-shell used to think that was a
great idea to DND to the overview.
Somebody complain to gnome-shell devs about it not being a good idea if
they want it fixed.
Potentially using Wayland is a better idea though.
This reverts 85ae875dcb
Related: https://bugzilla.gnome.org/show_bug.cgi?id=601731
2021-07-20 14:00:25 -04:00
Benjamin Otte
afc5f46ca9
x11: Remove unused headers
2021-07-20 14:00:25 -04:00
Benjamin Otte
e544c891ca
build: Make all X11 extensions mandatory
...
It's not 2011 anymore, and we shouldn't randomly build one of 10.000
different combinations of X11 backends (I counted the possibilities) but
exactly the one we expect people to use.
2021-07-20 14:00:25 -04:00
Benjamin Otte
af0c95c11a
build: Remove sassc option
...
Instead, ensure that sassc is made madatory on git builds (because
it is, we don't ship CSS files anymore) and not even looked for in
release builds (because do ship CSS files there).
2021-07-20 14:00:25 -04:00
Benjamin Otte
4d5dc18a57
build: disable Vulkan by default
...
We don't want people to build Vulkan support when they just want to get
GTK built.
This is in particular true for GTK as a CI subproject or for people
using jhbuild.
Worse, just having Vulkan support compiled in tends to cause crashes
in the Inspector, even if you are not using it.
2021-07-20 14:00:25 -04:00
Benjamin Otte
9f6fb161e2
build: Set proper defaults for media backends
...
GTK supports webm playback, which means a backend should always be
compiled.
The ffmpeg backend however is incomplete (no audio) and as such, we
don't want people to end up with it accidentally.
Since we don't want to drag an entire gstreamer build into our ci
on MacOs or msvc, explicitly disable the gstreame media backend there.
2021-07-20 14:00:25 -04:00
Matthias Clasen
3883a98771
Merge branch 'fix-dialog-docs' into 'master'
...
gtk/builder: Port example to GTK 4
See merge request GNOME/gtk!3772
2021-07-20 12:54:55 +00:00
Yuri Chornoivan
9b44965f13
Update Ukrainian translation
2021-07-20 12:08:13 +00:00
Maximiliano Sandoval R
aa6a9de6ba
gtk/builder: Port example to GTK 4
2021-07-20 13:22:08 +02:00
Matthias Clasen
8669e8a498
Merge branch 'tooltip-hig' into 'master'
...
password_entry: Header Capitalization on tooltip
See merge request GNOME/gtk!3771
2021-07-20 11:17:36 +00:00
Maximiliano Sandoval R
ead31db096
password_entry: Header Capitalization on tooltip
...
See https://teams.pages.gitlab.gnome.org/Design/hig-www/feedback/tooltips.html
2021-07-20 13:00:05 +02:00
Matthias Clasen
69fda941c7
Merge branch 'win32.hidpi.cleanup' into 'master'
...
GDK-Win32: Clean up HiDPI support and WGL slightly
Closes #3796
See merge request GNOME/gtk!3767
2021-07-20 02:43:43 +00:00
Matthias Clasen
67c9e7a4a8
Merge branch 'ci-default-settings-4' into 'master'
...
reftests: Enforce default settings
See merge request GNOME/gtk!3769
2021-07-19 18:36:11 +00:00
Matthias Clasen
4e4f57e091
reftests: Enforce default settings
...
Set all settings to their default values, so we
are less dependent on the environment to be set
up just right. In particular, this fixes animations
being disabled when we happen to run in a vm.
2021-07-19 13:26:32 -04:00
Chun-wei Fan
ac64d2d910
GDK-Win32: Clean up HiDPI support and WGL a bit
...
Make _gdk_win32_display_get_monitor_scale_factor() less complex, by:
* Drop the preceding underscore.
* Dropping an unused parameter.
* Using a GdkSurface instead of a HWND, as the HWND that we pass into
this function might have been taken from a GdkSurface, which are now
always created with CS_OWNDC. This means if a GdkSurface was passed
in, we ensure that we only acquire the DC from the HWND once, and do
not attempt to call ReleaseDC() on it.
* Store the HDC that we acquire from the GdkSurface's HWND into the
surface, and use that as the HDC we need for our GdkGLContext.
* Drop the gl_hwnd from GdkWin32Display, as that is really should be
stored in the GdkSurface.
* For functions that were updated, name GdkWin32Display variables as
display_win32 and GdkSurface variables as surface, to unify things.
* Stop calling ReleaseDC() on the HDC that we use for OpenGL, since
they were acquired from HWND's created with CS_OWNDC.
2021-07-19 18:30:42 +08:00
Chun-wei Fan
49a76257cd
gdksurface-win32.c: Create all surfaces with CS_OWNDC
...
We want to ensure that we have things set up properly for drag surfaces
as well.
2021-07-19 17:36:54 +08:00
Matthias Clasen
77829cf3ed
Merge branch 'pango-main' into 'master'
...
Use pango from the main branch
See merge request GNOME/gtk!3762
2021-07-17 13:05:42 +00:00
Yuri Chornoivan
4d10ab3d35
Update Ukrainian translation
2021-07-17 05:34:21 +00:00
Matthias Clasen
e609ede597
Use pango from the main branch
...
Change the Pango subproject to use the main branch.
This depends on
https://gitlab.gnome.org/GNOME/pango/-/merge_requests/379
2021-07-16 13:19:22 -04:00
Benjamin Otte
2ba69abe39
Merge branch 'wip/otte/for-master' into 'master'
...
cssimagecrossfade: Don't abort() when failing to parse image
Closes #4101
See merge request GNOME/gtk!3758
2021-07-16 16:26:23 +00:00
Benjamin Otte
a76f515569
cssimagecrossfade: Don't abort() when failing to parse image
...
The code wasn't checking if parsing an image failed and just returning
success.
Testcase from bug is attached.
Fixes #4101
2021-07-16 17:50:09 +02:00
Matthias Clasen
a663b8c313
Merge branch 'fix-negative-scales' into 'master'
...
ngl: Handle negative scales
Closes #4096
See merge request GNOME/gtk!3755
2021-07-16 11:59:47 +00:00
Matthias Clasen
f66fa16bd1
Merge branch 'metainfo' into 'master'
...
metadata: Fix license identifiers and appdata
See merge request GNOME/gtk!3757
2021-07-16 11:14:09 +00:00
Matthias Clasen
8390363abe
testsuite: Avoid negative scales with gl renderer
...
The fix in 1c90bb522e was only for the ngl renderer,
so don't use the test with the gl renderer, until it is
fixed as well.
2021-07-16 07:11:20 -04:00
Matthias Clasen
6ff85d287a
Merge branch 'wip/chergert/fix-texthistory-insert' into 'master'
...
texthistory: fix calculation of n_chars
See merge request GNOME/gtk!3756
2021-07-16 11:04:21 +00:00
Maximiliano Sandoval R
94c2072be8
meson: Use a valid SPDX identifier
...
See https://mesonbuild.com/Reference-manual.html#license
2021-07-16 11:14:46 +02:00
Maximiliano Sandoval R
64b9d53472
appdata: Use launchable rather than id
...
<id> should be used for the component id and <launchable> for the
desktop file.
2021-07-16 11:14:46 +02:00
Maximiliano Sandoval R
a5e7b92c5d
appdata: Add content_rating
...
https://www.freedesktop.org/software/appstream/docs/chap-Metadata.html#tag-content_rating
2021-07-16 11:14:42 +02:00
Maximiliano Sandoval R
2da9ba63e2
appdata: Use correct SPDX license identifier
...
Following
https://www.freedesktop.org/software/appstream/docs/chap-Metadata.html#tag-project_license ,
for the complete list of identifiers see https://spdx.org/licenses/
2021-07-16 11:09:28 +02:00
Christian Hergert
5d02a8f5db
texthistory: fix calculation of n_chars
...
This should be the number of characters, not the end position. This fixes
an issue where we wouldn't coalesce insert actions together.
2021-07-15 21:26:30 -07:00
Benjamin Otte
834d3749c6
testsuite: Add test for crasher
...
Test for the crasher in !4096
2021-07-15 23:43:28 +02:00
Matthias Clasen
1c90bb522e
ngl: Handle negative scales
...
Scale factors can be negative, but we were not
looking out for that, triggering an assertion when
trying to create a render target with negative
width of height. Avoid that.
Fixes : #4096
2021-07-15 16:40:13 -04:00
Matthias Clasen
b70b058b66
Merge branch 'transparent-optimizations' into 'master'
...
snapshot: Handle transparent opacity nodes correctly
See merge request GNOME/gtk!3754
2021-07-15 18:39:48 +00:00
Matthias Clasen
b99beeb552
Merge branch 'wip/baedert/for-master' into 'master'
...
snapshot: Replace trivial gradients with color nodes
See merge request GNOME/gtk!3753
2021-07-15 18:31:22 +00:00
Matthias Clasen
c799452973
ngl: Do nothing for transparent text nodes
...
Like the previous commit - a transparent text node
will not produce any visible pixels, so bail out early.
2021-07-15 13:18:23 -04:00
Matthias Clasen
fd48afb77d
ngl: Do nothing for transparent color nodes
...
No need to send commands to the GPU to render transparency.
2021-07-15 13:18:23 -04:00
Matthias Clasen
aaa68954c3
snapshot: Handle transparent opacity nodes correctly
...
Eliding totally transparent content from the node tree is
not 100% correct, since filters can make things visible, so
we need to at least preserve the bounds. We can do that by
creating a transparent color node.
2021-07-15 13:18:23 -04:00
Timm Bäder
433233258b
snapshot: Only compute start and end point if we have to
...
If the linear gradient results in a color node, we don't need the start
and end point. Only declare and compute it if we need to.
2021-07-15 16:52:38 +02:00
Timm Bäder
3eed61deba
snapshot: Replace trivial gradients with color nodes
...
Extend this to all existing gradient types
2021-07-15 16:51:17 +02:00
Matthias Clasen
87e2a02e0c
composetable: Rewrite Compose files if necessary
...
Apply heuristics to avoid breaking users existing configurations
with the change to not always add the default sequences.
If we find a cache that was generated before 4.4, and the Compose
file does not have an include, and doesn't contain so many sequences
that it is probably a copy of the system one, we take steps to keep
things working, and thell the user about it.
2021-07-15 09:30:09 -04:00
Matthias Clasen
264d592012
composetable: Keep the number of sequences
...
And print it out in tests.
Update all tests for this.
2021-07-15 09:30:01 -04:00
Matthias Clasen
0ad5094119
Remove some leftover debug code
2021-07-15 09:30:01 -04:00
Benjamin Otte
67952a9142
Merge branch 'wip/otte/for-master' into 'master'
...
rendernodeparser: Don't use %g when writing file
See merge request GNOME/gtk!3752
2021-07-14 18:46:36 +00:00
Benjamin Otte
ca3d942b9b
rendernodeparser: Remove leftover debug prints
2021-07-14 20:19:40 +02:00
Benjamin Otte
5470a1344d
rendernodeparser: Don't use %g when writing file
...
%g is locale dependent and can add "," where "." should be. Use
string_append_double() instead.
2021-07-14 20:18:44 +02:00
Matthias Clasen
4390f8102b
imcontext: Improve the docs
...
Add more details about supported input methods.
2021-07-13 22:03:23 -04:00
Matthias Clasen
92129a2011
imcontext: Simplify checking compose seqs
...
Add the builtin table to the list of tables, and
remove the duplicated code that checks builtin
sequences separately.
2021-07-13 22:03:23 -04:00
Matthias Clasen
54dffa07f3
composetable: Drop GtkComposeTableCompact
...
All tables use the compact format now, and we generate
caches in that format too. Bump the cache version to 3
for this.
Replace the python script for generating the builtin table
by a small C program using the same code to generate the data
for the builtin table. This drops the restriction on only
generating a single character in the builtin sequences.
2021-07-13 22:03:23 -04:00
Matthias Clasen
1cff4bb27a
composetable: Ignore length 1 sequences
...
It turns out that the X11 Compose file has some
length 1 sequences which are not interesting to us.
2021-07-13 22:02:33 -04:00
Matthias Clasen
8087250476
imcontext: Replace the builtin sequences
...
When we find a Compose file, replace the builtin
sequences with the table we found. This matches the
semantics described in Compose(5), and makes it possible
to drop unwanted sequences from the builtin table.
It is slight change of behavior for users with existing
Compose files. To match the previous behavior, you have
to add
include "%L"
to your Compose file, to keep the builtin sequences in
addition to your own.
2021-07-13 22:02:33 -04:00
Matthias Clasen
485dc052ca
composetable: Allow removing sequences
...
Interpret an empty string as value in the Compose
file to mean: Remove this sequence.
Tests included.
2021-07-13 22:02:33 -04:00
Matthias Clasen
45d39c2802
composetable: Switch to using a hash table
...
This lets us naturally replace matching sequences
while parsing. That means that the semantics are now
"last one wins" if the parser sees multiple entries
for the same sequence.
Add a testcase that checks the new replacement semantics.
2021-07-13 22:02:33 -04:00
Matthias Clasen
3b4b1c6878
composetable: Reinterpret %L
...
When we see include "%L" in a Compose file, use the
builtin sequences. We no longer filter out duplicates
wrt. to the builtin sequences.
2021-07-13 22:02:33 -04:00
Matthias Clasen
ff4f07d76f
composetable: Handle substitutions in includes
...
Hande the %H, %L, %S substitutions that are described
in Compose(7).
Test included.
2021-07-13 22:02:33 -04:00
Matthias Clasen
fb6c8cd466
composetable: Handle includes
...
This adds the mechanics for parsing include lines in
Compose files. We do detect and prevent cycles.
Tests included.
2021-07-13 22:02:33 -04:00
Matthias Clasen
8464b0484f
composetable: Move code into the parser
...
This is just code reshuffling.
2021-07-13 22:02:33 -04:00
Matthias Clasen
bee58fd09d
composetable: Introduce a parser struct
...
This will be used in the following commits to
beef up Compose file parsing.
2021-07-13 22:02:33 -04:00
Matthias Clasen
d25557a5ef
Clean up the GtkComposeTable api
...
Keep the list of composetables private to GtkIMContextSimple,
and just have an api that creates new GtkComposeTables, either
from a file or from data.
Update tests to use the new api.
2021-07-13 22:02:33 -04:00
Matthias Clasen
da3ca6604b
gtk-demo: Add a slider to the menu example
...
This is a fun way to show that we can scale fast.
2021-07-13 22:02:33 -04:00
Matthias Clasen
74cba6c3b2
Add a simple Javascript example
...
This shows how to use a layout manager in a widget,
implemented in javascript. The example sets up the
environment for running from the toplevel dir, assuming
that the build dir is called 'build'.
2021-07-13 22:02:33 -04:00
Emmanuele Bassi
c09718b731
Merge branch 'doc-fixes' into 'master'
...
doc: Syntax fixes
See merge request GNOME/gtk!3751
2021-07-13 23:43:06 +00:00
Marco Melorio
eacfa2a966
doc: Syntax fixes
2021-07-13 22:53:19 +00:00
Matthias Clasen
e7f228e240
Merge branch 'fp16-tests' into 'master'
...
ngl: Make the C half-float implementation accessible
See merge request GNOME/gtk!3748
2021-07-13 13:38:21 +00:00
Matthias Clasen
fab82a7c25
tests: Add some fp16 tests
2021-07-13 09:03:49 -04:00
Matthias Clasen
fc9c34897a
ngl: Make the C half-float implementation accessible
...
Make this accessible for tests.
2021-07-13 09:03:49 -04:00
Emmanuele Bassi
28cdd3f497
Merge branch 'gi-fixes' into 'master'
...
Various introspection fixes
See merge request GNOME/gtk!3747
2021-07-13 11:21:20 +00:00
Marc-André Lureau
a009e26e95
gtk: fix GtkPasswordEntryBuffer introspection
...
Move the source file to public_sources list, and fix tag annotation.
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com >
2021-07-13 15:03:09 +04:00
Marc-André Lureau
ab908c23f4
Add GtkMenuButton:primary Since: annotation
...
Property added in commit a74420bc1a .
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com >
2021-07-13 11:31:09 +04:00
Marc-André Lureau
ae21f66fe5
Add GTK_DEBUG_ICONFALLBACK Since: 4.2 annotation
...
Introduced in commit 6f82408056 .
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com >
2021-07-13 11:26:39 +04:00
Rafael Fontenelle
2d092ea280
Update Brazilian Portuguese translation
...
(cherry picked from commit c7a7fc4de6 )
2021-07-10 19:30:32 +00:00
Rafael Fontenelle
0f9d39cdfd
Update Brazilian Portuguese translation
...
(cherry picked from commit 72c3026764 )
2021-07-10 17:14:31 +00:00
Matthias Clasen
a64087d481
Merge branch 'activatable-buttons' into 'master'
...
menubutton: Make menu buttons activatable again
Closes #4079
See merge request GNOME/gtk!3728
2021-07-10 12:59:39 +00:00
Matthias Clasen
c85f3f4942
Merge branch 'wip/chergert/fix-4094' into 'master'
...
joinedmenu: add helper to join menus instead of nesting
Closes #4094
See merge request GNOME/gtk!3739
2021-07-09 19:29:41 +00:00
Matthias Clasen
d7553279ff
Merge branch 'gdkkeys-m' into 'master'
...
[master] gdkkeys-win32.c: fix initialisation of key_state in update_keymap
See merge request GNOME/gtk!3742
2021-07-09 10:58:23 +00:00
Matthias Clasen
c86631b8a9
Merge branch 'dynamic-typelib-path' into 'master'
...
build: Get typelib dir dynamically using gobject-introspection dependency
See merge request GNOME/gtk!3737
2021-07-09 10:57:37 +00:00
Matthias Clasen
c1af63de9b
Merge branch 'invisible-char-fix' into 'master'
...
textbtree: Initialize to zero the tags counting array
See merge request GNOME/gtk!3740
2021-07-09 10:56:51 +00:00
Jeremy Tan
2784b03b2d
gdkkeys-win32.c: fix initialisation of key_state in update_keymap
...
It apparently worked by chance in the past, but now causes e.g.
alphanumeric characters to be interpreted as half-width katakana
when using the Japanese IME.
2021-07-09 12:46:49 +08:00
Marco Trevisan (Treviño)
10bdf8c645
textbtree: Initialize to zero the tags counting array
...
We're using the tag contents array to count the number of invisible tags
set but we always increase it without being initialized.
This may lead to unexpected behavior when traversing them and it's
causing a reliable failure in the textiter tests under s390x.
So, memset that area content to 0 once allocated. It's not needed to do
the same for the tags themselves as we always assign them.
Conditional jump or move depends on uninitialised value(s)
at 0x4CFAA00: _gtk_text_btree_char_is_invisible (gtktextbtree.c:2569)
by 0x4B8A1BB: find_visible_by_log_attrs (gtktextiter.c:3244)
by 0x10E93D: check_backward_visible_word_start (textiter.c:484)
by 0x10E93D: test_visible_word_boundaries (textiter.c:523)
by 0x533288F: g_test_run_suite (in /usr/lib/s390x-linux-gnu/libglib-2.0.so.0)
by 0x53328E7: g_test_run (in /usr/lib/s390x-linux-gnu/libglib-2.0.so.0)
by 0x109CC1: main (textiter.c:807)
2021-07-09 03:48:40 +02:00
Christian Hergert
d63d9b2319
joinedmenu: add helper to join menus instead of nesting
...
In many cases, we have an "extra-menu" property that is used to allow
applications to join menus into the native menu for the widget. Previously,
this was done by nesting that menu in a section.
Doing so increases the complexity of the rules for GtkMenuTracker as you
may want different handling from inside of the section vs toplevel
sections.
If instead we synthetically glue the menus together, we have a much more
natural joining of menus as the application developer would expect for
their menu.
This also ports GtkLabel, GtkText, GtkPasswordEntry, and GtkTextView to
use the joined menu helper.
The joined menu helper comes originally from GNOME Builder and has had
extensive use there.
Fixes #4094
2021-07-08 14:16:06 -07:00
Marco Trevisan (Treviño)
d5f2b69d0c
build: Get typelib dir dynamically using gobject-introspection dependency
...
We hardcoded the typelib directory for only an arch (and a distro),
while we can just get it from gobject-introspection pkg config if tests
are enabled.
2021-07-08 04:59:10 +02:00
Matthias Clasen
6818eee859
Merge branch 'wip/exalm/scroll-touch' into 'master'
...
scrolledwindow: Don't check drag threshold when already scrolling
See merge request GNOME/gtk!3735
2021-07-07 21:37:58 +00:00
Matthias Clasen
e7f1398d85
Merge branch 'text-cursor-extents' into 'master'
...
text: Add API to compute cursor extents
See merge request GNOME/gtk!3734
2021-07-07 21:37:14 +00:00
Matthias Clasen
880c01f8cc
Merge branch 'wl-since' into 'master'
...
Add missing "Since: 4.X" doc tags
See merge request GNOME/gtk!3736
2021-07-07 21:36:13 +00:00
Marc-André Lureau
337c5e5e59
Add missing "Since: 4.X" tags
...
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com >
2021-07-07 23:35:38 +04:00
Florian Müllner
af52ea78c6
text: Add API to compute cursor extents
...
The extents that correspond to the strong/weak cursor at a given
character position can be used for example to point a popover to
text in the widget.
2021-07-07 19:33:12 +02:00
Alexander Mikhaylenko
fe633d9ef9
scrolledwindow: Don't check drag threshold when already scrolling
...
Checkout the drag threshold only makes sense when starting a scroll, after
that it just adds jumps when trying to scroll back and forth.
2021-07-07 19:39:06 +05:00
Matthias Clasen
e6cce283a7
Merge branch 'matthiasc/for-master' into 'master'
...
gtk-demo: Add a slider to the menu example
See merge request GNOME/gtk!3733
2021-07-06 00:23:30 +00:00
Matthias Clasen
c920236c54
gtk-demo: Add a slider to the menu example
...
This is a fun way to show that we can scale fast.
2021-07-05 19:31:54 -04:00
Matthias Clasen
6f86b4d220
Merge branch 'js-example' into 'master'
...
Add a simple Javascript example
See merge request GNOME/gtk!3731
2021-07-05 20:24:30 +00:00
Matthias Clasen
a085e174c5
Merge branch 'wip/remove-cloudprint' into 'master'
...
Remove Google Cloud Print backend
See merge request GNOME/gtk!3729
2021-07-05 20:21:52 +00:00
Florentina Mușat
d3c08789a3
Update Romanian translation
...
(cherry picked from commit 6ff90954dc )
2021-07-05 20:02:15 +00:00
Florentina Mușat
630488210b
Update Romanian translation
...
(cherry picked from commit e5bd6312be )
2021-07-05 19:47:50 +00:00
Matthias Clasen
873f6ccfea
Add a simple Javascript example
...
This shows how to use a layout manager in a widget,
implemented in javascript. The example sets up the
environment for running from the toplevel dir, assuming
that the build dir is called 'build'.
2021-07-05 13:48:51 -04:00
Patrick Griffis
af15f5d004
Remove Google Cloud Print backend
...
This service was shut down at the start of 2021.
This helpfully removes any dependency on json-glib, librest (and libsoup).
2021-07-05 10:54:16 -05:00
Matthias Clasen
f328175e2f
appchooserbutton: Make buttons activatable again
...
The activation is simply forwarded to the combobox
within.
2021-07-05 10:10:44 -04:00
Matthias Clasen
fc65d6393a
colorbutton: Make color buttons activatable again
...
The activation is simply forwarded to the toggle button
within.
2021-07-05 10:10:19 -04:00
Matthias Clasen
271afb7eab
font button: Make font buttons activatable again
...
The activation is simply forwarded to the toggle button
within.
2021-07-05 10:09:43 -04:00
Matthias Clasen
76133dbea7
menubutton: Make menu buttons activatable again
...
The activation is simply forwarded to the toggle button
within.
Fixes : #4079
2021-07-05 10:08:43 -04:00
Matthias Clasen
6efe31e6f5
Merge branch 'master' into 'master'
...
gdk: fix gtk app startup with 'g_value_set_boxed: assertion...
See merge request GNOME/gtk!3714
2021-07-05 02:45:54 +00:00
Matthias Clasen
9885bedb7d
Merge branch 'matthiasc/for-master' into 'master'
...
widget-factory: Add a default button
Closes #3975
See merge request GNOME/gtk!3725
2021-07-04 13:46:13 +00:00
Matthias Clasen
b6edb517e4
Merge branch 'placeholder-visibility' into 'master'
...
text: Update placeholder visibility more often
Closes #4066
See merge request GNOME/gtk!3724
2021-07-04 03:14:38 +00:00
Matthias Clasen
f023695f31
docs: Fix various link formatting
...
Make links that gi-docgen can undestand.
Fixes : #3975
2021-07-03 23:11:48 -04:00
Matthias Clasen
749ea8c30c
widget-factory: Add a default button
...
Mark one of the buttons in the message dialog
as default, so we can see how the default appears
visually.
2021-07-03 23:01:14 -04:00
Matthias Clasen
c79f289d67
text: Update placeholder visibility more often
...
We need to update the visibility of the placeholder
label when we create it, otherwise we can end up
with placeholder text on top of entry content.
Fixes : #4066
2021-07-03 22:15:38 -04:00
Matthias Clasen
e516ce428a
Merge branch 'fix-filechooser-critical' into 'master'
...
filechooser: Avoid a critical
Closes #4077
See merge request GNOME/gtk!3722
2021-07-03 21:48:41 +00:00
Matthias Clasen
1ae259aecb
Merge branch 'man-page-improvement' into 'master'
...
docs: Improve the gtk4-launch man page
Closes #4081
See merge request GNOME/gtk!3723
2021-07-03 19:51:39 +00:00
Matthias Clasen
c609e2fef9
docs: Improve the gtk4-launch man page
...
Be more precise about where desktop files are found.
Fixes : #4081
2021-07-03 15:23:36 -04:00
Matthias Clasen
8ff9c851ce
filechooser: Avoid a critical
...
This was showing up when calling some filechooser api on
a native filechooser, where we use a filechooser dialog
behind the scenes, but it does not have focus.
Fixes : #4077
2021-07-03 15:15:06 -04:00
Matthias Clasen
5ef2b9fd54
Merge branch 'matthiasc/for-master' into 'master'
...
Cosmetics
See merge request GNOME/gtk!3721
2021-07-03 13:40:23 +00:00
Matthias Clasen
511dc7a182
Merge branch 'fix-gir' into 'master'
...
meson: Fix generate_gir() dependencies
See merge request GNOME/gtk!3701
2021-07-03 13:35:22 +00:00
Matthias Clasen
c668586caf
Merge branch 'scrolling-menus' into 'master'
...
popovermenu: Scroll when necessary
See merge request GNOME/gtk!3717
2021-07-03 13:31:23 +00:00
Benjamin Otte
390447862a
Merge branch 'rerename-mediastream' into 'master'
...
mediastream: Rename apis one more time
See merge request GNOME/gtk!3720
2021-07-03 13:28:35 +00:00
Matthias Clasen
7f2648a013
Cosmetics
...
Amend LD_PRELOAD instead of replacing it, so you can just
point it at the right libgtk-4.so while running squares.py
from elsewhere.
2021-07-03 09:10:27 -04:00
Matthias Clasen
3227aa2c45
mediastream: Rename apis one more time
...
Before we end up with names that we are unhappy with,
rename things one more time, and update all callers.
2021-07-03 09:05:33 -04:00
Matthias Clasen
c88dc98b7c
Merge branch 'python-example' into 'master'
...
Add a simple python example
See merge request GNOME/gtk!3719
2021-07-03 02:03:16 +00:00
Matthias Clasen
ed5b42071c
Add a simple python example
...
This shows how to do custom drawing in a widget,
implemented in python. The example sets up the
environment for running from the toplevel dir,
assuming that the build dir is called 'build'.
2021-07-02 21:31:32 -04:00
Matthias Clasen
804d9ee828
popovermenu: Scroll when necessary
...
Add a scrolled window to GtkPopoverMenu, so we can scroll
long menus when there is not enough room.
2021-07-02 13:19:02 -04:00
Matthias Clasen
a90f721b74
Merge branch 'wip/baedert/wat' into 'master'
...
gtkffmediafile: Fix deprecated API usage
See merge request GNOME/gtk!3716
2021-07-02 17:00:41 +00:00
Timm Bäder
106417ada7
gtkffmediafile: Fix deprecated API usage
2021-07-02 18:41:55 +02:00
hudeng
fd0d3283e0
gdk: fix gtk app startup with 'g_value_set_boxed: assertion G_VALUE_HOLDS_BOXED (value) failed error message' when xsettings use 'XSETTINGS_TYPE_COLOR' type
2021-07-02 17:23:56 +08:00
Matthias Clasen
3e63e683a9
Merge branch 'text-undo-test' into 'master'
...
Add another text history test
See merge request GNOME/gtk!3713
2021-07-01 22:25:18 +00:00
Matthias Clasen
e415f25c8f
Add another text history test
...
Add a tests that checks we group undo actions as expected
when the user is typing.
2021-07-01 18:08:05 -04:00
Matthias Clasen
e596e1fa7d
Merge branch 'wip/chergert/fix-texthistory-grouping' into 'master'
...
texthistory: hoist single actions from group
Closes gnome-text-editor#97
See merge request GNOME/gtk!3711
2021-07-01 14:17:25 +00:00
Christian Hergert
d8ab2e6d03
texthistory: hoist single actions from group
...
In many cases across GtkTextBuffer, we end up with operations performed
inside of a begin/end user action. Those can be coalesced into a single
sub-action within the group, and hoisted out of the group. Doing so
increases the chances that we chain similar actions together for words.
Additionally, this fixes an issue introduced in
6179886b14 for #3977 where GNOME Text Editor
started to group all possible actions into a single group.
Fixes GNOME/gnome-text-editor#97
2021-06-30 16:40:54 -07:00
Benjamin Otte
e9d3d3e3cf
icontheme: Fix binding annotation
2021-06-30 18:55:25 +00:00
Matthias Clasen
3a5983e387
Merge branch 'wayland-cursor-theme' into 'master'
...
wayland: Look for cursor themes in $HOME
Closes #4080
See merge request GNOME/gtk!3708
2021-06-29 22:17:49 +00:00
Matthias Clasen
4efb661ae6
wayland: Look for cursor themes in $HOME
...
We should look in the same places that libXcursor does,
so add $XDG_DATA_HOME/icons and $HOME/.icons to the list.
Fixes : #4080
2021-06-29 16:57:15 -04:00
Matthias Clasen
bcdb9c937c
Merge branch 'more-vbo-overflow' into 'master'
...
gsk: Use the right limit for batch size
See merge request GNOME/gtk!3707
2021-06-29 20:36:42 +00:00
Matthias Clasen
f45c0b9609
gsk: Another vbo_size overflow fix
...
We can overflow vbo_size not just by batching
too much, but also by producing humongous text
nodes. Split them up.
2021-06-29 15:22:40 -04:00
Matthias Clasen
9ea162034a
gsk: Use the right limit for batch size
...
We use 16 bits, so G_MAXINT16 is one bit short.
Just make it explicit as 0xffff.
2021-06-29 15:21:45 -04:00
Matthias Clasen
192e779db2
Merge branch 'hello-world-fixup' into 'master'
...
Update hello-world.c
See merge request GNOME/gtk!3706
2021-06-29 16:59:45 +00:00
Matthias Clasen
bda7557783
Update hello-world.c
...
Simplify the code a bit and make the window
match the existing screenshot.
2021-06-29 08:01:37 -04:00
Matthias Clasen
dc50c7539a
Merge branch 'avoid-batch-size-overflow' into 'master'
...
Revert "gsk: Respect max element vertices limitation"
See merge request GNOME/gtk!3704
2021-06-28 21:35:15 +00:00
Matthias Clasen
bf97dfd998
Merge branch 'wip/exalm/buttons' into 'master'
...
GtkMenuButton icon+arrow support + fixes
Closes #3501
See merge request GNOME/gtk!3694
2021-06-28 19:10:57 +00:00
Matthias Clasen
c7f4131402
Merge branch 'gtklistitemfactory-autocleanup' into 'master'
...
gtk: Define the GtkListItemFactory autocleanup func
See merge request GNOME/gtk!3703
2021-06-28 19:10:04 +00:00
Matthias Clasen
bd5e5beee0
gsk: Don't overflow vbo_count
...
We use 16 bits to store vbo_count, so we can't create
batches that have more than 65535 vertices. Pay attention
to that limit when merging batches.
2021-06-28 15:00:41 -04:00
Matthias Clasen
7a493f151d
Revert "gsk: Respect max element vertices limitation"
...
This reverts commit f58fc6b22e .
2021-06-28 14:50:58 -04:00
Adrien Plazas
0ea73c384f
gtk: Define the GtkListItemFactory autocleanup func
2021-06-28 14:01:57 +02:00
Emmanuele Bassi
d8c416e8b2
Merge branch 'ebassi/issues-4076' into 'master'
...
docs: Use code blocks for inline XML
Closes #4076
See merge request GNOME/gtk!3702
2021-06-27 15:10:15 +00:00
Emmanuele Bassi
9bf3724d25
docs: Use code blocks for inline XML
...
Otherwise the markdown renderer will just ignore them.
Fixes : #4076
2021-06-27 15:25:18 +01:00
Hugo Carvalho
fd49d39184
Update Portuguese translation
...
(cherry picked from commit a9c68757b5 )
2021-06-27 09:45:19 +00:00
Xavier Claessens
0fd790eb8d
Meson: Only g-ir-scanner warnings fatal when buit with -Dwerror=true
...
Also fix deprecation warning that requires using fatal_warnings kwarg
from Meson 0.55.0.
Fixes : #4072 .
2021-06-25 11:38:11 -04:00
Xavier Claessens
b18e95d6b3
meson: Fix generate_gir() dependencies
...
There is no need to search for gir variables into subprojects, they are
part of dependencies objects, meson will find them there.
2021-06-25 10:08:36 -04:00
Alexander Mikhaylenko
47b5c68df4
menubutton: Don't hardcode label<->arrow spacing
...
This should come from the theme instead, as it does for icon<->arrow.
2021-06-24 23:13:01 +05:00
Alexander Mikhaylenko
ac3b246858
menubutton: Add a way to always show arrow with image buttons
...
Make sure the button still has the .image-button style class with an icon,
also add it to the initial state with only an arrow. Add a new
.arrow-button style class for the icon+arrow state so it's possible to
style it.
Remove spacing from the label+arrow variant to match, re-add it from the
stylesheet for both.
Fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/3501
2021-06-24 23:12:26 +05:00
Alexander Mikhaylenko
51a754547e
menubutton: Remove a random g_return_if_fail()
...
There's already one above.
2021-06-24 23:11:57 +05:00
Alexander Mikhaylenko
76df60db2b
menubutton: Reset label when setting icon name and vice versa
...
Match GtkButton.
2021-06-24 23:06:46 +05:00
Alexander Mikhaylenko
f3befe530b
button: Reset style classes when setting arbitrary children
...
Don't leave leftover .image-button or .text-button.
2021-06-24 23:06:46 +05:00
Matthias Clasen
59d4333e23
Merge branch 'wip/sadiq/reveal-controls-on-touch' into 'master'
...
video: Reveal controls on tap
See merge request GNOME/gtk!3648
2021-06-24 15:11:33 +00:00
Matthias Clasen
92177d9663
Merge branch 'wip/chergert/gdk-macos-gdkdrop' into 'master'
...
GdkDrop suport for macOS backend
See merge request GNOME/gtk!3683
2021-06-24 15:03:19 +00:00
Matthias Clasen
6a29b64850
Merge branch 'dnd-fixes' into 'master'
...
dnd: Add another assertion
See merge request GNOME/gtk!3689
2021-06-24 15:01:29 +00:00
Matthias Clasen
73cb60d053
Merge branch 'ebassi/filechooser-no-trash' into 'master'
...
Never show the Trash in the FileChooserWidget side bar
Closes #674
See merge request GNOME/gtk!3692
2021-06-24 14:59:43 +00:00
Matthias Clasen
47bd998e94
Merge branch 'checkbutton-release-outside' into 'master'
...
checkbutton: Match GtkButton behavior
Closes #4061
See merge request GNOME/gtk!3691
2021-06-24 14:58:42 +00:00
Matthias Clasen
e2cfa7bd11
Merge branch 'fix_tests_testdnd' into 'master'
...
make testdnd trashcan work again
See merge request GNOME/gtk!3700
2021-06-24 14:54:32 +00:00
Matthias Clasen
006633082d
Merge branch 'macos-input-method' into 'master'
...
macos: fix the position of curosr of input method for macos.
Closes #4063
See merge request GNOME/gtk!3699
2021-06-24 14:50:59 +00:00
Caolán McNamara
bbf7454fc9
make testdnd trashcan work again
...
so that dragging into the 'trashcan' is detected
2021-06-23 15:09:44 +01:00
Emmanuele Bassi
85cb5509c4
Merge branch 'gtklistitem-autocleanup' into 'master'
...
gtk: Define the GtkListItem autocleanup func
See merge request GNOME/gtk!3698
2021-06-23 13:09:28 +00:00
Emmanuele Bassi
0e29f52841
Merge branch 'migration_patch' into 'master'
...
Add section about `gtk_widget_set_app_paintable`
Closes #4007
See merge request GNOME/gtk!3641
2021-06-23 13:08:07 +00:00
Jaap aarts
02893e37d3
Add section about gtk_widget_set_app_paintable
2021-06-23 13:08:06 +00:00
Zhi
1dbb5188ba
macos: fix the position of curosr of input method for macos.
...
In the refactoring from GdkWindow to GdkSurface, GtkWidget no longer
corresponds to a GdkSurface. We have to calculate the relative position
from GtkWidget to the GdkSurface.
Closes #4063 .
2021-06-22 22:57:34 +08:00
Adrien Plazas
a4d35ace78
gtk: Define the GtkListItem autocleanup func
2021-06-22 09:43:16 +02:00
Carlos Garnacho
981a638b01
Merge branch 'fix-pointer-gestures-kde-plasma' into 'master'
...
gdk/wayland: Fix pointer-gestures version selection
See merge request GNOME/gtk!3693
2021-06-21 21:35:06 +00:00
Vlad Zahorodnii
3969d8b028
gdk/wayland: Fix pointer-gestures version selection
...
version == GDK_ZWP_POINTER_GESTURES_V1_VERSION will fail if the
compositor implements version 2 of pointer-gestures-v1.
2021-06-21 09:51:45 +03:00
Emmanuele Bassi
889709213e
Never show the Trash in the FileChooserWidget side bar
...
The Trash is a special location: files cannot be copied or moved, there,
and the file selection dialog is not able to restore files from the
Trash.
Fixes : #674
2021-06-20 15:44:22 +01:00
Emmanuele Bassi
333a92bcff
Revert "Never show the Trash in the FileChooserWidget side bar"
...
This reverts commit cd39e417e1 .
2021-06-20 15:41:43 +01:00
Emmanuele Bassi
cd39e417e1
Never show the Trash in the FileChooserWidget side bar
...
The Trash is a special location: files cannot be copied or moved, there,
and the file selection dialog is not able to restore files from the
Trash.
Fixes : #674
2021-06-20 15:39:41 +01:00
Matthias Clasen
1cebf406aa
docs: Fix a typo
2021-06-19 14:14:57 -07:00
Matthias Clasen
d7915fbca8
docs: Add a section about Drag-and-Drop
2021-06-19 14:14:57 -07:00
Matthias Clasen
9169315cc1
Merge branch 'wip/chergert/textview-access-to-contexts' into 'master'
...
textview: give application developers access to RTL and LTR context
See merge request GNOME/gtk!3690
2021-06-19 20:36:44 +00:00
Matthias Clasen
3b70cd3226
checkbutton: Match GtkButton behavior
...
When leaving the widget before releasing the button,
we should not activate the checkbutton, to match the
way GtkButton behaves.
Fixes : #4061
2021-06-19 13:30:31 -07:00
Christian Hergert
a6101f0181
textview: give application developers access to RTL and LTR context
...
This allows developers to modify the pango context that is used when
rendering text within the text view.
Such access can be useful to alter how rounding occurs with API such as
pango_context_set_round_glyph_positions() and is needed by GtkSourceView
for proper placement of glyphs within the overview map.
2021-06-19 12:28:18 -07:00
Matthias Clasen
92c6485adf
docs: Tweak wording
...
Instead of drag'n'drop, say drag-and-drop. That is easier
to read, and less unclear on the markdown syntax implications.
2021-06-19 08:03:47 -07:00
Matthias Clasen
4df9314039
wayland: Fix some dnd corner case
...
We must call gdk_drag_drop_done() when the drag ends,
successfully or not. Without this, we get an unwarranted
emission of ::cancel after a successful drop.
Since only the first call to gdk_drag_drop_done() is taking
effect, it is safe to call as a fallback, after emitting
::dnd-finished. If the application connects to that signal
and calls gdk_drag_drop_done() itself, its call will take
precedence.
This matches what the X11 implementation does.
2021-06-19 08:03:21 -07:00
Matthias Clasen
c8ad4d5deb
dnd: Add another assertion
...
Assert that gdk_drop_finish() is called after the
drop is performed.
2021-06-19 07:50:41 -07:00
Matthias Clasen
13a2db2238
Merge branch 'fix-3798' into 'master'
...
GDK-Win32: Fix drag surface positioning (issue #3798 )
Closes #3798
See merge request GNOME/gtk!3659
2021-06-18 17:31:51 +00:00
Matthias Clasen
e8f9fb0f86
Merge branch 'gsk-big-batches' into 'master'
...
ci: Build Broadway on MacOS
See merge request GNOME/gtk!3686
2021-06-18 17:00:58 +00:00
Matthias Clasen
634bd2de48
Merge branch 'matthiasc/for-master' into 'master'
...
ci: Build Broadway on MacOS
See merge request GNOME/gtk!3685
2021-06-18 14:09:49 +00:00
Matthias Clasen
f58fc6b22e
gsk: Respect max element vertices limitation
...
We are pretty good at batching commands now, and we can easily
produce batches that exceed the maximum number of elements per
draw call that the hw can handle. Query that number, and respect
it when merging batches.
This fixes the rendering of the overview map in GtkSourceView.
2021-06-18 06:50:59 -07:00
Matthias Clasen
fb052c8d25
ci: Build Broadway on MacOS
...
We've seen a build failure if Broadway is built without
the X11 backend. Lets recreate that configuration in ci
so it doesn't break again.
2021-06-18 06:09:14 -07:00
Chun-wei Fan
e35490ba5b
gdkdrag-win32.c: Fix drag surface positioning
...
Determine the root_x and root_y coordinates of the drag surface by
relying on the coordinates of the surface where the drag is being
carried out, plus the coordinates that we receive from the drag event,
which is in-line with what the X11 backend does.
This will prevent the drag surface from being initially drawn at the
correct position, but jumping towards the top-left corner of the screen
shortly afterwards.
The DnD support will still need some more updates to function correctly
on Windows, but at least this is a small improvement.
Fixes issue #3798 .
2021-06-18 18:07:50 +08:00
Matthias Clasen
be1b979e51
Merge branch 'matthiasc/for-master' into 'master'
...
treeviewcolumn: Clip header buttons
Closes #4045
See merge request GNOME/gtk!3682
2021-06-18 04:37:48 +00:00
Christian Hergert
3fd931d392
macos: implement GdkDrop for macOS
...
This gets the basic mechanics of the drop portion of DnD working on the
macOS backend. You can drag, for example, from TextEdit into GNOME
Text Editor when using the macOS backend.
Other content formats are supported, and match what is currently
supported by the clipboard backend as the implementation to read
from the pasteboard is shared.
Currently, we look up the GdkDrag for the new GdkDrop. However,
nothing is stashing the drag away for further lookup. More work is
needed on GdkMacosDrag for that to be doable.
2021-06-17 17:26:42 -07:00
Christian Hergert
6c1dce2878
macos: make pasteboard usage reusable
...
We will want to be able to reuse the pasteboard reading code from
the macOS DnD drop backend. This just removes the pasteboard
bits from the implementation and allows that to be passed in as in
both clipboard and DnD cases we'll have a specific NSPasteboard
to read from.
2021-06-17 17:19:19 -07:00
Christian Hergert
ad1260505d
macos: check for GdkMacosBaseView before using as such
...
We can get events for external windows such as those from native
file chooser dialogs.
2021-06-17 17:18:19 -07:00
Matthias Clasen
d92f8a1b8e
treeviewcolumn: Clip header buttons
...
We don't want to overdraw when dragging a narrow column
around, and we also need the clipping to avoid picking
the wrong column, when a later column button overlaps
an earlier one.
Fixes : #4045
2021-06-17 17:14:14 -07:00
Matthias Clasen
22827f2cc7
macos: Fix a compiler warning
2021-06-17 17:14:14 -07:00
Christian Hergert
b64370cd48
macos: move drag motion to GdkMacosDrag
...
This doesn't help to be pushed off into the surface, as it makes things
more different than the X11 implementation.
2021-06-17 13:24:39 -07:00
Christian Hergert
6c8e176cc0
macos: fix position of drag surface
2021-06-17 13:23:38 -07:00
Christian Hergert
057bda6cd7
macos: register known clipboard types for drag destination
2021-06-17 13:23:18 -07:00
Matthias Clasen
8df2cce5c1
Merge branch 'wip/chergert/fix-broadway-build' into 'master'
...
inspector: fix compilation with broadway
See merge request GNOME/gtk!3681
2021-06-17 19:45:16 +00:00
Christian Hergert
352898ae9e
inspector: fix compilation with broadway
2021-06-17 11:54:00 -07:00
Matthias Clasen
1bda665662
Merge branch 'matthiasc/for-master' into 'master'
...
action muxer fixes
See merge request GNOME/gtk!3678
2021-06-17 17:53:16 +00:00
Hugo Carvalho
fad4c60499
Update Portuguese translation
...
(cherry picked from commit 807537dd5d )
2021-06-17 14:44:54 +00:00
Matthias Clasen
47bb556327
testsuite: Avoid a compiler warning
...
This was showing up in ci on macos.
2021-06-17 09:37:45 -04:00
Matthias Clasen
4d00f1903a
widget-factory: Show Ctrl-? in the menu
...
We use our own action for showing the shortcuts window,
so we need to associate this shortcut with our action
for it to show up.
2021-06-17 08:59:30 -04:00
Matthias Clasen
7344a03aa3
shortcutcontroller: Don't reinject menu accels
...
The normal way to associate accels with actions is
to attach a shortcut controller to the widget. The shorcut
controller will inject the accel into the action muxer
tree, so that it can get displayed in widgets that activate
the action (say, in menus.
This approach does not works for generated menus, since the
widgets are not in the hands of the app developer, so attaching
shortcut controllers to them is impractical.
Instead, GtkModelButton has an accel property that gets
bound to the accel coming from the action muxer tree (most
likely put there via gtk_application_set_accel_for_action),
and creates a shortcut controller itself.
The change in this commit is to prevent the shortcut controller
from injecting the accel into the action muxer tree in this case.
Otherwise, the accels get 'stuck' and we won't update them if the
global accels are later changed.
This is a hack, and needs a better solution.
2021-06-17 08:50:26 -04:00
Matthias Clasen
64af90111e
window: Propagate accel changes
...
When the global accels change, tell the
shortcut controller to re-inject them into
the action muxer hierarchy.
2021-06-17 08:50:26 -04:00
Matthias Clasen
3254a3feab
shortcutcontroller: Add a way to update accels
...
This will be used to make accel changes propagate.
2021-06-17 08:50:26 -04:00
Matthias Clasen
d5054f9b99
action muxer: Propagate registrations further up
...
We were pretty aggressive about not registering
observers further than necessary, stopping at the
first muxer that provides an action.
But even though action changes further up in the tree
won't be relevant in that case, we need to listen to
accel changes, since they may come from higher up
in the tree (e.g. when using
gtk_application_set_accels_for_action with an action
that is defined on a widget.
So, register all the way to the top, and stop propagating
action changes when we hit a muxer that provides the action.
2021-06-17 08:50:26 -04:00
Matthias Clasen
db93090ea8
menutrackeritem: Be more careful with accel changes
...
In some cases (such as when getting a new parent), the
action muxer doesn't know exactly which detailed actions
have changed accels, so we call primary_accel_changed with
just an action name.
Make the menu tracker item handle that case by matching
either against the detailed name or the the action name.
2021-06-17 08:50:26 -04:00
Matthias Clasen
15c65595b8
action muxer: Propagate accel changes
...
When we set a new parent on an action muxer,
accels may change, so call primary_accel_changed
for involved actions.
2021-06-17 08:50:26 -04:00
Benjamin Otte
e59e9ad6a9
Merge branch 'wip/otte/for-master' into 'master'
...
spinner: Behave like any other icon
See merge request GNOME/gtk!3677
2021-06-17 11:47:28 +00:00
Benjamin Otte
e6c4dbfc6d
spinner: Behave like any other icon
...
Take the size from -gtk-icon-size.
Note that min-width/height still works, as those properties are handled
by the generic widget sizing machinery in GTK4.
2021-06-17 12:54:56 +02:00
Matthias Clasen
424dd8a463
actionobserver: Clarify primary_accel_changed docs
...
Either action_name or action_and_target may be NULL
here, and observer implementations should be careful
when checking those values.
2021-06-16 10:34:37 -04:00
Matthias Clasen
7b1a7629bc
print-editor: Make accels work
...
Sadly, they don't show up anymore with this.
2021-06-16 10:17:49 -04:00
Matthias Clasen
df1116a010
bloatpad: Add icons as resources
...
This can serve as a useful example for how to add
themed icons as resources.
2021-06-16 09:35:00 -04:00
Matthias Clasen
11916bac7e
bloatpad: Give the toolbar a facelift
...
Make it look more like a toolbar.
2021-06-16 09:26:15 -04:00
Matthias Clasen
d675ae5cc5
bloatpad: Improve accel dialog
...
Make this dialog a bit less of an eyesore.
2021-06-16 09:09:24 -04:00
Matthias Clasen
43eeff8f15
examples: Use existing icons
...
The sunny icon doesn't exist anymore.
2021-06-16 08:45:04 -04:00
Matthias Clasen
ece9e7e240
examples: Drop a redundant frame
...
The frame in the drawing example adds nothing
and looks wrong.
2021-06-16 08:40:01 -04:00
Matthias Clasen
1abbf00dcf
Merge branch 'fix-3793' into 'master'
...
gdksurface-win32.c: Fix up popup placement (fix issue #3793 )
Closes #3793
See merge request GNOME/gtk!3674
2021-06-16 10:08:52 +00:00
Matthias Clasen
10564514e8
Merge branch 'media-stream-name-collision' into 'master'
...
mediastream: Some more api renaming
Closes #4023
See merge request GNOME/gtk!3673
2021-06-16 10:07:29 +00:00
Chun-wei Fan
ba7ec29dc0
gdksurface-win32.c: Fix up popup placement
...
If we are undergoing a surface move, just apply the next_layout anyways,
even if we are not moving a toplevel surface.
Update the way how we obtain the x and y coordinates of a surface, if it
is a toplevel, apply the x and y coordinates from the results from we
obtained the underlying Win32 HWND, as we did before. But if it is a
popup, use gdk_win32_surface_get_geometry() to obtain the correct x and
y coordinates to place our popup surface.
Also correct how we compute the shadow dimensions, and the final popup
rectangle as we attempt to layout the popup surface, since GDK-Win32
keeps track of the shadow dimensions in system (unscaled) units, not GDK
units.
Fixes issue #3793 .
2021-06-16 16:25:29 +08:00
Chun-wei Fan
85b595bd14
gdksurface-win32.c: Fix formatting for popup functions
2021-06-16 15:02:56 +08:00
Matthias Clasen
56c486abbf
Merge branch 'drop-target-name-collision' into 'master'
...
droptarget: Rename :drop to :current-drop
Closes #4028
See merge request GNOME/gtk!3669
2021-06-16 00:12:53 +00:00
Matthias Clasen
96fc5dc3a7
mediastream: Some more api renaming
...
Also rename gtk_media_stream_ended to
gtk_media_stream_set_ended, to avoid naming
collision with GtkMediaStream:ended.
The existing entry points still exist, deprecated
and marked as non-introspectable.
Update all internal uses.
Fixes : #4023
2021-06-15 18:33:23 -04:00
Matthias Clasen
b09087d634
droptarget: Rename :drop to :current-drop
...
Rename the GtkDropTraget:drop property to :current-drop,
to avoid naming collision with the signal of the same
name.
We leave the old property and getter in place, deprecated
and marked as non-introspectable.
Fixes : #4028
2021-06-15 18:21:28 -04:00
Matthias Clasen
5e99513507
Merge branch 'cherry-pick-4ba89f25' into 'master'
...
cellarea: Don't shrink area too much
See merge request GNOME/gtk!3672
2021-06-15 20:29:28 +00:00
Matthias Clasen
0a9d2f248e
Merge branch 'label-underline-markup' into 'master'
...
label: Fix mnemonic handling
Closes #4041
See merge request GNOME/gtk!3670
2021-06-15 19:43:40 +00:00
Benjamin Otte
16ff055b42
cellarea: Don't shrink area too much
...
Do not compute rectangles with negative width/height. This avoids
assertion failures further down when those rectangles were actually
checked.
https://bugzilla.redhat.com/show_bug.cgi?id=1962215
(cherry picked from commit 4ba89f25b8 )
2021-06-15 18:00:25 +00:00
Matthias Clasen
89f57d4ff6
Add a mnemonic testcase
...
Add a testcase that tests the label mnemonic handling
that was fixed in the previous commit.
2021-06-15 13:32:31 -04:00
Matthias Clasen
c4a2234a28
label: Fix mnemonic handling
...
We were not handling the case right in which we
want to use underlines, but not use markup. Since
we are now using pango_parse_markup for this case,
we need to escape the xml markup.
Fixes : #4041
2021-06-15 13:06:10 -04:00
Matthias Clasen
a3882763d8
Revert "progressbar: Avoid redundant storage"
...
This reverts commit 95747b1a40 .
This was wrong - it turns out that while GtkProgressBar
allows you to change its orientation, its box layout is
always vertical.
Fixes : #4037
2021-06-15 07:37:57 -04:00
Emin Tufan Çetin
787fa6bd0d
Update Turkish translation
2021-06-15 09:02:34 +00:00
Matthias Clasen
a6b4e53dca
Merge branch 'macos-input-method' into 'master'
...
fix: make input method work again in gtk4
Closes #3968
See merge request GNOME/gtk!3668
2021-06-14 19:20:06 +00:00
Matthias Clasen
00d25ae89c
Merge branch 'media-stream-name-collision' into 'master'
...
mediastream: Rename an api to avoid name collisions
Closes #4023
See merge request GNOME/gtk!3667
2021-06-14 18:44:10 +00:00
Zhi
5776fcd955
fix: make the new nsview as the first responder.
...
Make the new view as the first responder(focused) so the new view can
accept events from input method.
Fixes #3968 .
2021-06-15 00:09:46 +08:00
Matthias Clasen
86b5dba43b
mediastream: Rename an api to avoid name collisions
...
Some bindings can't handle the coexistence of
GtkMediaStream:prepared and gtk_media_stream_prepared.
Help them out by renaming the function to
gtk_media_stream_set_prepared, and rename
gtk_media_stream_unprepared as well, to match.
The existing entry points still exist, deprecated.
Update all internal uses.
Fixes : #4023
2021-06-14 07:50:12 -04:00
Matthias Clasen
e888364d3c
Merge branch 'columnview-double-activation' into 'master'
...
listitemwidget: Claim gesture when activating
Closes #4015
See merge request GNOME/gtk!3663
2021-06-14 10:39:43 +00:00
Matthias Clasen
276f85c9e3
listitemwidget: Claim gesture when activating
...
Claim the gesture when we are activating a list item.
Otherwise we end up with double activations in
columnviews: first GtkColumnViewCell handles
the event, and then GtkListItemWidget handles
it again.
Fixes : #4015
2021-06-13 08:03:39 -04:00
Matthias Clasen
68eb422333
listitemwidget: Match activation conditions
...
Make the conditions used for activation in the single-
and double-click case properly match, so that it is
obvious that we won't trigger both of them.
2021-06-13 08:02:06 -04:00
Matthias Clasen
c0f54f899d
Merge branch 'filename-annotations' into 'master'
...
Add type annotations for filename arguments
Closes #633
See merge request GNOME/gtk!3665
2021-06-13 11:38:50 +00:00
Matthias Clasen
65212535df
Merge branch 'msvc-fix' into 'master'
...
Fix illegal instruction crash on x64 CPUs without POPCNT instruction when compiled with MSVC
See merge request GNOME/gtk!3664
2021-06-13 11:38:22 +00:00
Sebastian Cherek
106ac7c782
Update gtkpopcountprivate.h: undefined macro outside msvc
2021-06-12 17:35:13 +00:00
scherek
bc7b6a0e53
Dropped defined() for readability
2021-06-12 19:10:11 +02:00
scherek
e5b89569fd
Replaced && with || for POPCNT checks to fix the logic.
2021-06-12 17:32:19 +02:00
Matthias Clasen
938bfff3dd
Add type annotations for filename arguments
...
Add missing "(type filename)" annotations for string
arguments that are filenames.
Fixes : #633
2021-06-12 11:12:06 -04:00
scherek
6835fcf3cf
Fix illegal instruction crash on x64 CPUs without POPCNT instruction when compiled with MSVC
2021-06-12 16:18:26 +02:00
Matthias Clasen
2554ee27d9
Merge branch 'listmodel-get-item' into 'master'
...
docs: Mention the GtkWidget.destroy vfunc
Closes #4024
See merge request GNOME/gtk!3662
2021-06-11 19:56:06 +00:00
Matthias Clasen
007cdf8787
Add tests for empty list models
...
Test that all our models return NULL for out-of-range
get_item calls, as expected.
2021-06-11 15:38:20 -04:00
Matthias Clasen
a526daf310
selectionfiltermodel: Fix an oversight
...
When the position is out of range, get_item needs
to return NULL.
Fixes : #4024
2021-06-11 15:37:16 -04:00
Matthias Clasen
ee34e1acc5
docs: Mention the GtkWidget.destroy vfunc
...
Mention GtkWidget.destroy in the migration guide.
2021-06-11 10:11:53 -04:00
Matthias Clasen
a08fbfa586
docs: Fix a typo in the migration guide
2021-06-11 07:52:30 -04:00
Matthias Clasen
d29f57fd1d
Merge branch 'wip/chergert/fix-delayed-focus' into 'master'
...
window: clear move_focus when focus is already set
See merge request GNOME/gtk!3658
2021-06-10 21:31:47 +00:00
Christian Hergert
a4c5d1d94d
window: clear move_focus when focus is already set
...
This can get set in other places, so we need to ensure it is cleared so
that an after-paint handler does not move the focus to a new widget.
2021-06-10 14:01:41 -07:00
Matthias Clasen
17f1bb1632
Merge branch 'actionable-fixes' into 'master'
...
tests: Fix check vs toggle button confusion
Closes #4022
See merge request GNOME/gtk!3656
2021-06-10 13:30:25 +00:00
Matthias Clasen
3418504b4b
checkbutton: Fix actionable state tracking
...
If we have a GAction as model, we just have to
call gtk_action_helper_activate() and let
the action helper handle the state updates,
Fixes : #4022
2021-06-10 08:38:12 -04:00
Matthias Clasen
0a78a592ff
togglebutton: Fix actionable state tracking
...
If we have a GAction as model, we just have to let
the action helper handle the state updates. GtkButton
already calls gtk_action_helper_activate() for us.
2021-06-10 08:36:08 -04:00
Matthias Clasen
208c527fb3
button: Add a private getter for the action helper
...
GtkToggleButton needs to know if it needs to actively
maintain its state, or defer to the action helper.
2021-06-10 08:36:01 -04:00
Matthias Clasen
28990285e2
testgaction: Add more widgetry
...
Add some toggle and check buttons to test that they
work as expected as GtkActionables.
2021-06-10 08:10:25 -04:00
Matthias Clasen
c7ad8d29e9
Fix the GAction test
...
We weren't setting the state of the stateful actions.
2021-06-10 08:10:08 -04:00
Matthias Clasen
dba8d1ff77
tests: Fix check vs toggle button confusion
...
Check buttons aren't toggle buttons anymore.
2021-06-10 07:49:08 -04:00
Matthias Clasen
143770f16d
4.3.1
2021-06-09 18:23:47 -04:00
Matthias Clasen
8a890238f5
Merge branch 'ebassi/docs-for-master' into 'master'
...
docs: Mention Window::close-request in the migration guide
See merge request GNOME/gtk!3655
2021-06-09 17:30:02 +00:00
Emmanuele Bassi
71be3a8de1
docs: Mention the ::damage-event signal in the migration guide
...
There is no replacement for damage event tracking.
2021-06-09 18:11:10 +01:00
Emmanuele Bassi
17373c3e77
docs: Mention GdkSurface:mapped
...
It replaces the ::map-event and ::unmap-event signals on GtkWidget.
2021-06-09 18:08:31 +01:00
Emmanuele Bassi
078ada75d4
docs: Mention Window::close-request in the migration guide
...
The Widget::delete-event signal was moved to Window::close-request.
2021-06-09 18:03:12 +01:00
Matthias Clasen
51a60b88b7
Merge branch 'ci-install-build' into 'master'
...
Make a standalone hello world
See merge request GNOME/gtk!3652
2021-06-09 12:59:46 +00:00
Matthias Clasen
193903ce4a
ci: Update the image
...
v32 of the image includes wayland-protocols 1.21, and
other updates from Fedora 34.
While we are at it, drop gtk-doc from the image, and drop
the separate DOCS_IMAGE - no longer used.
2021-06-09 08:42:37 -04:00
Matthias Clasen
386002597b
ci: Collect hello build logs
2021-06-09 08:42:30 -04:00
Matthias Clasen
e5a6d4a1c8
ci: Test building against installed GTK
...
This is meant to ensure that we e.g. install the
right header files, and so on.
2021-06-09 08:42:30 -04:00
Matthias Clasen
06caa57f9a
Make a standalone hello world
...
We want to test building against the installed GTK
in ci, so lets add a standalone project.
2021-06-08 17:41:11 -04:00
Matthias Clasen
5ef6944a41
Merge branch 'row-activated-annotation' into 'master'
...
treeview: Add a few missing annotations
Closes #3828
See merge request GNOME/gtk!3647
2021-06-08 17:17:45 +00:00
Matthias Clasen
2e415e266f
Merge branch 'wip/carlosg/spin-button-swipe-gesture' into 'master'
...
spinbutton: Connect swipe gesture to the text entry
Closes #4008
See merge request GNOME/gtk!3649
2021-06-08 14:54:26 +00:00
Zhi
970bb804de
fix: replace deprecated metods.
...
Use NSInputContext to replace NSInputManager, which has been deprecated
since 10.6.
Sync from 0e30a96 in gtk3.
2021-06-08 22:47:53 +08:00
Carlos Garnacho
915388cfdb
spinbutton: Mind the step in the swipe gesture
...
The swipe gesture forces values in the spin button that are
"impossible" according to the adjustment. This can break things
in creative ways.
Ensure the steps provided are always multiples of the adjustment
step value, and keep the remainder for further interaction.
2021-06-08 15:18:14 +02:00
Carlos Garnacho
1bf7f5eacb
spinbutton: Connect swipe gesture to the text entry
...
In the GTK3 days, the spin button was an entry, with buttons on
top, and the swipe gesture affected the input on the entry bits.
Now the spin button is a container, so this gesture in the capture
phase applies to all contained children (incl. buttons).
Attach this gesture to the entry itself, so the buttons are left
outside this business. The gesture is still in the capture phase
in order to prevent text selection/edition/etc to happen.
Fixes: https://gitlab.gnome.org/GNOME/gtk/-/issues/4008
2021-06-08 15:17:56 +02:00
Matthias Clasen
6a86acb9ce
Apply 1 suggestion(s) to 1 file(s)
2021-06-08 12:59:57 +00:00
Matthias Clasen
e35e7bcd4a
Apply 1 suggestion(s) to 1 file(s)
2021-06-08 12:59:38 +00:00
Mohammed Sadiq
517b5173f9
video: Reveal controls on tap
...
So that the controls shall be shown on touch
2021-06-08 18:06:51 +05:30
Matthias Clasen
37acfcfcd5
Merge branch 'password-entry-buffer' into 'master'
...
Install gtkpasswordentrybuffer.h
See merge request GNOME/gtk!3646
2021-06-08 12:09:01 +00:00
Matthias Clasen
c2f2a45227
treeview: Documentation tweaks
2021-06-08 07:59:47 -04:00
Matthias Clasen
621e0a13e9
Install gtkpasswordentrybuffer.h
2021-06-08 07:49:42 -04:00
Matthias Clasen
92fcd37a19
Merge branch 'password-entry-buffer' into 'master'
...
Make GtkPasswordEntryBuffer public
See merge request GNOME/gtk!3645
2021-06-08 11:25:12 +00:00
Matthias Clasen
d8bde48b87
Make GtkPasswordEntryBuffer public
2021-06-08 11:25:11 +00:00
Matthias Clasen
825ffb9422
Merge branch 'ebassi/issue-3892' into 'master'
...
a11y: Update the level property for tree expanders
Closes #3892
See merge request GNOME/gtk!3470
2021-06-07 18:10:12 +00:00
Emmanuele Bassi
046ef010b3
Merge branch 'glib-main' into 'master'
...
subprojects: Use GLib main branch
See merge request GNOME/gtk!3642
2021-06-07 14:53:04 +00:00
Philip Withnall
b71ec6cb59
subprojects: Use GLib main branch
...
GLib upstream has renamed its `master` branch to `main`.
See https://gitlab.gnome.org/GNOME/glib/-/issues/2348 .
Signed-off-by: Philip Withnall <pwithnall@endlessos.org >
2021-06-07 14:56:49 +01:00
Matthias Clasen
b1beb3650b
treeview: Add a few missing annotations
...
gtk_tree_view_row_activated and the ::row-activated signal
can (and do) receive NULL for the column occasionally.
This is an introspection api change.
Fixes : #3828
2021-06-06 08:24:52 -04:00
Matthias Clasen
fca19e72ad
Merge branch 'matthiasc/for-master' into 'master'
...
Docs: Tweaks
Closes #3638
See merge request GNOME/gtk!3639
2021-06-05 22:13:21 +00:00
Matthias Clasen
98d2320c93
gtk-builder-tool: Replace can-focus with focusable
...
The focusable property has the meaning that can-focus had
in GTK 3.
Update tests, and mention this in the migration guide.
Fixes : #3638
2021-06-05 17:56:35 -04:00
Matthias Clasen
effc7a619d
Docs: Tweaks
...
Remove some more redundant "or NULL" blurbs.
2021-06-05 17:38:23 -04:00
Matthias Clasen
0ec017fcc0
Merge branch 'matthiasc/for-master' into 'master'
...
popovermenu: doc tweaks
See merge request GNOME/gtk!3638
2021-06-05 21:36:06 +00:00
Matthias Clasen
94ad177176
popovermenu: doc tweaks
2021-06-05 17:19:39 -04:00
Matthias Clasen
4616104742
Merge branch 'submenu-action-fixes' into 'master'
...
Submenu action fixes
Closes #3721
See merge request GNOME/gtk!3272
2021-06-05 13:36:10 +00:00
Matthias Clasen
a3a24b81c8
Merge branch 'msvc-aarch64' into 'master'
...
gtkpopcountprivate.h: Fix build on ARM/aarch64 Visual Studio
See merge request GNOME/gtk!3637
2021-06-05 13:05:15 +00:00
Matthias Clasen
debcc62775
menusectionbox: Fix submenu-action for nested menus
...
We were not updating the state of submenu-actions
for nested submenus.
Fixes : #3721
2021-06-05 08:49:18 -04:00
Matthias Clasen
b11f31afea
popovermenubar: Make submenu-actions work
...
We were not updating submenu-action state
for items in menubars.
2021-06-05 08:49:17 -04:00
Matthias Clasen
db2e5648c9
menutrackeritem: Make submenu-actions work again
...
This broke when GtkActionMuxer stopped being a
GActionGroup.
2021-06-05 08:49:17 -04:00
Matthias Clasen
46d1f04a7c
bloatpad: Bring back the menubar
...
This was lost at some point.
2021-06-05 08:49:17 -04:00
Matthias Clasen
fe774c1ad8
Merge branch 'powimod_icon' into 'master'
...
Load icon from executable on Windows
Closes #3713
See merge request GNOME/gtk!3326
2021-06-05 12:47:08 +00:00
Chun-wei Fan
08ee36e7c4
gtkpopcountprivate.h: Fix build on ARM/aarch64 Visual Studio
...
__popcnt() is not supported for ARM nor ARM64 Visual Studio builds, so we must
use the fallback implementation as intrinsics are not supported for this
purpose on ARM/ARM64 Visual Studio builds.
2021-06-05 15:41:14 +08:00
Matthias Clasen
1605ec0a44
Merge branch 'ci-file-filters' into 'master'
...
GtkFileFilter: Allow case-insensitive patterns
Closes #3705
See merge request GNOME/gtk!359
2021-06-05 01:47:24 +00:00
Matthias Clasen
4b46e11b22
Merge branch 'imcontext-ignore-more-keysyms' into 'master'
...
imcontext: Ignore more keysyms
See merge request GNOME/gtk!3634
2021-06-05 01:19:39 +00:00
Matthias Clasen
9993e91add
Add GtkFileFilter tests
2021-06-04 21:10:01 -04:00
Matthias Clasen
9ac22c1088
GtkFileFilter: Add suffix matches
...
This is less flexible than a glob pattern, but it is
explicitly case-insensitive, to match the behavior
on Windows.
Fixes : #3705
2021-06-04 21:10:01 -04:00
Matthias Clasen
47400e4bd8
Add a helper to make case-insensitive globs
...
This will be used in GtkFileFilter in the future.
Tests included.
2021-06-04 21:10:01 -04:00
Matthias Clasen
8981ba4bd2
imcontext: Ignore more keysyms
...
It finally dawned on my that #3673 is just another
case of unexpected keysyms getting sent our way via
fringe XKB features.
Ignore them all!
2021-06-04 19:01:57 -04:00
Matthias Clasen
74a41eeb70
Merge branch 'matthiasc/for-master' into 'master'
...
docs: Mention <packing> in migration guide
Closes #3950 and #2271
See merge request GNOME/gtk!3630
2021-06-04 20:24:23 +00:00
Matthias Clasen
ff874318c0
Merge branch 'master' into 'matthiasc/for-master'
...
# Conflicts:
# docs/reference/gtk/migrating-3to4.md
2021-06-04 20:24:09 +00:00
Matthias Clasen
a4598567b9
icontheme: Add detail to the 'not found' message
...
Name the icon theme we're using.
Fixes : #2271
2021-06-04 09:49:05 -04:00
Matthias Clasen
8f95661167
Clean up some comments
...
These XXX comments aren't useful enough to keep.
2021-06-04 09:49:05 -04:00
Matthias Clasen
e437c55142
Add a doc comment for gsk_rounded_rect_is_circular
2021-06-04 09:49:05 -04:00
Matthias Clasen
ff01067b8b
Merge branch 'matthiasc/for-master' into 'master'
...
docs: Mention <packing> in migration guide
Closes #3950
See merge request GNOME/gtk!3629
2021-06-04 13:21:37 +00:00
Matthias Clasen
7f4630abac
wayland: Add a comment
...
I just had to debug this to rediscover how it works, so
add a comment for next time.
2021-06-04 08:30:52 -04:00
Matthias Clasen
4c9bd6ed9a
wayland: Add a comment
...
I just had to debug this to rediscover how it works, so
add a comment for next time.
2021-06-04 08:29:23 -04:00
Matthias Clasen
b6cd97be1e
docs: Escape some xml tags
...
When mentioning xml tags in markdown, we must write
them as `<foo>`, or they will come out mangled.
2021-06-04 08:06:18 -04:00
Matthias Clasen
c4cbd6ec1b
docs: Mention <packing> in migration guide
...
Add another hint for what to do with child properties.
Fixes : #3950
2021-06-04 07:59:07 -04:00
Matthias Clasen
312289fb11
docs: Mention <packing> in migration guide
...
Add another hint for what to do with child properties.
Fixes : #3950
2021-06-04 07:42:21 -04:00
Matthias Clasen
036dd60a4e
Merge branch 'matthiasc/for-master' into 'master'
...
fnmatch: Support case-folding
See merge request GNOME/gtk!3628
2021-06-04 04:43:20 +00:00
Matthias Clasen
10c6c93f40
Merge branch 'gtk_combo_box_with_entry_docs_update' into 'master'
...
Documentation update for combo_box_new_with_entry
See merge request GNOME/gtk!3605
2021-06-04 04:02:48 +00:00
DarkTrick
4d894e08f7
Documentation update for combo_box_new_with_entry
2021-06-04 04:02:48 +00:00
Matthias Clasen
31407d0a4c
Move fnmatch testcases to the testsuite
...
We have a well-working way to test internal
apis now, lets use it for these tests.
2021-06-03 23:58:50 -04:00
Matthias Clasen
bb53cf53e7
fnmatch: Support case-folding
...
This will be used in GtkFileFilter in the future.
Update all callers.
2021-06-03 23:58:21 -04:00
Matthias Clasen
da9cd4659e
Merge branch 'bilelmoussaoui/markdown-links' into 'master'
...
docs: use markdown syntax for hyperlinks
See merge request GNOME/gtk!3589
2021-06-04 02:45:25 +00:00
Matthias Clasen
d3e6e303fc
Merge branch 'GtkCellLayoutWordingImprovement' into 'master'
...
Added information, that "attributes" refer to CellRenderer "properties".
See merge request GNOME/gtk!3602
2021-06-04 02:21:33 +00:00
DarkTrick
a0c23b1c3d
Added information, that "attributes" refer to CellRenderer "properties".
2021-06-04 02:21:31 +00:00
Matthias Clasen
50b3a952c8
Merge branch 'fix-appwindow-allocate' into 'master'
...
applicationwindow: Allocate tooltips
Closes #3997
See merge request GNOME/gtk!3627
2021-06-04 02:01:53 +00:00
Matthias Clasen
15b24a000d
Apply 1 suggestion(s) to 1 file(s)
2021-06-04 01:53:12 +00:00
Matthias Clasen
6a509608f9
applicationwindow: Allocate tooltips
...
GtkApplicationWindows size_allocate does not chain
up if the menubar is visible; don't forget to allocate
the tooltip window in that case.
Fixes : #3997
2021-06-03 21:43:13 -04:00
Matthias Clasen
df6a52520c
Merge branch 'matthiasc/for-master' into 'master'
...
Cosmetics: Eradicate gdouble
See merge request GNOME/gtk!3626
2021-06-03 21:59:26 +00:00
Matthias Clasen
578db92973
Cosmetics: Eradicate gint
...
Remove a handful of errant uses of gint.
2021-06-03 17:41:28 -04:00
Matthias Clasen
3ab97fac1f
Cosmetics: Eradicate gdouble
...
Remove 3 errant uses of gdouble.
2021-06-03 17:41:28 -04:00
Matthias Clasen
e8852c9a25
Merge branch 'primary-menu-button' into 'master'
...
menubutton: Enable F10 for primary menus
See merge request GNOME/gtk!3580
2021-06-03 19:37:23 +00:00
Matthias Clasen
fa0b379d30
Merge branch 'wip/carlosg/no-early-popup-ungrabs' into 'master'
...
gdk/wayland: Break only implicit grabs on wl_pointer.leave w/ pressed buttons
See merge request GNOME/gtk!3625
2021-06-03 18:10:06 +00:00
Emmanuele Bassi
1565053842
Merge branch 'akamfoad/readme-link-fixes' into 'master'
...
Update broken links in README.md
Closes #4001
See merge request GNOME/gtk!3623
2021-06-03 15:23:45 +00:00
Carlos Garnacho
8288d9e87c
gdk/wayland: Break only implicit grabs on wl_pointer.leave w/ pressed buttons
...
The releasing of grabs while a button is pressed (e.g. after starting dnd, or
dragging the window, or going to overview with a pressed button, etc...) was
generalized here in https://gitlab.gnome.org/GNOME/gtk/-/merge_requests/1879 .
However we shouldn't break all grabs here. In the case of grabbing popups,
compositors will still emit crossing events between client surfaces (e.g.
popping up and selecting a menu item via press-drag-release), breaking all
grabs here means inconsistent client state, that was
https://gitlab.gnome.org/GNOME/gtk/-/issues/2746 .
That was fixed in mutter, by essentially making implicit grabs
owner_events=FALSE, however that breaks the mentioned use pattern entirely.
Mutter is changing this behavior back, so GTK should handle these crossing
events.
The grab that we are interested in breaking here is the implicit pointer
one. Popups will be dismissed via other means if the compositor says their
active grab needs breaking. This still leaves dnd/move/resize drags in
one place, while not allowing #2746 to happen with popups.
2021-06-03 17:13:12 +02:00
Akam Foad
a900b30bcf
Changing old Gtk4 link to the new one hosted in gtk docs
2021-06-03 14:22:06 +00:00
Akam Foad
9b671d1f79
Update broken links in README.md
...
Updated Release notes links from https://developer.gnome.org/gtkX/unstable/YYYY.html
to https://developer.gnome.org/gtkX/stable/YYYY.html in the README.md file in the root
folder.
Closes #4001
2021-06-03 14:02:59 +00:00
Emmanuele Bassi
c2d82c23e6
Merge branch 'ebassi/doc-fixes' into 'master'
...
Small doc fixes
See merge request GNOME/gtk!3622
2021-06-03 10:32:01 +00:00
Emmanuele Bassi
a88b4f517e
docs: Fix link to the interactive debugging section
...
It's in the "running" document.
2021-06-03 09:31:13 +01:00
Emmanuele Bassi
f9f9fa6dc6
docs: Fix the license field
...
It's LGPL-2.1-or-later, not GPL.
2021-06-03 09:11:09 +01:00
Matthias Clasen
a1789ee2b8
Merge branch 'wip/chergert/fix-use-after-free-switcher' into 'master'
...
stackswitcher: clear timer when widget id disposed
See merge request GNOME/gtk!3621
2021-06-02 20:21:57 +00:00
Matthias Clasen
ffb7df2cc4
Merge branch 'macos-menubar' into 'master'
...
macos: fix weird menubar rendering.
Closes #3967
See merge request GNOME/gtk!3607
2021-06-02 20:13:16 +00:00
Christian Hergert
c2ca246aee
stackswitcher: clear timer when widget id disposed
...
If the widget is disposed while the cursor has a drag timeout queued, it
can activate after finalization.
2021-06-02 10:20:32 -07:00
Matthias Clasen
80c33ca2dd
Merge branch 'wip/otte/for-master' into 'master'
...
x11: Be more careful with NVIDIA workaround
See merge request GNOME/gtk!3620
2021-06-02 14:57:52 +00:00
Matthias Clasen
7307c6fdfb
Merge branch 'entry-docs-typo' into 'master'
...
entry: Fix a typo in the docs
See merge request GNOME/gtk!3619
2021-06-02 11:15:10 +00:00
Matthias Clasen
039fc2e567
entry: Fix a typo in the docs
2021-06-02 06:47:27 -04:00
Matthias Clasen
1dcf9d5c95
Merge branch 'wip/exalm/treeview-click' into 'master'
...
treeview: Don't handle clicks on any child widgets
Closes #3996
See merge request GNOME/gtk!3618
2021-06-02 10:33:50 +00:00
Matthias Clasen
742482e0e1
Merge branch 'box-orientation' into 'master'
...
progressbar: Avoid redundant storage
See merge request GNOME/gtk!3617
2021-06-02 10:16:17 +00:00
Alexander Mikhaylenko
80497debbb
treeview: Don't handle clicks on any child widgets
...
We already skip them on the edited cell widget, but it's also a problem for
header buttons. Overall, there's no real reason to let it propagate here.
Fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/3996
2021-06-02 13:49:11 +05:00
Matthias Clasen
bffc6c5b9a
spinbutton: Avoid redundant storage
...
GtkBoxLayout stores the orientation; no need for
GtkSpinButton to duplicate that.
2021-06-01 17:37:07 -04:00
Matthias Clasen
95747b1a40
progressbar: Avoid redundant storage
...
GtkBoxLayout stores the orientation; no need for
GtkProgressBar to duplicate that.
2021-06-01 17:37:01 -04:00
Matthias Clasen
775dbec2e6
Merge branch 'demo-appdata' into 'master'
...
demos: Generate appdata
Closes #3993
See merge request GNOME/gtk!3613
2021-06-01 20:17:16 +00:00
Matthias Clasen
25ee6d3f47
demos: Generate appdata
...
We don't maintain a release history here, but at least
we can put in the right version and date for the current
build.
Fixes : #3993
2021-06-01 15:36:33 -04:00
Matthias Clasen
1f3f2f1dca
Merge branch 'wip/chergert/switcher-orientable' into 'master'
...
stackswitcher: implement GtkOrientable
Closes #3988
See merge request GNOME/gtk!3606
2021-06-01 18:28:23 +00:00
Christian Hergert
c848a51395
stackswitcher: implement GtkOrientable
...
In GTK 3, GtkStackSwitcher implemented GtkOrientable via the parent GtkBox
type. In GTK 4, that was changed to inherit from GtkWidget and lost this
interface implementation.
This adds that back, along with a note in the documentation that the
interface was added in GTK 4.4.
Fixes #3988
2021-06-01 10:57:27 -07:00
Matthias Clasen
7d3c3cb653
Merge branch 'fix_cast_warning_adding_notebook_page' into 'master'
...
invalid cast from 'GtkButton' to 'GtkBox'
See merge request GNOME/gtk!3615
2021-06-01 16:18:31 +00:00
Caolán McNamara
9c79b8b877
invalid cast from 'GtkButton' to 'GtkBox'
...
on adding a page to a GtkNotebook
(soffice): Gtk-CRITICAL **: gtk_box_remove: assertion 'GTK_IS_BOX (box)' failed
2021-06-01 14:56:53 +01:00
Matthias Clasen
c137f4017f
Merge branch 'screensaver-async-4' into 'master'
...
gtkapplication-dbus: Fetch inital screen saver state async
See merge request GNOME/gtk!3599
2021-06-01 11:14:38 +00:00
Matthias Clasen
c92b21b5fd
Merge branch 'fix-has-actionable-function' into 'master'
...
texthistory: fix has_actionable function
See merge request GNOME/gtk!3612
2021-06-01 11:04:56 +00:00
liferooter
44f07f7708
texthistory: fix has_actionable function
2021-06-01 11:04:55 +00:00
Matthias Clasen
b85b4f2cd6
Merge branch 'box-orientation' into 'master'
...
box: Avoid redundant storage
See merge request GNOME/gtk!3611
2021-05-31 23:05:11 +00:00
Matthias Clasen
d1a7a55d7e
box: Avoid redundant storage
...
GtkBoxLayout stores the orientation; no need for
GtkBox to duplicate that.
2021-05-31 18:38:52 -04:00
Zhi
75868dfee4
macos: fix weird menubar rendering.
...
As app menu has been deprecated, the function of app menu should be
merged into the menubar, which behaves like the original API of NSApp.
This also brings back the default app menu, which looks like native
macOS apps.
For future refactoring, please note that the menubar must contain at
least one menu before being set to NSApp to avoid weird menubar
rendering.
Fixes #3967 .
2021-05-30 21:59:57 +08:00
Fabio Tomat
44bc9a24f8
Update Friulian translation
...
(cherry picked from commit a80804ccef )
2021-05-27 16:13:50 +00:00
Matthias Clasen
c9785c4cd3
Merge branch 'placeholder-alignment' into 'master'
...
text: Propagate xalign to the placeholder
Closes #3979
See merge request GNOME/gtk!3604
2021-05-27 11:44:33 +00:00
Matthias Clasen
9f93883dc9
text: Propagate xalign to the placeholder
...
This is what we were doing in GTK 3, and there's
no reason not to continue.
Fixes : #3979
2021-05-27 06:57:23 -04:00
Matthias Clasen
4362f7e6e2
Merge branch 'bilelmoussaoui/for-gi-docgen-grid' into 'master'
...
docs: fix gtk grid formatting
See merge request GNOME/gtk!3603
2021-05-27 10:31:24 +00:00
Bilal Elmoussaoui
90a829f25a
docs: fix gtk grid formatting
2021-05-27 09:58:42 +00:00
Emmanuele Bassi
d0e29cc901
Merge branch 'bilelmoussaoui/for-gi-docgen' into 'master'
...
docs: fix broken links
See merge request GNOME/gtk!3601
2021-05-27 00:43:31 +00:00
Bilal Elmoussaoui
8ebdd256a5
docs: fix broken links
2021-05-27 00:18:23 +00:00
Matthias Clasen
4b5f8e6ceb
Merge branch 'test-text-buffer-undo' into 'master'
...
Add a test for text buffer history
See merge request GNOME/gtk!3596
2021-05-26 19:33:58 +00:00
Matthias Clasen
ffbfafb189
textbuffer: Add some docs for undo
...
Mention what is undoable and what isn't.
2021-05-26 14:36:16 -04:00
Matthias Clasen
994a38c7ad
textbuffer: Improve the docs
...
Add getter/setter annotations.
2021-05-26 14:36:16 -04:00
Matthias Clasen
0268c9d642
Add tests for text buffer history
...
Check that things can be undone.
2021-05-26 14:36:16 -04:00
Matthias Clasen
f729912913
Merge branch 'wip/chergert/fix-3977' into 'master'
...
textbuffer: ensure user actions are propagated to history
Closes #3977
See merge request GNOME/gtk!3600
2021-05-26 17:43:34 +00:00
Christian Hergert
6179886b14
textbuffer: ensure user actions are propagated to history
...
This was an oversight when porting the GtkTextHistory into GTK. We simply
need to bind the GtkTextBuffer action into the text history for grouping
to work correctly.
Fixes #3977
2021-05-26 10:11:33 -07:00
Guido Günther
3aa34c1211
gtkapplication-dbus: Fetch inital screen saver state async
...
Avoid a sync call that can make the application block for no good
reason.
Fixes 6bfe171058
2021-05-26 18:47:38 +02:00
Matthias Clasen
24f0ae1d39
Merge branch 'move-text-history-tests' into 'master'
...
Move text history tests
See merge request GNOME/gtk!3597
2021-05-26 12:01:58 +00:00
Matthias Clasen
c0ca3c642a
Merge branch 'picture-nullable-setters' into 'master'
...
picture: Make setters actually take NULL
Closes #3974
See merge request GNOME/gtk!3598
2021-05-26 11:46:23 +00:00
Matthias Clasen
b2b044ce95
Move text history tests
...
We can test internal apis in our testsuite now,
so move the text history tests there, to have them
run in ci.
2021-05-26 07:34:28 -04:00
Matthias Clasen
8f4b0cd30d
picture: Make setters actually take NULL
...
gtk_picture_set_file was claiming to be nullable,
but choked on NULL.
Fixes : #3974
2021-05-26 07:30:57 -04:00
Matthias Clasen
cbe2aa716d
Merge branch 'bilelmoussaoui/for-gi-docgen-link' into 'master'
...
gtk: drop unwanted char on Switch::state-set docs link
See merge request GNOME/gtk!3594
2021-05-25 23:23:39 +00:00
Bilal Elmoussaoui
23ea33b656
gtk: drop unwanted char on Switch::state-set docs link
2021-05-25 20:29:46 +00:00
Matthias Clasen
ee80a22db4
Merge branch 'wip/exalm/checks' into 'master'
...
checkbutton: Sync the indicator state with the widget
See merge request GNOME/gtk!3568
2021-05-25 20:29:06 +00:00
Matthias Clasen
d32c343657
Merge branch 'fix.vs2013.link' into 'master'
...
gtk/meson.build: Fix linking on Visual Studio 2013
See merge request GNOME/gtk!3575
2021-05-25 20:27:54 +00:00
Emmanuele Bassi
90d8c94819
Merge branch 'ebassi/introspection-error' into 'master'
...
Turn introspection scanner warnings into errors
See merge request GNOME/gtk!3588
2021-05-25 18:51:54 +00:00
Emmanuele Bassi
e13da35d4d
Turn introspection scanner warnings into errors
...
We want to catch errors in our annotations or our API.
2021-05-25 19:16:37 +01:00
Emmanuele Bassi
f50450485c
docs: Add missing documentation on Windows
...
The gtk_print_run_page_setup_dialog() function, and its asynchronous
variant, are declared in the common gtkprintoperation.h header, but
implemented in different source files depending on the platform.
2021-05-25 19:16:37 +01:00
Matthias Clasen
264d08abc4
Merge branch 'ignore-nosymbol-press' into 'master'
...
imcontext: Ignore NoSymbol key events
Closes #3973
See merge request GNOME/gtk!3591
2021-05-25 17:44:45 +00:00
Matthias Clasen
8c441756df
imcontext: Ignore NoSymbol key events
...
These can happen with some XKB options.
Fixes : #3973
2021-05-25 13:20:12 -04:00
Emmanuele Bassi
cdf2a9ddce
Merge branch 'bilelmoussaoui/for-gi-docgen' into 'master'
...
gdk: fix wrong doc annotation
See merge request GNOME/gtk!3590
2021-05-25 16:23:15 +00:00
Bilal Elmoussaoui
a196a35d1d
gdk: fix wrong doc annotation
2021-05-25 16:07:51 +00:00
Yuri Chornoivan
aeda5b2f58
Update Ukrainian translation
2021-05-25 13:19:55 +00:00
Bilal Elmoussaoui
02672a521a
docs: use markdown syntax for hyperlinks
2021-05-25 13:14:01 +00:00
Emmanuele Bassi
da1e43c1e6
Merge branch 'ebassi/docs-fixes' into 'master'
...
Enable fatal warnings for gi-docgen
See merge request GNOME/gtk!3587
2021-05-25 12:57:28 +00:00
Emmanuele Bassi
6d06b0f076
Enable fatal warnings when build the docs
...
We want to fail the CI pipeline when the documentation generator emits a
warning.
2021-05-25 13:32:32 +01:00
Emmanuele Bassi
7da2e86d4b
docs: Fix the PANGO_SCALE link
...
The fragment for constants is `const`.
2021-05-25 13:31:49 +01:00
Matthias Clasen
1f99723a9f
Merge branch 'fix-im-reset' into 'master'
...
imcontextsimple: Fix a possible problem
See merge request GNOME/gtk!3584
2021-05-25 12:09:38 +00:00
Matthias Clasen
c3c16bd2be
Merge branch 'matthiasc/for-master' into 'master'
...
doc: Syntax fixes
See merge request GNOME/gtk!3583
2021-05-25 11:57:48 +00:00
Matthias Clasen
4c2761302a
doc: Syntax fixes
...
No, we can't have links that say [constructor@...] or
[mehtod@...] or [methoc@...] or [methos@...] or [metohd@...].
And no, not [signals@...] either.
2021-05-25 07:33:55 -04:00
Emmanuele Bassi
3d19b1108a
Merge branch 'bilelmoussaoui/gi-docgen-link-fix' into 'master'
...
gtk: fix gi-docgen link type
See merge request GNOME/gtk!3582
2021-05-25 11:26:08 +00:00
Bilal Elmoussaoui
4728d7b70b
gtk: fix gi-docgen link type
...
constructors are supposed to use "ctor" as a link type, not new
2021-05-25 09:25:32 +00:00
Matthias Clasen
cbd34cd239
Merge branch 'quartz-elide-underscores' into 'master'
...
Bring back elide_underscores
See merge request GNOME/gtk!3581
2021-05-24 22:55:10 +00:00
Matthias Clasen
d0ca4a1255
imcontextsimple: Fix a possible problem
...
We were forgetting to handle the compose sequence
case in reset().
2021-05-24 18:53:14 -04:00
Matthias Clasen
16623d4e71
quartz: Elide underscores again
...
We don't want a literal _File to show up in the
global menubar on OS X, so use the revivied
_gtk_elide_underscores.
Related: #3967
2021-05-24 17:39:05 -04:00
Matthias Clasen
dab7ceaa24
Bring back elide_underscores
...
This used to live in gtktoolbar.c, which is gone.
We still need it, so put it in gtkprivate.c.
2021-05-24 17:37:05 -04:00
Matthias Clasen
a74420bc1a
menubutton: Enable F10 for primary menus
...
Add a ::primary property to GtkMenuButton, which can
be set to make the menu activatable with F10, like
menubars.
2021-05-24 17:27:40 -04:00
Emmanuele Bassi
b05f3f5614
Merge branch 'gallery-reflow-fix' into 'master'
...
docs: Convince the widget gallery to reflow
See merge request GNOME/gtk!3579
2021-05-24 15:44:26 +00:00
Matthias Clasen
808e5421a9
docs: Convince the widget gallery to reflow
2021-05-24 10:51:02 -04:00
Matthias Clasen
f1f225c6b3
Merge branch 'gst.gl.win32' into 'master'
...
media/gstreamer: Support using GL for video for Windows
See merge request GNOME/gtk!3506
2021-05-24 11:37:06 +00:00
Chun-wei Fan
16f307b305
media-gstreamer: Provide fallback mode for playback
...
Make the "gl-context" property of the GstGLSink readable as well so that
we can query whether the GstGLContext sharing really succeeded. If it
did, then we proceed to playback our video using the glimagesink as we
did before. If it didn't, throw out the GtkGstSink we were creating, and
re-create the GtkGstSink without the "gl-context" property, meaning that
we won't be using the glimagesink in this case.
2021-05-24 19:04:37 +08:00
Chun-wei Fan
ccdec5da77
gtkgstsink.c: Support EGL on Windows as well
...
Add support to look for and use the EGL context in Windows if it was activated
instead of desktop OpenGL.
GstGL may have been built with or without EGL/libANGLE support, so if it were,
check in GstGL whether we have gst_gl_display_new_with_type() to create a
GstGLDisplay that is of the GST_GL_WINDOW_WIN32 type when we are using
Desktop OpenGL (WGL), otherwise we show messages indicating that envvars
need to be set to initialize GstGL properly.
Due to a bug in GstGL, the GstGLContext can only be set up successfully
if one of the following is true:
* An OpenGL 3.x or later emulator, such as Mesa is used (for WGL)
* The latest GstGL master is being used, at the time of writing (for
WGL)
* GTK, libepoxy and GstGL are all built only with WGL support (for WGL)
* EGL is being used in GTK at runtime
Special thanks to Matthew Waters for the help during the process.
2021-05-24 19:04:14 +08:00
Chun-wei Fan
52d1c0c271
media/gstreamer: Support using GL for video for Windows
...
Add support to share the WGL context in GDK with the WGL context in GStreamer,
so that we can also use OpenGL in the gstreamer media backend to playback
videos. For now OpenGL/ES is not supported for this under Windows.
The process of setting this up in Windows is a little bit more involved, as:
* The OpenGL support in GstGL requires a GL 4.1 Core context, but we may just
get the GL version from wglCreateContextAttribsARB() that we pass into the
attributes, which is 3.2 by default. So, try to ask for a 4.1 Core context
first if we are asking for anything less.
* There is only one GstDisplay available for Windows, so we just use
gst_gl_display_new().
* We must explicitly tell libepoxy that we are using wglMakeCurrent() outside
of libepoxy that is being used in GdkGL, otherwise we would end up crashing
as the GL/WGL function pointers would become invalid.
* We must also deactivate temporarily the underlying WGL context that was made
current by gdk_gl_context_make_current() so that when
gst_gl_display_create_context() calls wglShareLists(), we won't get bitten
by error 0xaa (resource busy), as some drivers don't handle this well when
the GL context is current in another thread.
For the last two points we make use of macros defined by the platforms that the
build is done for to help us carry out the necessary tasks as needed.
Thanks to Matthew Waters for the info on integrating GstGL and windowing
toolkits on Windows.
2021-05-24 16:36:40 +08:00
Chun-wei Fan
943559da67
gtk/meson.build: Fix linking on Visual Studio 2013
...
Visual Studio 2013's linker does not suport `/WHOLEARCHIVE:`, so just
explicitly extract the objects from the static libraries that will
form the final GTK DLL.
2021-05-24 10:30:34 +08:00
Matthias Clasen
21057fb857
Merge branch 'focusable-fixes' into 'master'
...
label: Fix mnemonic activation
Closes #3965
See merge request GNOME/gtk!3578
2021-05-23 15:53:27 +00:00
Matthias Clasen
281bb5e2c4
treeviewcolumn: Use focusable when we mean it
...
The focusable property has taken over the role that
can-focus had in GTK 3.
2021-05-23 11:20:00 -04:00
Matthias Clasen
eb61f0fc63
treeexpander: Use focusable where we mean it
...
This does not fix keyboard activation for tree expanders,
but it is more correct than using can-focus.
2021-05-23 11:20:00 -04:00
Matthias Clasen
105b12f807
togglebutton: Fix mnemonic activation
...
We want to grab the focus when we're focusable, so
look at the focusable property.
2021-05-23 11:20:00 -04:00
Matthias Clasen
882893259d
floxbox: Fix focus navigation
...
We want to find focusable children, so we need to look at
the focusable property, not at can-focus. This is a change
from GTK 3, where can-focus was the correct property to
look at.
2021-05-23 11:20:00 -04:00
Matthias Clasen
052917a67d
label: Fix mnemonic activation
...
The intention of the code is to find a focusable ancestor,
so it needs to look at the focusable property, not at
can-focus. This is a change from GTK 3, where can-focus
was the correct property to look at.
Fixes : #3965
2021-05-23 11:19:40 -04:00
Matthias Clasen
226edf1f91
Merge branch 'matthiasc/for-master' into 'master'
...
demos: Clean up doc comments
See merge request GNOME/gtk!3574
2021-05-23 02:14:01 +00:00
Matthias Clasen
be944053e0
docs: More syntax fixes
...
The syntax for interface links is [iface@...], not
[interface@...].
2021-05-22 21:21:10 -04:00
Matthias Clasen
71aac48042
docs: More syntax fixes
...
[`func@Foo`] is not the right link syntax either.
2021-05-22 21:20:10 -04:00
Matthias Clasen
8bcc6b1d96
docs: Fix up syntax
...
There's no [type_func@...[ syntax, it is all [func@...].
2021-05-22 20:56:14 -04:00
Matthias Clasen
40f292cb13
docs: Sync up debug flag information
2021-05-22 20:46:59 -04:00
Matthias Clasen
601a8de422
treemodel: Cosmetic docs changes
2021-05-22 20:46:59 -04:00
Matthias Clasen
fe564318b6
sortlistmodel: Cosmetic docs changes
2021-05-22 20:46:16 -04:00
Matthias Clasen
09244edc15
expression: Cosmetic docs changes
2021-05-22 17:28:10 -04:00
Matthias Clasen
f5f8f83e3e
textbuffer: Cosmetic docs changes
2021-05-22 17:25:27 -04:00
Matthias Clasen
74a39bbae0
textview: Cosmetic docs changes
2021-05-22 17:25:27 -04:00
Matthias Clasen
3ab34ffdc0
text: Cosmetic docs fixes
2021-05-22 17:25:26 -04:00
Matthias Clasen
13a93489b7
widget: Cosmetic docs changes
2021-05-22 17:25:26 -04:00
Matthias Clasen
b35e02db20
shortcutscontroller: Cosmetic docs changes
2021-05-22 17:25:26 -04:00
Matthias Clasen
6cb4dda5d6
gdk: Cosmetic docs changes
2021-05-22 17:25:26 -04:00
Matthias Clasen
2d12a7d9ee
directorylist: Cosmetic docs changes
2021-05-22 17:25:26 -04:00
Matthias Clasen
9a7e4f4304
eventcontroller: Cosmetic docs changes
2021-05-22 17:25:26 -04:00
Matthias Clasen
876104835e
sorter: Cosmetic docs changes
2021-05-22 17:25:26 -04:00
Matthias Clasen
786e28fec0
filter: Cosmetic docs changes
2021-05-22 17:25:26 -04:00
Matthias Clasen
b617ba1c82
docs: Refer to backend APIs
...
Add links to the backend api docs.
2021-05-22 17:25:26 -04:00
Matthias Clasen
252edbdbc6
docs: Fix a typo
2021-05-22 17:25:26 -04:00
Matthias Clasen
0bba3610c5
docs: Avoid stairstepping
...
If you don't put empty lines between the items in a
definition list, markdown helpfully stairsteps them.
We don't want that!
2021-05-22 17:25:26 -04:00
Matthias Clasen
fc9f580fd3
docs: Update GSK_RENDERER docs
...
This did not mention the opengl and ngl values yet.
2021-05-22 17:25:26 -04:00
Matthias Clasen
91f7b9663f
gtk: Clean up docs syntax
...
Replace leftover gtk-doc syntax (#Type) with backquotes.
2021-05-22 17:25:26 -04:00
Matthias Clasen
2d266d107b
gsk: Clean up docs syntax
...
Replace leftover gtk-doc syntax (#Type) with backquotes.
2021-05-22 17:25:26 -04:00
Matthias Clasen
fff2b3c710
gdk: Clean up docs syntax
...
Replace leftover gtk-doc syntax (#Type) with backquotes.
2021-05-22 17:25:26 -04:00
Benjamin Otte
5af6c37f8c
x11: Be more careful with NVIDIA workaround
...
Check that we are indeed running inside an Xorg server before enabling
the workaround.
XWayland or other nested X servers deadlock when that workaround is
applied.
2021-05-22 01:43:31 +02:00
Matthias Clasen
2d0957b732
docs: Clean up docs syntax
...
Replace leftover gtk-doc syntax (#Type) with backquotes.
2021-05-21 15:34:47 -04:00
Matthias Clasen
0996552708
demos: Clean up doc comments
...
These don't show up anywhere, but might still clean
them up.
2021-05-21 13:53:38 -04:00
Piotr Drąg
620787e56b
Update POTFILES.in
2021-05-21 14:28:58 +02:00
Matthias Clasen
f5bd9f721c
Merge branch 'wip/exalm/check-activate' into 'master'
...
checkbutton: Don't allow to uncheck radios by activating them
See merge request GNOME/gtk!3569
2021-05-21 02:06:58 +00:00
Matthias Clasen
345edb8a89
Merge branch 'doc-tweaks' into 'master'
...
Fix documentation syntax
See merge request GNOME/gtk!3572
2021-05-21 01:18:58 +00:00
Matthias Clasen
4a0d3d7acc
docs: Reduce redundancy
...
Remove a boatload of "or %NULL" from nullable parameters
and return values. gi-docgen generates suitable text from
the annotation that we don't need to duplicate.
This adds a few missing nullable annotations too.
2021-05-20 20:45:06 -04:00
Matthias Clasen
7fe0610b68
introspection: Stop using allow-none
...
allow-none has been deprecated for a long time
already. Instead use optional and nullable everywhere.
2021-05-20 19:17:49 -04:00
Matthias Clasen
8ba16eb4f1
Documentation fixes
...
Mostly fixing up indentation of continuation lines,
and other small cleanups.
2021-05-20 19:17:49 -04:00
Matthias Clasen
ab6a5be0f8
Fix documentation syntax
...
Properties use : in their link syntax.
2021-05-20 19:16:59 -04:00
Matthias Clasen
94b0907534
Merge branch 'wip/exalm/switch-icons-2' into 'master'
...
icons: Fix switch-off icon
See merge request GNOME/gtk!3571
2021-05-20 22:49:29 +00:00
Alexander Mikhaylenko
0017b4b69a
icons: Fix switch-off icon
...
It wasn't converted to paths and so wasn't rendered correctly.
2021-05-20 23:36:30 +05:00
Matthias Clasen
430be6f2a9
Merge branch 'popover-docs' into 'master'
...
popover: Update docs
Closes #3960
See merge request GNOME/gtk!3570
2021-05-20 13:55:47 +00:00
Matthias Clasen
bff7ac4a1d
popover: Update docs
...
Remove mention of show/hide animations, and mention
cascading close instead.
Fixes : #3960
2021-05-20 09:18:47 -04:00
Alexander Mikhaylenko
fb6c6c85bf
checkbutton: Don't allow to uncheck radios by activating them
...
Do the same check as when clicking.
2021-05-20 14:38:33 +05:00
Yuri Chornoivan
894adea2f7
Update Ukrainian translation
2021-05-20 07:29:07 +00:00
Yuri Chornoivan
0e1d6fbbbc
Update Ukrainian translation
2021-05-20 07:27:43 +00:00
Alexander Mikhaylenko
bad01edd2c
checkbutton: Sync the indicator state with the widget
...
Clicking the whole check button toggles it, so make sure the hover and
active states are propagated to the indicator like in GTK3.
2021-05-20 12:17:45 +05:00
Matthias Clasen
e9ca8d689f
Merge branch 'bilelmoussaoui/gdk-return-error-annotation' into 'master'
...
gdk: annotate Content Serialize/Deserialize return_error
See merge request GNOME/gtk!3567
2021-05-20 03:54:15 +00:00
Bilal Elmoussaoui
c5eb2f5d16
gdk: annotate Content Serialize/Deserialize return_error
2021-05-19 18:10:34 +00:00
Benjamin Otte
7db87a8889
Merge branch 'fix-gst-media-file' into 'master'
...
gtkgstmediafile: Remove media-info-updated callback
Closes #3913
See merge request GNOME/gtk!3565
2021-05-19 16:22:35 +00:00
Ivan Molodetskikh
12a9a0faf7
gtkgstmediafile: Remove media-info-updated callback
...
Instead, rely on position-updated which is also called always, and also
a little later than media-info-updated, giving GstPlayer time to figure
out more of the video info. Tested on local and remote mount videos,
images, sound files.
Works around / fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/3913 ,
https://gitlab.gnome.org/GNOME/gtk/-/issues/3914 .
2021-05-19 18:55:37 +03:00
Matthias Clasen
fc321d8282
Merge branch 'matthiasc/for-master' into 'master'
...
Actually pass the devel profile to flatpak builds
See merge request GNOME/gtk!3563
2021-05-18 11:42:33 +00:00
Matthias Clasen
7d27c615b7
Actually pass the devel profile to flatpak builds
...
I added that to the manifests, and did not notice that
we do the last build step manually :(
2021-05-18 07:38:18 -04:00
Matthias Clasen
7de266a620
Merge branch 'wip/carlosg/sequence-accepted-in-group' into 'master'
...
gtkgesture: Apply gesture group state after setting up sequence
Closes #3946
See merge request GNOME/gtk!3560
2021-05-18 10:58:19 +00:00
Matthias Clasen
4cbc5ed20a
Merge branch 'fix-gen-demo-conf' into 'master'
...
Fix generating demo_conf.h on builds without GIT in PATH
See merge request GNOME/gtk!3562
2021-05-18 10:31:57 +00:00
Chun-wei Fan
c18a1ac1a1
gen-demo-header.py: Fix running without git
...
The script assumes that the git program is in the PATH which may not be always
the case, so if git was not found, fallback to the former behavior of making
VCS_TAG an empty string if the profile option was not set to 'devel'.
Also fix the call to the script so that we do indeed call GIT on the source GIT
repo so that we can get the right short SHA1 sum.
Re-organize the code a bit in the process, so that things seem cleaner.
2021-05-18 11:25:20 +08:00
Matthias Clasen
ab6e4bfc8d
Merge branch 'wip/carlosg/reset-after-grab' into 'master'
...
Fixes to GTK grab notification
Closes #3942
See merge request GNOME/gtk!3561
2021-05-17 23:35:26 +00:00
Carlos Garnacho
6b7b232114
gtkwindow: Fix "shadowed" checks for GTK grabs
...
We iterate here from the target widget up the toplevel checking
for the previous and new grab, there's however 2 bugs here:
- The check for is_shadowed was different to the check for was_shadowed
- The loop started with the assumption that the widgets did not hold
a grab, just to change it if the grab widget was found. (or maybe
it's the other way around? it's unclear with the differing checks
for past/present state).
Make these checks consistent, and ensure we start with the right
assumption for the past/present grabbing state, and accounting that
new/old grab widgets may or may not be part of the pick stack.
2021-05-18 00:16:55 +02:00
Carlos Garnacho
0a5d21ca9e
gtkwindow: Rename function
...
With gtk_grab_notify_foreach() just taking care of emitting crossing
notifications due to the GTK grab change, rename it to a more apt
gtk_synthesize_grab_crossing().
2021-05-18 00:16:48 +02:00
Carlos Garnacho
f003a4c6cc
gtkwindow: Simplify GTK grab notification
...
The _gtk_widget_grab_notify() function just (maybe) did a) reset
controllers and b) hide toplevels. The second part was a testing
remnant introduced in commit 024d832d94 , not part of the original
fix.
Do the former more concisely, called from the place where we figure
out whether a widget's ability to receive events changed due to
GTK grabs. It's across those changes that we are interested in
resetting the controllers.
With the gestures being reset both ways, GtkWindowHandle (and
probably other) gestures are now able to reset after a GTK grab
takes input away (e.g. GtkMenuButton). This could be seen as
a sudden jump the next time they'd be dragged with the mouse,
as the gesture would "resume" the previous interaction.
Fixes: https://gitlab.gnome.org/GNOME/gtk/-/issues/3942
2021-05-18 00:16:48 +02:00
Carlos Garnacho
53df32e6cf
gtkgesture: Apply gesture group state after setting up sequence
...
When a new sequence is added to a GtkGesture, its state is looked
in other gestures in the same group, and made to match in this
gesture. This however happened a bit too early, before the
gesture touchpoint was fully set up. As this may result in signal
emission and whatnot, it's a good idea to make it happen with a
fully set up touchpoint.
Fixes: https://gitlab.gnome.org/GNOME/gtk/-/issues/3946
2021-05-18 00:16:12 +02:00
Matthias Clasen
8670034c86
Merge branch 'ebassi/rev-parse-fallback' into 'master'
...
build: Check CI envvars before rev-parse
See merge request GNOME/gtk!3559
2021-05-17 21:13:04 +00:00
Emmanuele Bassi
c1fbf654a0
build: Check CI envvars before rev-parse
...
The CI pipeline does not do a full clone, so we cannot use `git
rev-parse` to get the short SHA checksum for the current commit.
Of course, since nothing's ever easy, we cannot use vcs_tag() with a
custom command, so we need to generate our out `demo_conf.h` header
straight from a script.
2021-05-17 21:34:13 +01:00
Matthias Clasen
9066078928
Merge branch 'wip/exalm/activatable2' into 'master'
...
theme: Specificity bump for dropdowns
See merge request GNOME/gtk!3558
2021-05-17 20:10:12 +00:00
Alexander Mikhaylenko
4f16e661cf
theme: Specificity bump for dropdowns
...
Fix a fallout from d56711b5d8
2021-05-17 23:26:08 +05:00
Matthias Clasen
45b85767c4
Merge branch 'wip/exalm/activatable' into 'master'
...
listitemwidget: Have .activatable style class if the item is activatable
See merge request GNOME/gtk!3557
2021-05-17 15:56:02 +00:00
Alexander Mikhaylenko
d56711b5d8
listitemwidget: Have .activatable style class if the item is activatable
...
Match GtkListBox, so it's possible to use the same styles for them.
Update GtkListView and GtkGridView docs to reflect that, fix a few gtk-doc
formatting leftovers along the way.
2021-05-17 18:10:35 +05:00
Matthias Clasen
df28a57ae3
Merge branch 'matthiasc/for-master' into 'master'
...
ngl: Add padding between cached glyphs
See merge request GNOME/gtk!3555
2021-05-17 12:12:22 +00:00
Matthias Clasen
04bac8ef2a
testsuite: Run some installed tests exclusively
...
My suspicion is that the clipboard (and some other)
installed test interferes with others, because the
clipboard is a shared resource.
2021-05-17 07:16:42 -04:00
Matthias Clasen
7ad193787e
Merge branch 'wip/exalm/emojichooser' into 'master'
...
emojichooser: Set selection-mode=none on the toolbar flowbox
See merge request GNOME/gtk!3556
2021-05-17 11:10:33 +00:00
Alexander Mikhaylenko
27e662cfd1
emojichooser: Set selection-mode=none on the toolbar flowbox
...
Selection is never used there, avoid unwanted selected states if clicking
outside the buttons.
2021-05-17 14:09:03 +05:00
Pawan Chitrakar
661a572d82
Update Nepali translation
...
(cherry picked from commit 597a624fc5 )
2021-05-16 07:41:56 +00:00
Matthias Clasen
66b4f0cac4
ngl: Reuse texture coordinates
...
When uploading glyphs, reuse the position that
we get from gsk_ngl_texture_library_pack, instead
of recomputing it.
2021-05-15 22:23:14 -04:00
Matthias Clasen
81e0206465
ngl: Be consistent about padding
...
Make gsk_ngl_texture_library_pack always return
the position including the padding. And compute
texture coordinates accurately in all cases (we
were fudging the padding for standalone textures.
2021-05-15 22:21:26 -04:00
Matthias Clasen
cb1babeeba
ngl: Add padding between cached glyphs
...
Without this, adjacent items in the cache sometimes
bleed into the texture for a glyph.
2021-05-15 22:15:05 -04:00
Matthias Clasen
67dc778b8f
Merge branch 'gst-egl-optional' into 'master'
...
meson: Do not enforce GStreamer EGL lib
See merge request GNOME/gtk!3554
2021-05-15 14:21:09 +00:00
Rafał Dzięgiel
bbd4ee2986
meson: Do not enforce GStreamer EGL lib
...
GStreamer EGL headers are handled by GstGL lib.
No need to additionally import them.
2021-05-15 14:03:23 +02:00
Kjartan Maraas
42b2eae532
Update Norwegian Bokmål translation
...
(cherry picked from commit d952fa48e7 )
2021-05-15 07:35:38 +00:00
Matthias Clasen
0902f45d71
Merge branch 'gst-x11-egl' into 'master'
...
gtkgstsink: Support EGL under x11
See merge request GNOME/gtk!3553
2021-05-14 19:57:05 +00:00
Rafał Dzięgiel
c51eb7665e
gtkgstsink: Support EGL under x11
...
Add support for EGL under x11 windowing system to GStreamer sink
2021-05-14 19:29:00 +02:00
Matthias Clasen
1a426d6fff
Merge branch 'ebassi/issue-3948' into 'master'
...
x11: Loosen the match for the NVIDIA driver
Closes #3948
See merge request GNOME/gtk!3549
2021-05-14 10:50:59 +00:00
Matthias Clasen
07b5072c9c
Merge branch 'matthiasc/for-master' into 'master'
...
inspector: Use new get_egl_display apis
See merge request GNOME/gtk!3546
2021-05-14 00:40:05 +00:00
Matthias Clasen
3a0febfe79
Merge branch 'offscreen-fixes' into 'master'
...
Add some more transform tests
See merge request GNOME/gtk!3551
2021-05-14 00:38:52 +00:00
Matthias Clasen
8e7bc8d742
Improve transformed offscreen rendering
...
Preserve the scale for 2D transforms to
avoid a pixellated appearance.
2021-05-13 19:37:16 -04:00
Matthias Clasen
809299f9e4
Add some more transform tests
...
Test that gsk_transform_to_affine works.
2021-05-13 19:37:16 -04:00
Matthias Clasen
c391cf38e2
testzoom: Fix the in-place rotate
2021-05-13 19:37:16 -04:00
Matthias Clasen
8c75e6896e
inspector: Use new get_egl_display apis
...
This makes the code a bit more concise.
Also, get WGL information when we are using it.
2021-05-13 15:25:18 -04:00
Emmanuele Bassi
b3d6928f35
x11: Pair eglInitialize with eglTerminate
...
If we bail out after EGL initialization we want to go back to a stable
state and not leave EGL hanging.
2021-05-13 18:23:50 +01:00
Emmanuele Bassi
3d8ba93f59
x11: Loosen the match for the NVIDIA driver
...
It seems nVidia puts a different string in the GL_VENDOR than the one it
uses for GLX.
2021-05-13 18:22:30 +01:00
Emmanuele Bassi
889bf83020
Merge branch 'ebassi/boost-url' into 'master'
...
Update the URL for the Boost archive
See merge request GNOME/gtk!3548
2021-05-13 11:47:28 +00:00
Emmanuele Bassi
6c63f7b0e2
Update the URL for the Boost archive
...
The old URL seems to have failed, and now it returns 301.
Use the URL from the Boost website.
2021-05-13 11:29:22 +01:00
Matthias Clasen
3872c3a127
Merge branch 'fix-picking-with-transforms' into 'master'
...
Fix picking with transforms
See merge request GNOME/gtk!3547
2021-05-13 10:09:37 +00:00
Matthias Clasen
5be785bff8
Add a transform test
...
This reveals some issues with scale handling.
2021-05-12 21:50:32 -04:00
Matthias Clasen
bf454e948d
Fix picking with transforms
...
When transforms include scales, we weren't picking
children properly. The special-case in gtk_widget_do_pick
only applies to 2D translations.
2021-05-12 20:58:16 -04:00
Emmanuele Bassi
e66ec84c1e
Merge branch 'ebassi/issue-3945' into 'master'
...
docs: Fix indentation of the arguments
Closes #3945
See merge request GNOME/gtk!3544
2021-05-12 20:12:13 +00:00
Matthias Clasen
6537728c7b
Merge branch 'wip/chergert/fix-gi-typo' into 'master'
...
gdk: fix typo in G-I attribute
See merge request GNOME/gtk!3545
2021-05-12 18:43:33 +00:00
Matthias Clasen
95f3f8f3c4
Merge branch 'win32.egl.getter' into 'master'
...
Win32: Add EGLDisplay getter
See merge request GNOME/gtk!3543
2021-05-12 18:42:35 +00:00
Christian Hergert
ae9b4f8940
gdk: fix typo in G-I attribute
2021-05-12 10:53:56 -07:00
Emmanuele Bassi
8ef353a970
docs: Fix indentation of the arguments
...
The indentation of new lines inside documentation blurbs must be smaller
than 4 spaces, otherwise the Markdown parser will consider the line to
be part of a pre-formatted code block.
Fixes : #3945
2021-05-12 17:38:07 +01:00
Chun-wei Fan
6d33e9058c
Win32: Add EGLDisplay getter
...
Like what was done for Wayland and X11, add an API to retrieve the EGLDisplay
if one is being used in place of WGL.
2021-05-12 22:16:56 +08:00
Matthias Clasen
78852b181a
Merge branch 'ebassi/egl-display-get' into 'master'
...
Add backend-specific getter for the EGLDisplay
See merge request GNOME/gtk!3542
2021-05-11 12:42:50 +00:00
Emmanuele Bassi
2588f9cee6
wayland: Add EGLDisplay getter
...
Getting an EGLDisplay object is messy; might as well expose the function
we use internally to save some time, just like we did for the X11
backend.
2021-05-11 12:46:03 +01:00
Emmanuele Bassi
abc2d7e4a9
x11: Add EGLDisplay getter
...
Getting an EGLDisplay object is messy; might as well expose the function
we use internally to save some time.
2021-05-11 12:42:16 +01:00
Emmanuele Bassi
6189e343f3
build: Do not use C arguments with C++
...
Otherwise the C++ compiler will start to complain.
The C++ keyword test does not need additional warnings.
2021-05-11 12:24:34 +01:00
Matthias Clasen
8bfa182ed9
Merge branch 'misc-inspector-things' into 'master'
...
inspector: Show text direction
See merge request GNOME/gtk!3541
2021-05-11 10:51:31 +00:00
Matthias Clasen
ea162ed016
inspector: Avoid a crash with GL variants
...
When configuring the inspector display, preserve
debug flags that affect which GL variant we pick.
Otherwise, we may end up with a GLX context on the
default display, and an EGL context on the inspector
one. This hopelessly confuses libepoxy, and things
don't go well when that happens.
2021-05-10 21:25:08 -04:00
Matthias Clasen
e2aa161590
inspector: Show EGL info for X11 as well
2021-05-10 21:24:50 -04:00
Matthias Clasen
a723baec4b
inspector: Show text direction
...
This is not a property, so show it on the misc tab.
2021-05-10 20:55:43 -04:00
Emmanuele Bassi
6120519e8e
Merge branch 'ebassi/egl-x11' into 'master'
...
Prefer EGL to GLX for the GL support on X11
See merge request GNOME/gtk!3540
2021-05-10 22:51:11 +00:00
Emmanuele Bassi
69856a9aac
x11: Don't update GLX visuals with EGL
...
We're going to get into a messy situation, with both GLX and EGL
initialized.
If we're already using EGL, skip the whole cache.
2021-05-10 21:19:14 +01:00
Matthias Clasen
564d835fba
Merge branch 'broadway-display-scale' into 'master'
...
broadway: Add a setter for display scale
Closes #3934
See merge request GNOME/gtk!3538
2021-05-10 20:11:38 +00:00
Emmanuele Bassi
c35a6725b9
x11: Always fall back to GLX on NVIDIA
...
At least until we can guarantee that EGL-X11 works fine there.
2021-05-10 20:44:35 +01:00
Emmanuele Bassi
a57f79006a
x11: Move the damage fences into the GLX code
...
It's GLX-specific anyway, there's no need to complicate things by having
half the code in the generic path, and half in the GLX one.
2021-05-10 20:44:35 +01:00
Emmanuele Bassi
6600b0b507
x11: Add debug toggle for preferring GLX
...
Mostly as a way to compare the EGL and GLX implementations.
2021-05-10 20:44:35 +01:00
Emmanuele Bassi
9a19e3c741
x11: Add profiler marks for SwapBuffers
2021-05-10 20:44:35 +01:00
Emmanuele Bassi
8924d614c0
x11: Use EGL for GL support
...
This makes the X11 backend similar to the Wayland one, when it comes to
OpenGL.
Fall back to GLX only if EGL support is not available.
2021-05-10 20:44:35 +01:00
Emmanuele Bassi
03f76eccf5
x11: Decouple GLX from GdkX11GLContext
...
If we want to add an EGL implementation for the X11 backend, we are
going to need to move the GLX bits into their own class. The first step
is to declare GdkX11GLContext as an abstract type, and then subclass it
into a GdkX11GLContextGLX type, which includes the whole GLX
implementation.
2021-05-10 20:44:35 +01:00
Matthias Clasen
b13c2e17f1
inspector: Support scale changes on Broadway
2021-05-10 10:55:41 -04:00
Matthias Clasen
7c1c8c53e7
Merge branch 'ci-more-clang' into 'master'
...
ci: Add clang-extra-tools to the image
See merge request GNOME/gtk!3539
2021-05-10 13:26:54 +00:00
Matthias Clasen
497b843e76
ci: Add clang-extra-tools to the image
...
Hurray for bite-size packages! Splitting
this off broke our style check in ci.
2021-05-10 08:52:12 -04:00
Matthias Clasen
7745f67583
broadway: Add a setter for display scale
...
This is useful when using Broadway as a headless
display server.
Fixes : #3934
2021-05-10 07:19:26 -04:00
Matthias Clasen
374225ae6a
Cosmetics
2021-05-09 19:32:48 -04:00
Matthias Clasen
7259be35b0
Merge branch 'file-replace-trap' into 'master'
...
print-editor: Fix saving
See merge request GNOME/gtk!3536
2021-05-09 23:06:49 +00:00
Matthias Clasen
1601e204f4
Merge branch 'wip/exalm/image-button' into 'master'
...
Ensure consistent header bar buttons in the demo and tests
See merge request GNOME/gtk!3537
2021-05-09 23:06:25 +00:00
Alexander Mikhaylenko
43e33b2990
test: Ensure .image-button on header bar buttons
2021-05-09 20:55:26 +05:00
Alexander Mikhaylenko
7ebd9291d9
demo: Ensure .image-button on header bar buttons
2021-05-09 20:53:05 +05:00
Alexander Mikhaylenko
5d59415c2d
test: Use more appropriate back/forward icons
2021-05-09 20:52:48 +05:00
Alexander Mikhaylenko
c5d2d89930
demo: Use more appropriate back/forward icons
2021-05-09 20:35:39 +05:00
Matthias Clasen
0108ffe059
inspector: Fix saving css
...
g_file_replace_contents() does not accept -1
as length, unlike similar apis.
2021-05-09 11:19:43 -04:00
Matthias Clasen
087935f160
print-editor: Fix saving
...
g_file_replace_contents() does not accept -1 as
length, unlike similar apis.
2021-05-09 11:19:43 -04:00
Matthias Clasen
fef9f1187d
Merge branch 'matthiasc/for-master' into 'master'
...
fontbutton: Quote font family names
See merge request GNOME/gtk!3534
2021-05-09 14:43:03 +00:00
Matthias Clasen
83c9a24855
Merge branch 'wip/exalm/actionbar' into 'master'
...
GtkActionBar spacing fixes
See merge request GNOME/gtk!3535
2021-05-09 14:40:19 +00:00
Alexander Mikhaylenko
435a8f6337
theme: Fix GtkActionBar spacing
2021-05-09 17:01:36 +05:00
Alexander Mikhaylenko
2c8e4573f2
actionbar: Fix the css node docs
2021-05-09 16:55:48 +05:00
Alexander Mikhaylenko
b45721373a
action-bar: Add start and end style classes to GtkActionBar boxes
...
Make it possible to add spacing to them from the theme without affecting
the center child should it happen to be a box.
2021-05-09 16:54:59 +05:00
Matthias Clasen
e0ebf4e401
fontbutton: Quote font family names
...
Otherwise, spaces in family names will trip up
the css parser.
2021-05-08 20:54:50 -04:00
Matthias Clasen
dc878f24d2
Merge branch 'emoji-full-locale' into 'master'
...
emoji: Try to load emoji data using both language and territory
See merge request GNOME/gtk!3531
2021-05-08 02:07:18 +00:00
Matthias Clasen
be1f9b2cb0
Merge branch 'wip/carlosg/map-emulated-moveresize-window' into 'master'
...
gdk/x11: Ensure to map the non-ewmh moveresize emulation window before use
See merge request GNOME/gtk!3529
2021-05-07 14:55:16 +00:00
Marco Trevisan (Treviño)
0769dfbd32
emoji: Try to load emoji data using both language and territory
...
When loading the emoji data we just try to get the data for a language
while there may be territory specializations and emojibase provides
them.
So, split the loading function and try to load the data for the fully
defined language string (i.e. `it-ch`) before loading the generic one
for the language (i.e. `it`) and eventually falling back to the generic
english.
2021-05-07 16:10:29 +02:00
Carlos Garnacho
081e127377
gdk/x11: Ensure to map the non-ewmh moveresize emulation window before use
...
Otherwise, we don't deem it as able to be grabbed, which we intend to do
immediately after.
2021-05-07 15:51:52 +02:00
Matthias Clasen
17a799aeb2
Merge branch 'matthiasc/for-master' into 'master'
...
Add some calendar tests
See merge request GNOME/gtk!3528
2021-05-07 12:57:55 +00:00
Matthias Clasen
a3f5283018
Add some calendar tests
...
Check that the getters and setters work as documented.
This tests the fix in 1f8985e476 .
2021-05-07 07:52:11 -04:00
Matthias Clasen
633d783f0c
Merge branch 'carlosgc/calendar-day' into 'master'
...
calendar: value of day property is shifted by 1
See merge request GNOME/gtk!3524
2021-05-07 11:42:59 +00:00
Matthias Clasen
451a5fb6d4
Merge branch 'fix-3918' into 'master'
...
demos: Mark non-static signal handler symbols for export
Closes #3918
See merge request GNOME/gtk!3523
2021-05-07 11:08:57 +00:00
Matthias Clasen
3ad7d304bd
Merge branch 'update-emoji-data' into 'master'
...
emoji: Update data to CLRD v39
See merge request GNOME/gtk!3520
2021-05-07 11:05:46 +00:00
Carlos Garcia Campos
7b2b8b86e1
calendar: do not allow to set 0 as day
...
We no longer unselect the current day when 0 is set, so update the
documentation and the property definition.
2021-05-07 12:13:49 +02:00
Carlos Garcia Campos
1f8985e476
calendar: value of day property is shifted by 1
...
The day is a number between 1 and 31 and that's what we get from
GDateTime.
2021-05-07 11:10:36 +02:00
Chun-wei Fan
efb875daef
demos: Mark non-static signal handler symbols for export
...
The symbols in the .ui files for the signal handlers and functions must be
exported so that the system can pick them up during execution.
Fixes #3918 .
2021-05-07 10:38:02 +08:00
Matthias Clasen
59cc3a9f86
Merge branch 'hidden-mnemonics-fix' into 'master'
...
label: Make hidden mnemonics work again
See merge request GNOME/gtk!3518
2021-05-07 00:34:33 +00:00
Matthias Clasen
febd143ac8
Merge branch 'emoji-data-prefix-fix' into 'master'
...
emoji: Use a portable and configuration-dependent path to load the data
See merge request GNOME/gtk!3522
2021-05-06 15:33:15 +00:00
Matthias Clasen
e00785e958
Merge branch 'macos' into 'master'
...
Fix building both X11 and Quartz backends on macOS
See merge request GNOME/gtk!3508
2021-05-06 15:26:49 +00:00
Marco Trevisan (Treviño)
4a4525a65d
emoji: remove duplicated include
2021-05-06 16:00:06 +02:00
Marco Trevisan (Treviño)
c98dd1afb9
emoji: Use a portable and configuration-dependent path to load the data
...
Load the emojis data in all the platforms, respecting the configured
GTK_DATA_PREFIX
2021-05-06 16:00:06 +02:00
Dan Cîrnaț
12d591178e
Fix compilation of c++ test: cpp_args
...
The correct meson argument for c++ is cpp_args.
Remove unnecessary(?) "-Idummy-headers" - breaks build
2021-05-06 10:38:41 +02:00
Dan Cîrnaț
bd7b29a6c4
Only compile gtkmountoperation-stub if the X11 backend is not enabled
2021-05-06 10:38:41 +02:00
Dan Cîrnaț
13b94dab10
Conditional check for gdesktopappinfo header
...
GDesktopAppInfo is not available on macOS and needs to be disabled
2021-05-06 10:38:41 +02:00
Marco Trevisan (Treviño)
ba3cbac21a
emoji: Update data to CLRD v39
...
This is based on version 6.2.0 of emojibase, containing CLRD 39
http://cldr.unicode.org/index/downloads/cldr-39
https://github.com/milesj/emojibase/blob/b3c9a78/packages/data/CHANGELOG.md
2021-05-06 05:08:37 +02:00
Matthias Clasen
d94c386320
label: Make hidden mnemonics work again
...
The change in 875a92b95f made labels strip
out underlines earlier, but overlooked that this made
mnemonics not work before the timeout to show them
has passed. That was unintentional. Make mnemonics
work regardless of their visibility, again.
2021-05-05 22:55:52 -04:00
Matthias Clasen
4e2a263c1f
Merge branch 'introspection-test' into 'master'
...
Add an introspection api test
See merge request GNOME/gtk!3514
2021-05-06 00:52:06 +00:00
Matthias Clasen
6a24e0c7c3
Add an introspection api test
...
Every beginning is small... just check one constant for now.
2021-05-05 19:18:32 -04:00
Matthias Clasen
c8eeb46aa5
Merge branch 'update-ci-to-f34' into 'master'
...
WIP ci: Update the image to Fedora 34
See merge request GNOME/gtk!3516
2021-05-05 23:17:07 +00:00
Matthias Clasen
d143f76568
Merge branch 'msvc-ci' into 'master'
...
ci: Add MSVC build
See merge request GNOME/gtk!3486
2021-05-05 23:16:39 +00:00
Matthias Clasen
930ff499ee
Confine -mf16c to a single source file
...
We can't use this flag for any code that may get run
outside the __builtin_cpu_supports() check, and meson
doesn't allow per-file cflags. So we have to split this
code off into its own static library.
2021-05-05 18:58:23 -04:00
Xavier Claessens
f4dc24c3da
Meson: gdk-pixbuf jpeg/png options changed to feature
2021-05-05 16:40:57 -04:00
Matthias Clasen
399fb76652
ci: Add pygobject to the images
...
This will let us add introspection tests in the future.
2021-05-05 16:31:03 -04:00
Matthias Clasen
de056a3319
ci: Show OS release for our containers
2021-05-05 16:22:32 -04:00
Matthias Clasen
bafa23fa2c
Add debug spew to gdk tests
2021-05-05 15:41:46 -04:00
Matthias Clasen
ab725b4ba9
Merge branch 'wl-phys-transform' into 'master'
...
gdk/wayland: Take transform into account when setting physical size
See merge request GNOME/gtk!3515
2021-05-05 15:23:26 +00:00
Xavier Claessens
d8f44c06e8
ci: Add MSVC build
...
This script is copied from glib CI.
2021-05-05 09:16:36 -04:00
Guido Günther
e40c869d0d
gdk/wayland: Take transform into account when setting physical size
...
Width and height of a GdkMonitor are derived via wl_output which
talks about physical dimensions of a device and compositors usually
implement this as the untransformed values (e.g. weston, wlroots).
Since the GTK client has no way to figure out if a monitor was rotated,
transform the physical dimensions according to the applied wayland
transform to have the physical dimensions match the logical ones.
Mutter flips the physical dimensions itself but doesn't announce the
transform so this shouldn't break anything there.
2021-05-05 14:55:07 +02:00
Matthias Clasen
3591da517a
Disable another font-challenged reftest
2021-05-05 08:17:26 -04:00
Matthias Clasen
014fb41448
Help the compiler out
...
gcc says: error: iteration 2147483649 invokes undefined behavior
[-Werror=aggressive-loop-optimizations]
which of course, never happens because ncols is always >= 2.
Add some assertions to tell the compiler.
2021-05-05 08:17:26 -04:00
Matthias Clasen
24072f26ca
ci: Update the image to Fedora 34
...
This is in preparation to using mutter --headless
for tests.
2021-05-05 08:17:26 -04:00
Matthias Clasen
65017a0031
Merge branch 'bilelmoussaoui/trick-gir-list-position' into 'master'
...
gtk: trick g-ir scanner to add INVALID_LIST_POSITION
See merge request GNOME/gtk!3513
2021-05-05 00:04:16 +00:00
Bilal Elmoussaoui
dc5aab62c8
gtk: trick g-ir scanner to add INVALID_LIST_POSITION
...
without it, the define doesn't get picked in the introspection data
2021-05-05 00:45:21 +02:00
Matthias Clasen
a3cccbeb53
Merge branch 'wip/exalm/text-handles' into 'master'
...
texthandle: Add a contents css node
Closes #3475
See merge request GNOME/gtk!3511
2021-05-04 21:40:48 +00:00
Matthias Clasen
cee6525213
Merge branch 'fix-reftest' into 'master'
...
Fix the icon-effect-missing reftest
See merge request GNOME/gtk!3512
2021-05-04 21:03:30 +00:00
Matthias Clasen
4f81dc1eaf
Fix the icon-effect-missing reftest
...
This was comparing the included image-missing icon
with the one in the current icontheme on the test
system. Works fine as long as we don't change
the icons (which we just did). To avoid this, set
the icontheme to hicolor for this test, which does
not have the image-missing icon, so we end up getting
the builtin icon for both ui files.
2021-05-04 16:21:37 -04:00
Alexander Mikhaylenko
0e58bfe90e
texthandle: Add a contents css node
...
Allow to theme it including using css transforms to avoid having assets.
Fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/3475
2021-05-04 23:53:05 +05:00
Matthias Clasen
e3e0342db7
Merge branch 'wip/exalm/switch-icons' into 'master'
...
icons: Fix switch icon names
Closes #3920
See merge request GNOME/gtk!3509
2021-05-04 16:18:29 +00:00
Matthias Clasen
b1f12a0535
Merge branch 'wip/exalm/icons' into 'master'
...
Update icons from adwaita-icon-theme
Closes #2656
See merge request GNOME/gtk!3510
2021-05-04 16:18:00 +00:00
Alexander Mikhaylenko
60f4b07196
icons: Update from adwaita-icon-theme
...
Also add the missing edit-clear RTL variant.
2021-05-04 19:12:04 +05:00
Alexander Mikhaylenko
4c60dac9cb
icons: Remove media-playback-start-symbolic-rtl
...
See https://gitlab.gnome.org/GNOME/adwaita-icon-theme/-/issues/101
2021-05-04 19:12:04 +05:00
Matthias Clasen
8d14bd3339
Merge branch 'wip/exalm/css-error' into 'master'
...
cssselector: Fix max_selector usage
Closes #3100
See merge request GNOME/gtk!3507
2021-05-04 13:17:53 +00:00
Alexander Mikhaylenko
48d95d2d7a
icons: Fix switch icon names
...
Fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/3920
2021-05-04 17:49:07 +05:00
Matthias Clasen
670a2be782
Merge branch 'test.msvc' into 'master'
...
clipboard-client.c: Include necessary headers for Windows
See merge request GNOME/gtk!3505
2021-05-04 11:53:13 +00:00
Alexander Mikhaylenko
f3633d46ca
cssselector: Fix max_selector usage
...
Reverts 2ae8ace784 other than code style
fixes.
Fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/3100
2021-05-04 12:34:29 +05:00
Chun-wei Fan
e56754d27c
clipboard-client.c: Include necessary headers for Windows
...
We need to include io.h and process.h for close() and exit(), as unistd.h may
not be universally available.
2021-05-04 12:12:50 +08:00
Matthias Clasen
40ebed3a03
4.3.0
2021-05-03 20:31:18 -04:00
Matthias Clasen
14ac4903b6
Fix dist script for theme reorg
2021-05-03 20:31:18 -04:00
Matthias Clasen
da613c504b
Merge branch 'wip/exalm/textview-selection' into 'master'
...
textview: Selection rendering fixes
See merge request GNOME/gtk!3503
2021-05-03 23:55:46 +00:00
Matthias Clasen
7ac3507be2
Merge branch 'gnome-todo-dnd-crash' into 'master'
...
dragsource: Keep the source alive long enough
See merge request GNOME/gtk!3504
2021-05-03 21:35:55 +00:00
Alexander Mikhaylenko
316c783fce
label: Update selection node and redraw on state changes
...
Mirror GtkText and GtkTextView.
2021-05-04 02:29:10 +05:00
Matthias Clasen
9e952bc7ff
dragsource: Keep the source alive long enough
...
When a drop causes the event controller to be finalized
(directly or indirectly), we end up segfaulting while
trying to wrap up the drag operation. So, keep a reference
on the GtkDragSource from when the drag begins to when
it is done.
This fixes a crash in gnome-todo when dragging tasks.
2021-05-03 17:00:17 -04:00
Alexander Mikhaylenko
e4832a9e94
text: Queue redraw on state changes
...
Mirror GtkTextView.
2021-05-04 01:20:53 +05:00
Alexander Mikhaylenko
70ee86c951
textlayout: Clip selection bounds to the line extents
...
The rest of the line will be painted separately.
2021-05-04 01:08:19 +05:00
Matthias Clasen
ed97339ef1
NEWS: Updates
2021-05-03 15:38:11 -04:00
Matthias Clasen
b012a5c67e
Merge branch 'static-analysis-fixes' into 'master'
...
Static analyis fixes
See merge request GNOME/gtk!3501
2021-05-03 19:21:42 +00:00
Matthias Clasen
642f32e14d
Merge branch 'ebassi/for-master' into 'master'
...
Install documentation in the appropriate place
See merge request GNOME/gtk!3408
2021-05-03 19:21:18 +00:00
Matthias Clasen
7b735b88b4
Merge branch 'wip/carlosg/xdg-activation' into 'master'
...
gdk/wayland: Support the xdg-activation wayland protocol
See merge request GNOME/gtk!3502
2021-05-03 19:20:18 +00:00
Alexander Mikhaylenko
167134e1a8
textlayout: Support fully transparent selection text
...
Pango treats 0 alpha value as a unset alpha, so we have to special case it.
2021-05-04 00:16:05 +05:00
Alexander Mikhaylenko
0fa4b7a249
textview: Invalidate selection when its style changes
2021-05-04 00:16:05 +05:00
Alexander Mikhaylenko
f413d5ef22
textlayout: Only special case selection rendering for opaque colors
...
If the selection is partially transparent, it may still be desirable to
see the colors from tags underneath.
2021-05-04 00:16:05 +05:00
Carlos Garnacho
be4216e051
gdk/wayland: Support the xdg-activation wayland protocol
...
This protocol implements the IPC necessary to focus application
windows across launcher/launchee. Add support for it.
2021-05-03 17:20:50 +02:00
Matthias Clasen
fa10264759
updateiconcache: Static analysis fixes
2021-05-03 07:44:38 -04:00
Matthias Clasen
5fbfe5203c
buildertool: Static analysis fixes
2021-05-03 07:44:38 -04:00
Matthias Clasen
f472cb53ae
printbackendlpr: Static analysis fixes
2021-05-03 07:44:38 -04:00
Matthias Clasen
a49ff5a1c4
textbtree: Static analysis fixes
2021-05-03 07:44:38 -04:00
Matthias Clasen
faf56a8abe
stack: Static analysis fixes
2021-05-03 07:44:38 -04:00
Matthias Clasen
e510538f37
printoperation: Static analysis fixes
2021-05-03 07:44:38 -04:00
Matthias Clasen
b2bf48c3f0
listbase: Static analysis fixes
2021-05-03 07:44:38 -04:00
Matthias Clasen
cf0330d601
filterlistmodel: Static analysis fixes
2021-05-03 07:44:38 -04:00
Matthias Clasen
2f51f5affe
emojichooser: Static analysis fixes
2021-05-03 07:44:38 -04:00
Matthias Clasen
a69ae36a99
fnmatch: Static analysis fixes
2021-05-03 07:44:38 -04:00
Matthias Clasen
6863528df1
a11y: Static analysis fixes
2021-05-03 07:44:38 -04:00
Matthias Clasen
e2722f03ac
x11: A few static analysis fixes
2021-05-03 07:44:38 -04:00
Matthias Clasen
1be4684441
gdktoplevelsize: Comment out some unused code
...
This is not currently useful, and clang complains.
2021-05-03 07:44:38 -04:00
Matthias Clasen
4a96e790b1
Merge branch 'inspector-layouts' into 'master'
...
Various small inspector improvements
See merge request GNOME/gtk!3500
2021-05-03 01:40:46 +00:00
Matthias Clasen
f9d6134247
inspector: Improve monitor information display
...
Avoid a nested listbox, show the connector,
don't show information we don't have. Also,
disconnect all signal handlers from the display
when the inspector is going away.
2021-05-02 21:02:09 -04:00
Matthias Clasen
dfecc8fe02
inspector: Show keyboard layouts
2021-05-02 21:02:09 -04:00
Matthias Clasen
2b0c474117
Add gdk_wayland_device_get_xkb_keymap
...
This can be useful to get more detailed information
about keyboard configuration.
2021-05-02 21:02:09 -04:00
Matthias Clasen
0f74798a82
Add 4.4 version macros
2021-05-02 21:02:09 -04:00
Matthias Clasen
ead06fdb35
Bump version to 4.3.0
...
We are going to add new API.
Fix up affected tests.
2021-05-02 21:01:56 -04:00
Matthias Clasen
687e589950
Merge branch 'shifted-mnemonics' into 'master'
...
shortcuts: Ignore consumed modifiers for mnemonics
Closes #3912
See merge request GNOME/gtk!3499
2021-05-02 23:51:41 +00:00
Matthias Clasen
945b32ca1b
Merge branch 'mesa.win32.fixes' into 'master'
...
gdkglcontext-win32.c: Fix running with Mesa drivers
See merge request GNOME/gtk!3483
2021-05-02 22:42:35 +00:00
Matthias Clasen
0768cfb7df
shortcuts: Ignore consumed modifiers for mnemonics
...
This is necessary to make mnemonics like Alt-1 work in
layouts where numeric keys are shifted, like AZERTY.
Fixes : #3912
2021-05-02 18:33:44 -04:00
Matthias Clasen
b5e245762d
Merge branch 'more-content-serializer-tests' into 'master'
...
Add a test for custom serializers
See merge request GNOME/gtk!3497
2021-05-02 14:00:51 +00:00
Matthias Clasen
4c6c0b9099
Add a test for custom serializers
2021-05-02 09:17:20 -04:00
Matthias Clasen
23af39b5b4
Merge branch 'matthiasc/for-master' into 'master'
...
Add tests for content serialization
See merge request GNOME/gtk!3496
2021-05-02 04:30:19 +00:00
Matthias Clasen
a5cab71c9b
Add tests for content serialization
...
Test that roundtripping various types of content
through a stream of a given mimetype works as
expected.
2021-05-02 00:01:57 -04:00
Matthias Clasen
d4f43f1a7c
Merge branch 'matthiasc/for-master' into 'master'
...
contentdeserializer: Fix an oversight
See merge request GNOME/gtk!3495
2021-05-02 03:09:41 +00:00
Matthias Clasen
7ab8109ef8
contentdeserializer: Fix an oversight
...
The argument passed with string_deserializer must be
a charset name. Passing the mimetype there does not
make sense.
2021-05-01 22:44:41 -04:00
Matthias Clasen
0f49a5068a
Merge branch 'fix-gst-type' into 'master'
...
gtkgstmediafile: Fix callback argument type
See merge request GNOME/gtk!3494
2021-05-01 16:06:26 +00:00
Matthias Clasen
a6e0b6e5ce
Merge branch 'wip/baedert/for-master' into 'master'
...
clipboard tests: Add noreturn annotations where possible
See merge request GNOME/gtk!3493
2021-05-01 15:59:30 +00:00
Matthias Clasen
bf563e0926
Merge branch 'matthiasc/for-master' into 'master'
...
wayland: Rewrite shm format debug spew
See merge request GNOME/gtk!3492
2021-05-01 15:59:21 +00:00
Ivan Molodetskikh
03ca7081df
gtkgstmediafile: Fix callback argument type
2021-05-01 18:17:40 +03:00
Matthias Clasen
97afffba4e
wayland: Rewrite shm format debug spew
...
Rewrite this in a way that doesn't depend on kernel
header defines at the time the wayland scanner was run.
This was causing the build to break on Centos 8, where
a bunch of fourcc formats are missing.
2021-05-01 11:17:28 -04:00
Timm Bäder
6b6246f7b4
clipboard tests: Add noreturn annotations where possible
...
Clang complains when they are missing.
2021-05-01 17:14:23 +02:00
Matthias Clasen
f1e006c88c
Merge branch 'matthiasc/for-master' into 'master'
...
Check for root being a GtkWindow in a few places
See merge request GNOME/gtk!3491
2021-04-30 19:29:15 +00:00
Matthias Clasen
32280090fe
Check for root being a GtkWindow in a few places
...
These things were showing up as crashes during DND,
when the root is a GtkDragIcon. I'm sure there's more.
2021-04-30 13:45:39 -04:00
Matthias Clasen
cdd8f7cd53
Merge branch 'bilelmoussaoui/gdk-content-formats-annotations' into 'master'
...
gdk: add length annotation to gdk_content_formats_get_mime_types
See merge request GNOME/gtk!3488
2021-04-30 16:48:04 +00:00
Matthias Clasen
d69ac108d4
Merge branch 'clipboard-test' into 'master'
...
Add more clipboard tests
See merge request GNOME/gtk!3478
2021-04-30 15:25:50 +00:00
Matthias Clasen
c1b614772c
Install the clipboard-client binary
...
It is needed for the installed test.
2021-04-30 09:59:58 -04:00
Bilal Elmoussaoui
ec38e53249
gdk: add zero-terminated annotation to content_formats_get_gtypes
2021-04-30 15:43:33 +02:00
Bilal Elmoussaoui
e473e7a83a
gdk: fix content_formats_get_mime_types annotation
2021-04-30 15:43:17 +02:00
Matthias Clasen
5636384449
Skip clipboard tests when they don't work
...
On headless weston, we have no seat, so focusing
the window won't work, and thus claiming the clipboard
won't either. Skip the tests in that case.
2021-04-30 09:17:39 -04:00
Matthias Clasen
f72ca060b5
Run gdk tests with an unset D-Bus address
...
If the session bus address is unset, GLib will
helpfully try to autolaunch a bus, which will
fail and timeout. If we set an empty address,
it gives up early.
2021-04-30 08:10:48 -04:00
Matthias Clasen
6482954c6e
Fix the clipboard test under X11
...
We don't have a signal handler to worry about here.
2021-04-30 08:02:35 -04:00
Matthias Clasen
e1a0e4bfbe
Make clipboard tests run installed
...
Use dedicated data files, and install them.
As usual, to run the test binary by hand, you
will need to set G_TEST_SRCDIR.
2021-04-30 07:47:19 -04:00
Pawan Chitrakar
ae3ae428a0
Update Nepali translation
...
(cherry picked from commit 24e924720d )
2021-04-30 10:52:21 +00:00
Matthias Clasen
be42644091
Add more clipboard tests
...
This tests the simple cases of copying text,
files, colors or images between processes.
2021-04-30 06:48:52 -04:00
Chun-wei Fan
66e7f3b404
gdkglcontext-win32.c: Fix running with Mesa drivers
...
Some GL drivers such as Mesa-D3D12 do not allow one to call SetPixelFormat() on
a given HDC if one pixel format has been already set for it, so first check the
HDC with GetPixelFormat() to see whether a pixel format has already been set
with the HDC, and only attempt to acquire the pixel format if one has not been
set.
This will fix running with GL/NGL on Windows using the Mesa drivers.
2021-04-29 12:12:01 +08:00
Matthias Clasen
604d171d56
Merge branch 'bookmark-fix' into 'master'
...
gtkplacessidebar.c: add bookmark null checking
See merge request GNOME/gtk!3479
2021-04-28 16:09:32 +00:00
Geyslan G. Bem
65575fe0d0
gtkplacessidebar.c: fix coding style
...
Signed-off-by: Geyslan G. Bem <geyslan@gmail.com >
2021-04-28 08:42:59 -03:00
Emmanuele Bassi
ac5f0ba341
Merge branch 'ebassi/issue-3905' into 'master'
...
docs: Add missing extra files for gdk4 sub-references
Closes #3905
See merge request GNOME/gtk!3481
2021-04-28 09:50:55 +00:00
Matthias Clasen
e637ed739f
Merge branch 'memfd_create' into 'master'
...
gdk/wayland/cursor/os-compatibility: fix build when memfd_create is not available
See merge request GNOME/gtk!3480
2021-04-28 00:50:42 +00:00
Emmanuele Bassi
29382360ed
docs: Add missing extra files for gdk4 sub-references
...
The Wayland and X11 references need the gtk-logo.svg and the urlmap.js
extra files.
Fixes : #3905
2021-04-28 01:44:47 +01:00
David Lechner
2a610267eb
gdk/wayland/cursor/os-compatibility: fix build when memfd_create is not available
...
When building for homebrew/linuxbrew on Ubuntu 16.04, memfd_create() is
not available and causes the build to fail.
This adds a proper check for the function.
2021-04-27 11:46:39 -05:00
Geyslan G. Bem
1635998ac3
gtkplacessidebar.c: add bookmark null checking
...
This fixes nautilus crash and perhaps other callers issues.
Nautilus (and sometimes glib) crashes with malformed URI inside of the
bookmarks file .config/gtk-3.0/bookmarks when it has no LABEL.
This is result from the closed glib MR #2065 analysis and agreement.
https://gitlab.gnome.org/GNOME/glib/-/merge_requests/2065#note_1091979
Signed-off-by: Geyslan G. Bem <geyslan@gmail.com >
2021-04-27 11:58:31 -03:00
Matthias Clasen
82f8fc3bee
Merge branch 'fix-panel-monitor' into 'master'
...
x11: Try harder to find the right monitor
Closes #3900
See merge request GNOME/gtk!3477
2021-04-27 03:48:13 +00:00
Matthias Clasen
f37662c655
x11: Try harder to find the right monitor
...
If we deal with a panel, we end up with no monitor,
and crash, which isn't great and isn't necessary.
Fixes : #3900
2021-04-26 23:20:10 -04:00
Benjamin Otte
1a12ea6e5a
Merge branch 'wip/otte/for-master' into 'master'
...
clipboard: Make sure G_TYPE_STRING is nul-terminated
Closes #3899
See merge request GNOME/gtk!3476
2021-04-26 21:15:32 +00:00
Benjamin Otte
1be899459c
clipboard: Fix reading of files
...
Make sure writing a terminating null byte actually works and we don't
just ignore the error message.
2021-04-26 21:32:57 +02:00
Benjamin Otte
f34e3c573b
clipboard: Make sure G_TYPE_STRING is nul-terminated
...
When reading text, we need to check we terminate the G_TYPE_STRING
string with a null byte, because the clipboard does not guarantee one.
So just append a \0 to the stream.
Fixes #3899
2021-04-26 21:32:57 +02:00
Matthias Clasen
b23529d940
Merge branch 'matthiasc/for-master' into 'master'
...
wayland: Print all layouts in debug spew
See merge request GNOME/gtk!3475
2021-04-26 11:59:01 +00:00
Matthias Clasen
2c34abed20
wayland: Print all layouts in debug spew
2021-04-26 00:16:41 -04:00
Pawan Chitrakar
b3b63a2c8f
Update Nepali translation
...
(cherry picked from commit 193747fadf )
2021-04-26 01:10:45 +00:00
Jordi Mas
4a1a9b1f44
Update Catalan translation
2021-04-25 20:08:19 +02:00
Matthias Clasen
215d4cbfe5
Merge branch 'fix-x11-shadows' into 'master'
...
x11: Fix shadows
Closes #3896
See merge request GNOME/gtk!3473
2021-04-25 11:43:23 +00:00
Matthias Clasen
8cd8aa2cb3
Merge branch 'matthiasc/for-master' into 'master'
...
Mention nightly flatpaks in the README
See merge request GNOME/gtk!3474
2021-04-24 21:27:38 +00:00
Matthias Clasen
b3b9dd493e
Apply 4 suggestion(s) to 1 file(s)
2021-04-24 17:47:43 +00:00
Matthias Clasen
8909ad1859
Mention nightly flatpaks in the README
2021-04-24 11:42:21 -04:00
Matthias Clasen
aa569acaa1
window: Don't let solid-csd linger
...
Just from reading the code, it seems that we
should unset .csd and .solid-csd at the same
time, since the are mutually exclusive and
we unset them here so realize() can set one
of them again.
2021-04-24 11:29:19 -04:00
Matthias Clasen
1c1c030b8e
Simplify shadow conditions
...
The code in gtkwindow.c for dealing with the various
combinations of client-side decorations and client-side
shadows is entirely too complicated.
This commit does not really clean it up, but simplifies
one of the shadow conditions far enough to make some
sense.
With this change, I get the expected decorations in
all the cases I can easily reproduce locally.
2021-04-24 11:07:20 -04:00
Matthias Clasen
628d5406d7
x11: Fix shadows
...
Commit a2cd21cab6 changed a condition and inadvertedly
broke client-side shadows on X11. Change this back.
Fixes : #3896
2021-04-24 09:19:18 -04:00
Emmanuele Bassi
5d563fcde6
Merge branch 'a11y-properties' into 'master'
...
a11y: Don't sent redundant property changes
See merge request GNOME/gtk!3472
2021-04-23 12:04:47 +00:00
Matthias Clasen
b2f3a3220e
a11y: Don't sent redundant property changes
...
We were sending a property changed event for every set
property whenever we were sending any updates.
2021-04-23 07:34:00 -04:00
Matthias Clasen
4e66e782ea
Merge branch 'synthetic-motion-grab' into 'master'
...
gdk: Avoid synthetic motion confusion
Closes #3439
See merge request GNOME/gtk!3471
2021-04-23 03:11:36 +00:00
Matthias Clasen
d225f14657
gdk: Avoid synthetic motion confusion
...
Don't emit a synthetic motion event on a surface
that is grab-shadowed by a popup. This has been
known to confuse GTK, at times.
Fixes : #3439
2021-04-22 21:09:54 -04:00
Matthias Clasen
13f9ca60d5
Merge branch 'gtk4-listbox-selection' into 'master'
...
Allow repeated selection extension on gtklistbox
Closes #3887
See merge request GNOME/gtk!3461
2021-04-22 23:29:45 +00:00
Emmanuele Bassi
8789e78796
a11y: Update the level property for tree expanders
...
We already have the depth of a tree expander in order to compute the
indentation.
Fixes : #3892
2021-04-22 14:40:35 +01:00
Matthias Clasen
be927d9ce6
Merge branch 'resize-borders' into 'master'
...
window: Fix up resize borders
Closes #3856
See merge request GNOME/gtk!3467
2021-04-22 11:13:20 +00:00
Matthias Clasen
dcb5a74275
Merge branch 'a11y-debug' into 'master'
...
Some a11y improvements
See merge request GNOME/gtk!3455
2021-04-22 11:04:30 +00:00
Matthias Clasen
8f70f1449d
Merge branch 'gtk4-compose-modifiers' into 'master'
...
imcontextsimple: Ignore more modifiers in compose
See merge request GNOME/gtk!3468
2021-04-22 10:58:24 +00:00
Matthias Clasen
b25bc36d33
Merge branch 'wip/muktupavels/solid-csd' into 'master'
...
theme: fix solid-csd style
See merge request GNOME/gtk!3460
2021-04-22 10:48:22 +00:00
Matthias Clasen
da4e2a2976
theme: Make solid borders look better
...
As pointed out by Alberts Muktupāvels, without this,
we are missing the inner edge of the frame.
2021-04-22 06:45:28 -04:00
Matthias Clasen
f8dcda80cf
theme: Fix solid-csd borders
...
The selectors did not apply anymore.
Based on a patch by Alberts Muktupāvels.
2021-04-22 06:45:28 -04:00
Matthias Clasen
01d81ffc17
window: Make resize border size independent
...
Deriving the resize border size from the shadows
carries the risk that we might end up with uneven
resize borders (or none at all, on some sides).
So, justs enforce that we have a big enough shadow
width on all sides.
2021-04-22 06:45:28 -04:00
Ulli Kehrle
c78ec37d83
imcontextsimple: Ignore more modifiers in compose
...
Previously it was impossible to compose characters on higher levels of
some keyboard layouts as pressing the level selection key would just
exit compose mode.
Examples for affected keyboard layouts include the Latvian
apostrophe-variant "lv(apostrophe)" (latched third level), the extended
German keyboard layout "de(e1)" (latched fifth level) as well as the
multilingual Canadian keyboard layout "ca(multix)" and the German
neo-layout "de(neo)" and its descendants (shifted fifth level).
To reproduce, set a compose key and select the Latvian apostrophe layout.
Notice that you now can input [ by pressing first the ' and then the 8-key.
Then pressing <compose>'8'8 should produce ⟦, but prior to this patch it
did not.
2021-04-22 03:56:30 +02:00
Matthias Clasen
a2cd21cab6
window: Tweak resize borders
...
Make windows resizable in the padding and border
area of the css box as well. This naturally makes
solid-csd borders work again.
2021-04-21 21:09:09 -04:00
Matthias Clasen
760e60fa04
window: Fix up resize borders
...
The invisible resize borders have been wider than they
should, for a while. Go back to a size close to what
we have in GTK3.
To summarize: resize borders will be at most 12 pixels
on each size, but never wider than the windows shadow.
The resize corners have 'legs' of 24 pixels where you
still get a corner resize cursor.
Fixes : #3856
2021-04-21 20:09:38 -04:00
John Renner
81914f466d
Allow repeated selection extension on gktlistbox
2021-04-21 14:18:29 -07:00
Matthias Clasen
ebd8338795
Merge branch 'im-cursor-pos' into 'master'
...
imcontext: Fix cursor positions
Closes #3885
See merge request GNOME/gtk!3464
2021-04-21 17:43:12 +00:00
Matthias Clasen
11d637f869
Merge branch 'wip/oholy/placesview-default-location-regression' into 'master'
...
placesview: Open location even if mount was not found
Closes nautilus#1811
See merge request GNOME/gtk!3435
2021-04-21 12:22:17 +00:00
Emmanuele Bassi
b24fedda49
a11y: Update the labelled-by relation of GtkTreeExpander
...
Whenever we change the :child property, we need to update the
labelled-by relation.
2021-04-21 11:43:16 +01:00
Emmanuele Bassi
57cc2c4918
a11y: Set state on the GtkTreeExpander widget
...
Instead of setting it on its internal child.
2021-04-21 11:43:11 +01:00
Matthias Clasen
15483ac9df
imcontext: Fix cursor positions
...
gtk_im_context_get_preedit_string is documented to
return the cursor position as a character offset,
not a byte count. So return that.
Fixed : #3885
2021-04-21 06:28:52 -04:00
Matthias Clasen
142984cbf7
Merge branch 'untrusted-beep' into 'master'
...
x11: Don't beep on untrusted displays
Closes #3862
See merge request GNOME/gtk!3463
2021-04-21 10:12:39 +00:00
Emmanuele Bassi
8f9145109b
a11y: Pair window:activate with window:deactivate signal
...
Orca needs both events in order to decide whether or not to subscribe to
other event/state changes in a window.
2021-04-21 10:22:20 +01:00
Matthias Clasen
5587ee0c30
x11: Don't beep on untrusted displays
...
This can trigger BadAccess, and we don't
want that.
Fixes : #3862
2021-04-20 21:42:57 -04:00
Matthias Clasen
99750ac7ed
a11y: Realize notebook tabs when switching
...
We're not moving focus here, so we can't rely
on that to conjure the a11y objects into existence.
2021-04-20 20:35:22 -04:00
Alberts Muktupāvels
f89bad7f33
theme: fix solid-csd style
...
Move .solid-csd style out of .csd parent and adjust it so windows
look similar / same to GTK 3 windows:
- 4px padding.
- extra shadow.
https://gitlab.gnome.org/GNOME/gtk/-/issues/3879#note_1086351
https://gitlab.gnome.org/GNOME/gtk/-/issues/3879#note_1086377
2021-04-20 22:02:10 +03:00
Matthias Clasen
b97d0a3940
a11y: Avoid spurious selection changed events
...
Only send selection-changed events when we either
had a non-empty selection before, or have one now.
This should help orca speak the right things, and
not the wrong things.
Related: #3549
2021-04-20 13:23:56 -04:00
Emmanuele Bassi
639932ad8a
a11y: Emit window:activate event
...
Orca uses the window:activate event type to track top levels, and avoid
being spammed by events coming from non-focused windows.
2021-04-20 17:24:13 +01:00
Matthias Clasen
1a944b2824
stackswitcher: Set accessible label properties
...
This makes the tabs in about dialogs come out as
'About', 'Credits', and 'System', instead of
'Tab', 'Tab', 'Tab'.
2021-04-19 22:11:55 -04:00
Matthias Clasen
ae83b79984
a11y: Emit focus events
...
Orca relies on these to keep track of the focus location,
ignoring the focused state. With this change, orca can
once again speak text in entries as I type.
2021-04-19 21:29:17 -04:00
Matthias Clasen
5f2c08cef1
a11y: Make things appear on focus in
...
We are starting with a pretty empty a11y object tree,
and we want orca to bring more of it into existence
by navigating the tree. But that only happens when we
send it events. Primarily focus events, which come in
from GTK via the platform_change mechanism. So realize
the context when we are sending platform_changes,
otherwise, orca never gets the mesage.
2021-04-19 20:39:32 -04:00
Matthias Clasen
119d0b666c
Merge branch 'fix-uri-crash' into 'master'
...
Fix a possible crash in gtk_show_uri
Closes #3883
See merge request GNOME/gtk!3457
2021-04-19 21:09:44 +00:00
Matthias Clasen
ce2a433ca1
Fix a possible crash in gtk_show_uri
...
g_file_get_basename can return NULL.
Deal with it somehow.
Fixes : #3883
2021-04-19 16:49:02 -04:00
Matthias Clasen
a455db01a0
a11y: Actually set accessible roles
...
With most context realization happening inside
GtkAtspiContext in response to D-Bus calls, the
code in gtk_widget_realize_at_context that sets
the role is not executed for most accessibles,
causing them to be stuck with the 'filler' role
that makes orca ignore them.
To fix this, split gtk_widget_realize_at_context
into the actual context realization (getting on
the bus) and the setting of widget-specific
properties, and do the latter part when the
widget is rooted.
This makes accerciser report proper roles for
entries and buttons. Orca still has an issue
with getting the hierarchy populated.
2021-04-19 19:22:20 +01:00
Matthias Clasen
9e8187bdc4
a11y: Track window states more closely
...
Orca ignores events unless the object is inside an object
with role window and states ACTIVE and SHOWING. To arrange
for this, introduce a new ACTIVE platform state, and set it
for windows when they are active.
This gets orca to be a lot more talkative.
2021-04-19 19:22:20 +01:00
Matthias Clasen
9fbd11e1be
a11y: Add the root object to the cache
...
Not 100% sure this is necessary, but maybe it helps
to get orca up to speed.
2021-04-19 19:22:20 +01:00
Matthias Clasen
aa09737d4d
atspicontext: Remove an unused field
...
We don't make any use of the cache field, so drop it.
2021-04-19 19:22:20 +01:00
Matthias Clasen
435ed3158c
Merge branch 'wip/exalm/shader' into 'master'
...
gsk: Fix shader gresource paths
See merge request GNOME/gtk!3453
2021-04-19 18:01:44 +00:00
Pawan Chitrakar
72600516b9
Update Nepali translation
...
(cherry picked from commit 2a8fd6a488 )
2021-04-19 16:00:38 +00:00
Pawan Chitrakar
fbc8317c5c
Update Nepali translation
...
(cherry picked from commit 4e243d7d12 )
2021-04-19 15:58:08 +00:00
Alexander Mikhaylenko
ae7f380396
gsk: Fix shader gresource paths
...
They were never updated after having been moved.
2021-04-19 20:01:33 +05:00
Piotr Drąg
2e031e47dd
Update Polish translation
2021-04-18 12:44:35 +02:00
Emmanuele Bassi
dbe4543969
Merge branch 'gtksecurememory-updates' into 'master'
...
gtksecurememory: Request that secure memory not be dumped to disk
See merge request GNOME/gtk!3452
2021-04-17 23:46:38 +00:00
Jason Francis
b27ec5ebde
meson: check for madvise()
2021-04-17 19:30:20 -04:00
Matthew Garrett
6622ebb310
gtksecurememory: Request that secure memory not be dumped to disk
...
Linux 3.4 added support for the MADV_DONTDUMP option to madvise(), which
requests that the covered memory not be included in coredumps. It makes
sense to use this to prevent cases where application crashes could
result in secrets being persisted to disk or included in dumps that are
uploaded to remote servers for analysis. I've avoided making this fatal
since there's a chance this code could be built on systems that have
MADV_DONTDUMP but run on systems that don't.
2021-04-17 19:29:42 -04:00
Matthias Clasen
1530c90e37
Merge branch 'a11y-debug' into 'master'
...
testatcontext: Print out platform changes
See merge request GNOME/gtk!3451
2021-04-17 16:39:20 +00:00
Matthias Clasen
a804e4bd8c
a11y: Add more debug spew
...
This is in an attempt to figure out why orca won't speak.
2021-04-17 12:00:17 -04:00
Matthias Clasen
a04ce41799
testatcontext: Print out platform changes
...
This helps debugging what changes orca sees.
2021-04-17 12:00:11 -04:00
Matthias Clasen
5e3e1dd6ba
Merge branch 'matthiasc/for-master' into 'master'
...
image, picture: Move pixbuf code to gdkpixbufutils
See merge request GNOME/gtk!3449
2021-04-16 23:51:10 +00:00
Matthias Clasen
379bb6c9f5
placesview: Fix server mount feedback
...
We weren't properly resetting the in-entry progress.
2021-04-16 19:34:24 -04:00
Matthias Clasen
3df3a0499f
placesview: Fix mounting remote locations
...
This was broken by a stupid copy-paste error.
2021-04-16 19:17:37 -04:00
Matthias Clasen
0d308d09f3
mountoperation: Some cosmetics
...
Fix up the dialog minimally.
2021-04-16 19:05:14 -04:00
Matthias Clasen
1331d5cf97
cssimageurl: Remove direct pixbuf use
...
Rely on the gdkpixbufutils api that gives us
a paintable.
2021-04-16 18:27:40 -04:00
Matthias Clasen
91f3f5c63b
image, picture: Move pixbuf code to gdkpixbufutils
...
This cleans up and moves the code to load files
while taking the scale into account. Along the way,
we drop the last uses of GdkPixbufAnimation, and
consolidate the pixbuf using code in one place.
2021-04-16 18:27:40 -04:00
Matthias Clasen
486a2c9651
Merge branch 'matthiasc/for-master' into 'master'
...
pixbufutils: Remove an unused function
See merge request GNOME/gtk!3447
2021-04-16 15:16:48 +00:00
Matthias Clasen
05af726446
Merge branch 'wayland-xdg-surface-setup' into 'master'
...
wayland: Don't duplicate xdg_surface setup code
See merge request GNOME/gtk!3191
2021-04-16 15:16:28 +00:00
Jonas Ådahl
36347b21e6
Merge branch 'wayland-parent-shadow-refactor' into 'master'
...
wayland: Avoid directly accessing shadow property of parent surface
See merge request GNOME/gtk!3190
2021-04-16 14:34:42 +00:00
David Keijser
db8bf5e7b9
wayland: Don't duplicate xdg_surface setup code
2021-04-16 16:23:16 +02:00
David Keijser
5bbdf3a807
wayland: Avoid directly accessing shadow property of parent surface
2021-04-16 16:13:07 +02:00
Matthias Clasen
08b101ace8
pixbufutils: Remove an unused function
2021-04-16 09:19:06 -04:00
Matthias Clasen
5e53c0473a
Merge branch 'latest.glib.msvc' into 'master'
...
Fix builds against latest stable GLib with MSVC
See merge request GNOME/gtk!3443
2021-04-16 12:25:43 +00:00
Matthias Clasen
9d1e5aa0dc
Merge branch 'fix-focus-unsetting' into 'master'
...
window: Fix deferred focus unsetting
Closes #3413
See merge request GNOME/gtk!3446
2021-04-16 11:47:44 +00:00
Matthias Clasen
4d19de4e03
window: Fix deferred focus unsetting
...
In commit 4a76abffd4 , we deferred unsetting focus
and default until after the next draw, overlooking the
case where the focus is set to another widget before we
ever get to the unsetting.
Fixes : #3413
2021-04-16 07:35:26 -04:00
Chun-wei Fan
153019a794
GTK: Fix builds against latest stable GLib with MSVC
...
GLib-2.68.x now considers warning C4098 ('void' function returning a value) as
an error, so avoid doing that.
2021-04-16 11:39:24 +08:00
Chun-wei Fan
8df32e93be
GSK: Fix builds against latest stable GLib with MSVC
...
GLib-2.68.x now considers warning C4098 ('void' function returning a value) as
an error, so avoid doing that.
2021-04-16 11:39:17 +08:00
Chun-wei Fan
14632e11da
GDK: Fix builds against latest stable GLib with MSVC
...
GLib-2.68.x now considers warning C4098 ('void' function returning a value) as
an error, so avoid doing that.
2021-04-16 11:39:09 +08:00
Matthias Clasen
24cd05672e
Merge branch 'im-context-event-leak' into 'master'
...
imcontext: Eat key events during preedit
See merge request GNOME/gtk!3440
2021-04-15 22:16:49 +00:00
Matthias Clasen
74a68a5803
Merge branch 'theme-fallback-fix' into 'master'
...
themes: Make fallback work a bit better
See merge request GNOME/gtk!3441
2021-04-15 21:31:09 +00:00
Matthias Clasen
9f6b3e179f
themes: Make fallback work a bit better
...
One case we did not include in fd329e0ec5 is
Adwaita-dark -> Default:dark
It turns out that it is needed.
2021-04-15 17:09:46 -04:00
Matthias Clasen
20fb64704d
imcontext: Eat key events during preedit
...
Avoid passing through random key press or release
events while we are showing preedit. That prevents
'accidents' like typing Ctrl-. bringing up the
Emoji chooser during preedit, or hitting Ctrl-a
after the Compose key moving the 'dot' around in
vim in terminals.
2021-04-15 16:59:02 -04:00
Matthias Clasen
9b7f927b3c
Merge branch 'demo-manpages' into 'master'
...
meson: only build demo manpages when demos are enabled
See merge request GNOME/gtk!3438
2021-04-15 11:15:24 +00:00
Matthias Clasen
eb3df6a2e8
Merge branch 'theme-icon-filter-fixes' into 'master'
...
theme: Use -gtk-icon-filter for full-color icons
See merge request GNOME/gtk!1990
2021-04-15 11:12:28 +00:00
nana-4
c6483d431f
theme: Use -gtk-icon-filter for full-color icons
...
Not for symbolic icons.
Don't apply `-gtk-icon-filter: opacity(0.5);` to the symbolic icons as
they already have the "gray" colors indicating the disabled state.
Symbolic icons can be styled using the `color` property.
Also remove the obsolete comment.
2021-04-15 18:39:08 +09:00
Eli Schwartz
e5b0d225de
meson: only build demo manpages when demos are enabled
...
Installing them even when manpages are enabled, but the demos are
disabled, produces manpages for unavailable programs...
2021-04-13 22:55:03 -04:00
Matthias Clasen
d1d009b491
Merge branch 'x11-quiet-exit' into 'master'
...
x11: Be quiet on exit by default
See merge request GNOME/gtk!3436
2021-04-14 00:32:05 +00:00
Matthias Clasen
4465ee5414
Merge branch 'ngl-crash' into 'master'
...
ngl: Fix a rare assertion violation
Closes #3853
See merge request GNOME/gtk!3434
2021-04-13 22:02:44 +00:00
Matthias Clasen
6f11165dd1
x11: Be quiet on exit by default
...
The condition we check for to catch X servers going away
may not be accurate anymore, and the warning shows up in
logs, causing customers to be concerned. So, be quiet by
default, unless the user explicitly asked for a message.
2021-04-13 14:52:48 -04:00
Ondrej Holy
ddeabc7e19
placesview: Open location even if mount was not found
...
Some locations have to be mounted, but their mounts are not user-visible
(e.g. smb-browse). Though this is maybe a bit weird, it is how it works
for years. The problem is that the commit 267ea755 , which tries to get the
default location for opening, caused regression as it doesn't expect such
possibility. Before this commit, such locations were opened without any
issue, but nothing happens currently after clicking to "Connect" except of
clearing the "Connect to Server" entry. Let's fallback to the original
location if the mount was not found to fix this regression.
Fixes: https://gitlab.gnome.org/GNOME/nautilus/-/issues/1811
2021-04-13 17:33:03 +02:00
Matthias Clasen
f5d90826f3
Merge branch 'flatpak-highlight' into 'master'
...
flatpak: Include highlight in gtk4-demo flatpak
Closes #3867
See merge request GNOME/gtk!3433
2021-04-13 11:38:45 +00:00
Matthias Clasen
11154ba119
flatpak: Include highlight in gtk4-demo flatpak
...
Include the highlight utility to make syntax
highlighting work in gtk4-demo. This requires
building its dependencies as well, boost and lua.
2021-04-12 23:55:11 -04:00
Matthias Clasen
c66b030427
ngl: Fix a rare assertion violation
...
When we clean up the uniform allocations after a frame,
it can happen that our space requirements actually increase,
due to padding that depends on the order of allocations.
Instead of asserting that it doesn't happen, just make
it work by growing our allocation.
Fixes : #3853
2021-04-12 22:53:48 -04:00
Matthias Clasen
0c3dd0cf30
Merge branch 'testsuite-asserts' into 'master'
...
testsuite: Reduce the use of g_assert
Closes #3864
See merge request GNOME/gtk!3432
2021-04-13 02:46:07 +00:00
Matthias Clasen
4164abd9f7
build: Quiet the compiler
...
Don't use -Wnull-dereference when assertions are
disabled, since that causes the compiler to see
NULL everywhere.
2021-04-12 22:11:05 -04:00
Emmanuele Bassi
b0990aa8e2
wayland: Build with G_DISABLE_ASSERT
2021-04-12 21:26:02 -04:00
Emmanuele Bassi
a871a1bdb5
build: Don't append multiple flags as a string
...
The gtk_debug_cflags variable is an array, with each argument stored in
a separate string; if we add multiple arguments inside the same string
we break the escaping rules.
Fixes : #3864
2021-04-12 21:23:57 -04:00
Emmanuele Bassi
31e08d4629
gsk/ngl: Build with G_DISABLE_ASSERT enabled
2021-04-12 21:23:18 -04:00
Matthias Clasen
f98353c20b
Force g_test_init to cooperate
...
Change all g_test_init calls in the testsuite
to avoid the macro, so they work regardless of
G_DISABLE_ASSERT.
2021-04-12 21:22:46 -04:00
Matthias Clasen
13ece4ee9b
Make gtk_test_init work without assertions
...
The g_test_init macro 'helpfully' refuses to work when
assertions are disabled. So we just use the function.
2021-04-12 21:22:46 -04:00
Matthias Clasen
6e40f4f357
Remove assertions in tests
2021-04-12 21:22:46 -04:00
Matthias Clasen
ecfba2d31b
Inspector: Fix a possible undefined use
2021-04-12 21:22:46 -04:00
Matthias Clasen
367dfee36e
Fix unused variable warnings
...
These happen for variables which are only used
in assertions, when assertions are disabled.
2021-04-12 21:22:46 -04:00
Matthias Clasen
5e7b5fe085
gtk-demo: Avoid compiler warnings without assertions
...
Avoid an unused variable warning.
2021-04-12 21:22:46 -04:00
Matthias Clasen
9d3aa2cfce
gsk: Avoid compiler warnings without assertions
...
Disabling assertions was provoking some unused variable
warnings from the compiler. Avoid these.
2021-04-12 21:22:46 -04:00
Matthias Clasen
8c156e6b80
testsuite: Reduce the use of g_assert
...
Stop using g_assert() in the gtk tests.
2021-04-12 21:22:46 -04:00
Matthias Clasen
4d1075a082
testsuite: Reduce the use of g_assert
...
Stop using g_assert() in the gsk tests.
2021-04-12 21:22:46 -04:00
Matthias Clasen
442f485591
Merge branch 'f16c.msvc' into 'master'
...
Fix F16C build/runtime detection on Visual Studio
See merge request GNOME/gtk!3429
2021-04-12 20:35:10 +00:00
Matthias Clasen
74238b5429
Merge branch 'testsuite-asserts' into 'master'
...
testsuite: Reduce use of g_assert
See merge request GNOME/gtk!3431
2021-04-12 12:47:09 +00:00
Matthias Clasen
f9fa92766b
testsuite: Reduce use of g_assert
...
Stop using g_assert() in the css tests.
2021-04-12 08:33:41 -04:00
Matthias Clasen
90d187894d
testsuite: Reduce use of g_assert
...
Stop using g_assert() in the reftests.
2021-04-12 08:30:56 -04:00
Matthias Clasen
03db2690e2
testsuite: Reduce use of g_assert
...
Stop using g_assert() in the gdk tests.
2021-04-12 08:18:00 -04:00
Chun-wei Fan
65b35457fd
meson.build: Check for F16C on 32-bit Visual Studio
...
It is also possible to enable F16C instructions on 32-bit Visual Studio builds,
so also check for the compiler's ability to build F16C code on Visual Studio
32-bit instead of just bailing out.
2021-04-12 18:13:42 +08:00
Chun-wei Fan
d5ced21264
gsk/ngl/fp16.c: Implement runtime F16C detection on MSVC
...
We need to use __cpuid() to check for the presence of F16C instructions on
Visual Studio builds, and call the half_to_float4() or float_to_half4()
implementation accordingly, as the __builtin_cpu...() functions are strictly
for GCC or CLang only.
Also, since __m128i_u is not a standard intrisics type across the board, just
use __m128i on Visual Studio as it is safe to do so there for use for
_mm_loadl_epi64().
Like running on Darwin, we cannot use the alias __attribute__ as __attribute__
is also for GCC and CLang only.
2021-04-12 18:13:42 +08:00
Chun-wei Fan
6d6c8c59eb
meson.build: Improve F16C detection on Visual Studio
...
The __builtin_cpu...() intrisics are strictly for GCC/CLang-based compilers, so
don't use them in the checking code on Visual Studio. The test code will still
compile without this change, but will certainly fail if we want it to link.
2021-04-12 18:13:42 +08:00
Matthias Clasen
46ed7540b2
Merge branch 'ngl-shadow-fixes' into 'master'
...
ngl: Fix outset blurred shadows
See merge request GNOME/gtk!3427
2021-04-12 05:07:29 +00:00
Matthias Clasen
3ad56a762f
Merge branch 'grouped-toggle-fix' into 'master'
...
togglebutton: Fix expected group behavior
See merge request GNOME/gtk!3425
2021-04-12 02:40:43 +00:00
Matthias Clasen
21a1a40555
Merge branch 'shadow-reduction' into 'master'
...
gsk: Don't overshadow
See merge request GNOME/gtk!3419
2021-04-12 02:39:55 +00:00
Matthias Clasen
849692b24b
ngl: Fix unevenly scaled shadows
...
Ensure that we don't cut them off at the edges.
2021-04-11 22:35:02 -04:00
Matthias Clasen
f3bf4e4876
ngl: Don't slice unsliceable shadows
...
When the corners are too big to make slicing work,
don't do it, since it leads to broken results.
2021-04-11 22:10:33 -04:00
Matthias Clasen
46270d3dcd
ngl: Fix a case of flipped shadow
...
In the non-sliced case, we were rendering the shadow
upside down.
2021-04-11 22:10:33 -04:00
Matthias Clasen
da6096faaf
ngl: Add code to dump shadows
...
This can be helpful in understanding shadow bugs.
2021-04-11 21:13:47 -04:00
Matthias Clasen
2a7b5a5156
Merge branch 'matthiasc/for-master' into 'master'
...
menubutton: Propagate focus-on-click
See merge request GNOME/gtk!3424
2021-04-11 22:41:26 +00:00
Matthias Clasen
233e662294
togglebutton: Fix expected group behavior
...
The expectation is that a grouped button stays
active when you click it. Grouped check buttons
behave this way, and grouped toggle buttons should
too.
2021-04-11 18:29:53 -04:00
Matthias Clasen
ae41697d83
node-editor: Make header buttons not steal focus
...
This is rarely useful, and is confusing when it
happens as side-effect of dragging the window.
2021-04-11 15:32:15 -04:00
Matthias Clasen
e2fb59798e
icon browser: Make header buttons not steal focus
...
This is rarely useful, and is confusing when it
happens as side-effect of dragging the window.
2021-04-11 15:32:15 -04:00
Matthias Clasen
d0fc3e166d
widget-factory: Make header buttons not steal focus
...
This is rarely useful, and is confusing when it
happens as side-effect of dragging the window.
2021-04-11 15:32:15 -04:00
Matthias Clasen
e4ce46e75f
gtk-demo: Make header buttons not steal focus
...
This is rarely useful, and is confusing when it
happens as side-effect of dragging the window.
2021-04-11 15:32:15 -04:00
Matthias Clasen
e2420f62fe
menubutton: Propagate focus-on-click
...
Propagate the focus-on-click setting to the button
inside, so that setting menubuttons as !focus-on-click
works as expected. This helps for menubuttons in
header bars, where dragging on the button will otherwise
steal focus from the content.
2021-04-11 15:32:15 -04:00
Yuri Chornoivan
6712106c25
Update Ukrainian translation
2021-04-11 18:39:40 +00:00
Matthias Clasen
5b55138729
Merge branch 'matthiasc/for-master' into 'master'
...
some small optimizations
See merge request GNOME/gtk!3423
2021-04-11 18:23:54 +00:00
Matthias Clasen
1d9c581f10
ngl: Allow passing bounds to update_clip
...
update_clip only uses the bounds of the node that
we are currently passing. This opens the door to
updating the clip while handling a single node.
2021-04-11 12:54:17 -04:00
Matthias Clasen
6bfb57db16
ngl: Small optimization for shadows
...
When 9-slicing shadows, omit the center tile when it is
entirely contained in the outline (that is not always
the case, depending on corners and offsets).
2021-04-11 12:54:07 -04:00
Matthias Clasen
f8f2f2944f
roundedrect: Speed up contains_rect and friends
...
gsk_rounded_rect_contains_rect was calling
gsk_rounded_rect_contains_point, which potentially
checks all four corners, for a total of up to 16
corner/point checks. But there is no need to do
more than 4 such checks to answer the question.
2021-04-11 12:52:30 -04:00
Matthias Clasen
aaf17fd3d0
ngl: Small optimization
...
We really want equality here.
2021-04-11 12:50:50 -04:00
Matthias Clasen
678e6fc6d6
nodeeditor: Make the help window wide enough
...
Make the help window wide enough to show the
tables without wrapping.
2021-04-11 12:50:34 -04:00
Matthias Clasen
fcf39170e1
Merge branch 'media-memory-leak' into 'master'
...
media: Fix a memory leak
See merge request GNOME/gtk!3420
2021-04-10 13:42:41 +00:00
Matthias Clasen
187072c3fa
media: Fix a memory leak
...
This was introduced in e7dc82fa32 .
2021-04-10 09:02:59 -04:00
Matthias Clasen
e6599c6c4f
gsk: Don't overshadow
...
Reduce the cairo shadows to the same size as their GL brethren.
2021-04-09 21:47:55 -04:00
Matthias Clasen
87a8ff90d6
Merge branch 'popover-list-lockup' into 'master'
...
window: Defer focus setting until after paint
Closes #3725
See merge request GNOME/gtk!3417
2021-04-10 00:34:24 +00:00
Matthias Clasen
4a76abffd4
window: Defer focus setting until after paint
...
Commit 3dbf5038fa tried to defer focus changes
until after rendering is done. But it failed to do so, since
the toplevel ::render handler is still before rendering of
popups that are attached to that toplevel. To do this
properly, we need to do it in the AFTER_PAINT frame clock
phase.
Fixes : #3725
2021-04-09 19:44:10 -04:00
Matthias Clasen
715449695c
Merge branch 'ngl-coloring-underlines' into 'master'
...
Optimize underlines in text
See merge request GNOME/gtk!3414
2021-04-09 15:36:21 +00:00
Matthias Clasen
d15b0afca9
Merge branch 'no-scroll-cursor' into 'master'
...
scrolledwindow: Stop using scroll cursors
See merge request GNOME/gtk!3416
2021-04-09 13:30:36 +00:00
Matthias Clasen
0d6bbc035d
Merge branch 'ebassi/ci-docs' into 'master'
...
ci: Drop the split Fedora images
See merge request GNOME/gtk!3415
2021-04-09 12:35:49 +00:00
Matthias Clasen
9313d4b6b4
scrolledwindow: Stop using scroll cursors
...
We used to override cursor to use all-scroll while the
content is being scrolled. Unfortunately, there is several
problems with this:
- It is really only expected certain devices, and we don't
have the device information on Wayland
- With the way cursor setting works in GTK4, non-NULL cursors
of the content (eg the text views ibeam) win, making the
scroll cursor not show up
- Under X11, we seem to miss scroll end events and then
the scroll cursor gets stuck
Therefore, just remove this feature.
2021-04-09 08:26:09 -04:00
Emmanuele Bassi
ed412f43d1
ci: Drop the split Fedora images
...
Now that we don't need the whole of Pandoc to build our documentation,
we can go back to a single Fedora image for our CI.
2021-04-09 12:28:08 +01:00
Matthias Clasen
bfe4aea981
ngl: Add a program change counter
...
Count how often we change programs during a frame.
2021-04-09 00:52:18 -04:00
Matthias Clasen
0caa28c1de
ngl: Optimize underlines in text
...
Opportunistically use the coloring program for
drawing underlines instead of the color program.
This avoids program changes in the middle of
text.
For the Emoji text scrolling benchmark, this reduces
the program changes per frame from > 1000 to around 100.
2021-04-08 23:37:51 -04:00
Matthias Clasen
d8ba4b4114
ngl: Reserve a pixel in texture atlases
...
This will be used for coloring from the texture.
2021-04-08 23:34:37 -04:00
Matthias Clasen
e7963945bb
ngl: Fix an oversight
...
All the rest of debug spew goes to stderr here.
2021-04-08 23:34:37 -04:00
Matthias Clasen
e4a6101ae0
gtk-demo: Make one text scroll benchmark harder
...
Add underlines into the mix with the Emoji heavy
text, to see if we can optimize lines.
2021-04-08 23:34:36 -04:00
Matthias Clasen
5d0a3bd4cb
Merge branch 'half-float' into 'master'
...
ngl: Use fp16 for colors
See merge request GNOME/gtk!3405
2021-04-09 03:34:05 +00:00
Matthias Clasen
1c2238cc2a
Merge branch 'font-fallback-fix' into 'master'
...
wayland: Improve font setting fallback more
Closes #3838
See merge request GNOME/gtk!3412
2021-04-08 11:24:09 +00:00
Matthias Clasen
2d7169fd5f
Work around compiler shortcomings on macOS
...
alias attributes don't work on Darwin, so
do without.
2021-04-07 22:38:47 -04:00
Matthias Clasen
885a6b8ebc
gsk: Add runtime checks for F16C
...
Use an IFUNC resolver to determine whether we can use
intrinsics for FP16 conversion. This requires the functions
to be no longer inline.
Sadly, it turns out that __builtin_cpu_supports ("f16c")
doesn't compile on the systems where we want it to prevent
us from getting a SIGILL at runtime.
2021-04-07 22:21:23 -04:00
Matthias Clasen
9d81c129fc
Add an option to disable F16C
...
And add a compile time check for the presence of this
CPU feature.
2021-04-07 22:21:23 -04:00
Matthias Clasen
38c6fe2ce4
Move color conversion up
...
Doing the color conversion early lets us reuse
the results whenever we do more than one draw
per node.
2021-04-07 21:30:43 -04:00
Matthias Clasen
7fe7b7ac7d
ngl: Use a constant for (fp16)-1
...
No need to convert that again for every glyph.
2021-04-07 21:30:43 -04:00
Matthias Clasen
ae7f52d301
ngl: Reduce vertex storage
...
We only have one shader that uses the color2 attribute,
and it doesn't use the uv attribute, so save vertex
memory by putting those in the same space.
This reduce the per vertex space from 32 to 24 bytes.
2021-04-07 21:30:43 -04:00
Matthias Clasen
8b1fcb58e8
ngl: Use fp16 for colors
...
This reduces the size of our Vertex struct from
48 to 32 bytes. It would be nicer if we could store
the colors in fp16 format in the rendernodes, and
avoid conversion here. But this is still good.
2021-04-07 21:30:43 -04:00
Matthias Clasen
cce36ae701
wayland: Improve font setting fallback more
...
We may get a response from the portal that contains
no useful settings at all. In that case, we should
fallback as well.
Fixes : #3838
2021-04-07 19:24:09 -04:00
Matthias Clasen
2f0a02eecb
Merge branch 'wip/carlosg/stuck-frames' into 'master'
...
surface: Always set PHASE_PAINT as pending when updates are scheduled
Closes #3750
See merge request GNOME/gtk!3411
2021-04-07 23:18:25 +00:00
Carlos Garnacho
07167fdf22
surface: Always set PHASE_PAINT as pending when updates are scheduled
...
At times (most often when closing subsurfaces that are scheduling
relayouts) the PHASE_PAINT handling gets broken with the following
sequence:
1. Surface receives wl_callback.done for the previous frame.
Surface is thawed.
2. A new update on the surface is scheduled. PHASE_PAINT is
requested directly on the frame clock. priv->pending_phase is
left unset in the surface.
3. Surface gets frozen
4. Frame clock processes the update scheduled at 2. The surface
is frozen, so paint is prevented. PHASE_PAINT is considered
handled.
5. Compositor emits wl_callback.done again. Surface is thawed.
6. At this point the machinery is off
- The surface didn't paint but has pending update regions
- priv->draw_needed is set in the toplevel and other portions
of the widget tree
- So queueing redraws is ineffective at eventually calling
gdk_surface_schedule_update() again on the toplevel surface.
- We don't paint anymore, so this broken state is not flushed
until other subsurface changes manage to schedule the missing
update.
To fix this, always set PHASE_PAINT in priv->pending_phase when
doing gdk_surface_schedule_update(). If the frame clock turns
around before the surface is thawed, it will still be waiting to
be processed the next iteration.
Fixes: https://gitlab.gnome.org/GNOME/gtk/-/issues/3750
2021-04-07 23:06:06 +02:00
Emmanuele Bassi
99c7ba7840
Install documentation in the appropriate place
...
We're already installing each reference into its own namespaced
directory, so we don't need to add further path elements.
Additionally, with the changes in:
https://gitlab.gnome.org/GNOME/devhelp/-/merge_requests/20
https://gitlab.gnome.org/GNOME/gi-docgen/-/merge_requests/54
we can browse the GTK API references in DevHelp.
2021-04-07 14:57:31 +01:00
Matthias Clasen
5710df685b
Merge branch 'font-settings-fallback-4' into 'master'
...
wayland: Improve font setting fallback
See merge request GNOME/gtk!3407
2021-04-07 13:21:38 +00:00
Matthias Clasen
62f10b1b8f
wayland: Improve font setting fallback
...
When we don't get stettings from the portal, the current
fallback is 'awful fonts'. There is no need for that. Instead,
set the fallback values to grayscale antialiasing with slight
hinting.
2021-04-07 08:50:14 -04:00
Matthias Clasen
d50d55228b
Merge branch 'textview-last-line' into 'master'
...
textview: Fix a problem with the last line
Closes #3835
See merge request GNOME/gtk!3403
2021-04-06 16:15:55 +00:00
Matthias Clasen
288a5d4151
textview: Fix a problem with the last line
...
Sometimes, we missed the last line for display.
Fixes : #3835
2021-04-06 11:09:05 -04:00
Matthias Clasen
748b8497c9
Merge branch 'matthiasc/for-master' into 'master'
...
window: Actually enable the inspector by default
Closes #3831
See merge request GNOME/gtk!3401
2021-04-05 19:05:15 +00:00
Matthias Clasen
303ff60d5e
modelbutton: Avoid a crash
...
We may not have a popover menu ancestor. The check for
this was forgotten in one of the branches here.
Fixes : #3831
2021-04-05 14:06:42 -04:00
Matthias Clasen
b79eb55b34
window: Actually enable the inspector by default
...
427d216081 changed the default in the schema,
but didn't handle cases where the schema isn't found.
2021-04-05 11:54:37 -04:00
Matthias Clasen
0ca573142a
Merge branch 'matthiasc/for-master' into 'master'
...
textlayout: Remove some unnecessary code
See merge request GNOME/gtk!3400
2021-04-05 13:19:29 +00:00
Matthias Clasen
a1ece16143
ngl: Fix an oversight
...
We were special-casing 2D affine transforms,
but overlooked even simpler transforms.
2021-04-05 08:47:53 -04:00
Matthias Clasen
2e18f1b6e3
textlayout: Remove an unused function
2021-04-05 08:47:53 -04:00
Matthias Clasen
6cf712591f
textlayout: Avoid allocations for line iteration
...
No need to collect the lines firs, and allocate memory
for that. We can just iterate over them right away.
2021-04-04 23:42:58 -04:00
Matthias Clasen
b32cd5d328
textlayout: Introduce some locals
...
No need to call _gtk_text_buffer_get_btree over and over.
2021-04-04 22:44:09 -04:00
Matthias Clasen
2af99bd65e
textlayout: Create the cursor snapshot on demand
...
We don't need it all the time.
2021-04-04 22:27:53 -04:00
Matthias Clasen
5b0ea70d1c
textattributes: Small docs fix
2021-04-04 22:27:53 -04:00
Matthias Clasen
d719a3d877
textbtree: Return tags in a GPtrArray
...
One of the callers prefers that, it lets us avoid
copying the array in one place, and generally makes
for better code.
2021-04-04 22:27:53 -04:00
Matthias Clasen
b0df8910ba
textlayout: Only get selection color once
...
No need to do this for every paragraph that is
inside the selection.
2021-04-04 14:20:25 -04:00
Matthias Clasen
5b8bf04035
texttag: Just use qsort
...
No point in trying to optimize this.
2021-04-04 14:20:25 -04:00
Matthias Clasen
58e44e296f
textbtree: Inline node data handling
2021-04-04 14:20:25 -04:00
Matthias Clasen
0334d002c0
textbtree: Speed up _gtk_text_btree_find_line_top
...
Another place where we can avoid allocating a stack
piecemeal.
2021-04-04 14:20:25 -04:00
Matthias Clasen
d731ce49ad
textbtree: Don't opencode realloc
...
We can just use g_realloc here.
2021-04-04 14:20:25 -04:00
Matthias Clasen
a93614409e
textbtree: Speed up _gtk_text_line_char_index
...
No need to allocate a stack piecemeal here.
2021-04-04 14:20:25 -04:00
Matthias Clasen
214e2d14be
textbtree: Avoid malloc in one place
2021-04-04 14:20:25 -04:00
Matthias Clasen
67ee6b2740
textlayout: Don't call render_para too much
...
render_para produces no nodes for an empty paragraph.
Don't call it over and over for those.
2021-04-04 14:20:25 -04:00
Matthias Clasen
07a3fb833c
textlayout: Remove some unnecessary code
...
The same field is set again 2 lines down.
2021-04-04 14:20:25 -04:00
Chao-Hsiung Liao
1c419f762b
Update Chinese (Taiwan) translation
...
(cherry picked from commit 3d3912d7f4 )
2021-04-03 23:54:29 +00:00
Matthias Clasen
8d6c7b81e9
Merge branch 'matthiasc/for-master' into 'master'
...
gsk: Rename resource paths
See merge request GNOME/gtk!3399
2021-04-03 20:14:29 +00:00
Matthias Clasen
fcaadf6724
Merge branch 'dotted-lines3' into 'master'
...
Modernize error underlines
See merge request GNOME/gtk!3398
2021-04-03 20:14:13 +00:00
Matthias Clasen
ff38d8cdc0
Modernize error underlines
...
Implement PANGO_UNDERLINE_ERROR as a dotted line, instead of
squiggly, which looks quite dated.
2021-04-03 13:52:56 -04:00
Matthias Clasen
900a4e4d31
gsk: Move shader resources
...
Move the resources of each renderer to its subdirectory.
We've previously done that for the ngl renderer, but it
is better to be consistent and do it for all the renderers.
2021-04-03 08:24:58 -04:00
Matthias Clasen
ee63b84b6a
gsk: Rename resource paths
...
Make the shaders of the gl renderer live under
/org/gtk/libgsk/gl. This is purely cosmetic.
2021-04-03 08:10:58 -04:00
Matthias Clasen
2f1ff307da
Merge branch 'matthiasc/for-master' into 'master'
...
node test: Improve --generate
See merge request GNOME/gtk!3397
2021-04-03 03:20:17 +00:00
Matthias Clasen
a8e8e04496
settings: Make font-size changes apply immediately
...
We need to invalidate the style when font-size changes,
because we propagate this value through the initial
value of the CSS font-size property, and it will not
be recomputed otherwise.
2021-04-02 23:04:09 -04:00
Matthias Clasen
91bcf6f0ba
immulticontext: Unset client widget on delegate change
...
Forgetting to do so was causing the Wayland im context
to leave behind a dead event controller. This was showing
up as a crash when closing the inspector after changing
the im-module property of a GtkText widget. The crash
was delayed until closing the inspector because the
inspector keeps a ref on the event controllers of the
currently shown widget.
2021-04-02 22:24:19 -04:00
Matthias Clasen
a228b2de64
imwayland: Name event controllers
...
This helps with debugging.
2021-04-02 22:24:00 -04:00
Matthias Clasen
cb18437908
widget-factory: Name an event controller
...
This helps with debugging.
2021-04-02 22:23:34 -04:00
Matthias Clasen
23dab885cd
text: Name all event controllers
...
This helps with debugging.
2021-04-02 22:23:03 -04:00
Matthias Clasen
e7284c23da
inspector: Support copying nodes to clipboard
...
Add a button that copies the serialization of the
selected node to the clipboard.
2021-04-02 21:38:14 -04:00
Matthias Clasen
1e1f199b56
node-editor: Support pasting the image
...
Add a button that copies the image to the clipboard.
2021-04-02 21:24:59 -04:00
Matthias Clasen
efb5e793a4
nodeparser: Change the serialization
...
Arrange things so that non-child parameters
are always printed before the children. This
greatly helps with readability, which really
suffers when there's hundreds of lines of indented
children between the node start and its parameters.
Update all affected tests.
2021-04-02 20:38:32 -04:00
Matthias Clasen
f2edf40e48
node test: Improve --generate
...
This is a pet peeve of mine: When we call
g_test_init() before handling --generate,
the random seed spew pollutes the output.
Highly annoying. I've fixes many test binaries
over the years, but more keep popping up.
2021-04-02 20:35:39 -04:00
Matthias Clasen
7cb99a0866
Merge branch 'fix-downscaled-textures' into 'master'
...
ngl: Fix downscaled textures
See merge request GNOME/gtk!3395
2021-04-03 00:18:48 +00:00
Matthias Clasen
36da7c3075
Merge branch 'matthiasc/for-master' into 'master'
...
comboboxtext: Remove misleading docs
Closes #3824
See merge request GNOME/gtk!3396
2021-04-03 00:04:36 +00:00
Matthias Clasen
a3b69f1101
Merge branch 'fix-initial-font-selection' into 'master'
...
fontchooser: Fix initial font selection
Closes #3687
See merge request GNOME/gtk!3392
2021-04-02 23:45:59 +00:00
Matthias Clasen
9f2d1ff264
comboboxtext: Remove misleading docs
...
The entry is no longer accessible.
The docs were outdated.
Fixes : #3824
2021-04-02 19:44:30 -04:00
Matthias Clasen
8d603dfe99
ngl: Avoid huge intermediate textures
...
Instead of rendering the unclipped child to a texture
(and risking blowing the texture size limit, and bad
downscaling), just render the clipped region, and live
with the fact that we can't cache the rendered texture.
This avoid bad artifacts when scrolling long textviews
in rounded clips.
2021-04-02 19:33:44 -04:00
Matthias Clasen
3ff04976e3
ngl: Plug a memory leak
...
This was introduced in f9457af128 .
2021-04-02 18:41:53 -04:00
Matthias Clasen
54ff4fd45f
ngl: Fix downscaled textures
...
It is not pretty, but at least it works now.
2021-04-02 18:33:01 -04:00
Matthias Clasen
0d135d90f0
Merge branch 'flat-button-activating' into 'master'
...
button: Style .keyboard-activating on frameless buttons
See merge request GNOME/gtk!3394
2021-04-02 18:50:16 +00:00
Chris Mayo
ffa9814dd0
button: Style .keyboard-activating on frameless buttons
...
The use of the keyboard-activating CSS class for buttons was added
in [1], but the style did not apply to buttons with has-frame=FALSE.
[1] 00923615f4 ("button: Add back visual feedback for keynav", 2021-04-01)
2021-04-02 19:24:51 +01:00
Nathan Follens
a2fec9134b
Update Dutch translation
...
(cherry picked from commit a356bf6fac )
2021-04-02 18:09:34 +00:00
Matthias Clasen
8caadaf404
fontchooser: Fix initial font selection
...
The change in 740559a54f to populate the list incrementally
broke initial font selection. Fix that, by trying to select
until the incremental filling is done.
Fixes : #3687
2021-04-02 01:06:23 -04:00
Matthias Clasen
469228fcd7
Merge branch 'theme-reorg' into 'master'
...
Reorganize our themes
See merge request GNOME/gtk!3079
2021-04-02 03:02:49 +00:00
Matthias Clasen
fd329e0ec5
Make theme fallback working with the new names
...
Since we are likely going to see theme names like
Adwaita and HighContrast, make fallback work as follows:
Adwaita -> Default
Adwaita:dark -> Default:dark
HighContrast -> Default:hc
HighContrast:dark -> Default:hc-dark
HighContrastInverse -> Default:hc-dark
Other themes will fall back to Default, as before.
2021-04-01 22:02:38 -04:00
Matthias Clasen
7f4041ec30
Merge branch 'matthiasc/for-master' into 'master'
...
testsuite: Sort gsk compare tests
See merge request GNOME/gtk!3389
2021-04-02 00:38:55 +00:00
Matthias Clasen
5cb5bdc4eb
testsuite: Sort gsk compare tests
...
Easier to find things that way.
2021-04-01 20:07:13 -04:00
Matthias Clasen
08913deba5
Add some more gsk tests
...
The css-background test contains a node pattern that
is optimized in the ngl renderer.
2021-04-01 20:06:40 -04:00
Matthias Clasen
aceeef47f4
Add one more compose test
2021-04-01 20:06:40 -04:00
Matthias Clasen
ddda0ca1db
Merge branch 'button-activate-feedback' into 'master'
...
button: Add back visual feedback for keynav
Closes #3813
See merge request GNOME/gtk!3390
2021-04-01 23:36:32 +00:00
Matthias Clasen
00923615f4
button: Add back visual feedback for keynav
...
We lost the visual feedback for activating a button
via Space or Enter when the :active pseudo-state became
managed. Bring it back with a style class.
Fixes : #3813
2021-04-01 18:38:11 -04:00
Matthias Clasen
63945bc408
Merge branch 'matthiasc/for-master' into 'master'
...
Add one more compose test
See merge request GNOME/gtk!3388
2021-04-01 20:50:04 +00:00
Matthias Clasen
076f79745b
Add one more compose test
2021-04-01 16:32:30 -04:00
Matthias Clasen
8e9effcc1e
Merge branch 'us-intl-compose' into 'master'
...
Revert Compose sequence changes
Closes #3807
See merge request GNOME/gtk!3386
2021-04-01 20:01:06 +00:00
Matthias Clasen
7f4522a3f1
Add more compose tests
...
Test the sequences whose demise made people
unhappy.
2021-04-01 15:32:32 -04:00
Matthias Clasen
f98abe4400
Revert Compose sequence changes
...
This was breaking muscle memory of people with
the us intl keyboard layout, for important keys
such as '. The unfortunate side-effect is that
our handling of <dead_acute> is a bit hampered
by sequences that don't fit the pattern. But
such is life.
Fixes : #3807
2021-04-01 15:31:21 -04:00
Emmanuele Bassi
2ee8f676c3
Merge branch 'builder-tag' into 'master'
...
docs: Escape tags in GtkBuilder description
See merge request GNOME/gtk!3385
2021-04-01 18:49:38 +00:00
Chris Mayo
7216f71825
docs: Escape tags in GtkBuilder description
...
Fixes the tags and the rest of the gi-docgen created HTML page not being
visible in a browser.
2021-04-01 19:21:57 +01:00
Matthias Clasen
0bf3e4c25b
Drop Adwaita and HighContrast themes
...
These themes will reappear in libadwaita in due course.
2021-04-01 12:39:30 -04:00
Matthias Clasen
e964e176f9
widget-factory: Use the new themes
...
Update the Style menu to switch between the variants
of the Default theme.
2021-04-01 12:27:35 -04:00
Matthias Clasen
8938b09bc9
Change the default theme to "Default"
...
We are not shipping Adwaita anymore.
2021-04-01 12:27:35 -04:00
Matthias Clasen
3654bcfbe8
Make the theme variants available as themes
...
This makes it easier to implement the theme switching
in widget-factory, since we don't have a variant setting.
2021-04-01 12:27:26 -04:00
Matthias Clasen
0dcf95b898
Reorganize our themes
...
Rename the included theme to Default, with 4 variants:
light, dark, hc, hc-dark. This replaces Adwaita,
Adwaita:dark, HighContrast and HighContrastInverse.
We still make the themes available under these names,
and we still set up Adwaita-dark and HighContrastInverse
as the dark variants of Adwaita and HighContrast.
The unification of the theme variants under Default
is not quite perfect; it would be nice to merge
the assets/ and assets-hc/ subdirectories and render
all assets from a single svg file.
2021-04-01 11:42:17 -04:00
Benjamin Otte
405fab8b36
Merge branch 'wip/otte/for-master' into 'master'
...
snapshot: scale border widths when appending border nodes
Closes #3819
See merge request GNOME/gtk!3384
2021-04-01 15:10:50 +00:00
Benjamin Otte
ef455f5c85
snapshot: Move sanity checks to a better place
...
Fixes cases where the sanity checks would reject valid code, like when
using GL shaders on a scaled transform.
Fixes #3819
2021-04-01 16:53:33 +02:00
Benjamin Otte
05e4cd1579
snapshot: scale border widths when appending border nodes
...
Found by Matthias on IRC while arguing about GtkSnapshot being too
complicated.
2021-04-01 16:37:43 +02:00
Matthias Clasen
0ea96e3b0c
Merge branch 'filechooser-signal-disconnect' into 'master'
...
filechooserwidget: Disconnect settings signal on dispose
See merge request GNOME/gtk!3383
2021-04-01 14:25:08 +00:00
Carlos Garnacho
1e9e7bf0d9
Merge branch 'wip/exalm/overshoot-changes' into 'master'
...
scrolledwindow: Cancel overshoot on dimension changes
Closes #3752
See merge request GNOME/gtk!3300
2021-04-01 12:11:15 +00:00
Alexander Mikhaylenko
d7a5dedd4f
scrolledwindow: Cancel overshoot on dimension changes
...
If we scroll down in a list that's still being filled, we hit the edge and
initiate overshoot, and then the adjustment's upper value increases. This
leads to an unwanted bounce back.
Additionally, if in a similar situation the upper value decreases, the
overscroll glow gets stuck.
Update kinetic scrolling upper and lower value on changes, and immediately
cancel it if dimensions on that side change.
Fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/3752
2021-04-01 16:37:30 +05:00
Rafał Dzięgiel
2e65416270
filechooserwidget: Reduce code duplication for disconnecting settings signal
...
Instead of getting current display before calling settings signal removal,
do it inside remove function and only if there is a signal connection to remove.
2021-04-01 09:36:23 +02:00
Rafał Dzięgiel
13c22e4e2f
filechooserwidget: Disconnect settings signal on dispose
...
Settings signal was not being disconnected on dispose causing
application crash when user changed icon theme after dialog disposal.
2021-04-01 09:28:37 +02:00
Matthias Clasen
65a061f3c2
Merge branch 'ebassi/broadway-docs' into 'master'
...
docs: Update the Broadway instructions
See merge request GNOME/gtk!3380
2021-03-31 21:42:59 +00:00
Matthias Clasen
fc63e6856f
Merge branch 'ebassi/docs-links' into 'master'
...
docs: Update the links to the docs of GTK dependencies
Closes #3817
See merge request GNOME/gtk!3381
2021-03-31 21:42:49 +00:00
Matthias Clasen
94747d53eb
Merge branch 'offscreen-fixes' into 'master'
...
Offscreen fixes
See merge request GNOME/gtk!3379
2021-03-31 21:27:18 +00:00
Matthias Clasen
b5df1299ec
gsk: Add another test
...
Compare clipped repeat nodes. Must skip cairo here
since it blurred the child by scaling after rendering.
Also skip the gl renderer, since it hasn't been fixed
for this yet. ngl passes this test.
2021-03-31 16:49:31 -04:00
Emmanuele Bassi
7bfff6c51e
docs: Update the links to the docs of GTK dependencies
...
Use docs.gtk.org where appropriate.
Fixes : #3817
2021-03-31 20:51:27 +01:00
Emmanuele Bassi
3fdedce8f6
docs: Update the Broadway instructions
...
The Broadway server binary is now versioned, and it's not compatible
with the GTK3 server.
2021-03-31 20:06:54 +01:00
Matthias Clasen
6f62107656
testsuite: Rename next to ngl
...
Use specific names for renderers in the gsk tests.
Otherwise the tests may use the wrong renderer, or
the same renderer twice.
2021-03-31 14:59:43 -04:00
Matthias Clasen
f9457af128
ngl: Fix offscreen rendering with transforms
...
There was confusion here about the handling of the
modelview transform. The modelview transform we are
getting is already set up for rendering the node
we are given, so keep it - except for possible adding
an extra scale on top when the texture would otherwise
be too big.
2021-03-31 14:36:24 -04:00
Matthias Clasen
94f0a4ef2c
ngl: Be explicit about offscreen clipping
...
Explicitly set all the input arguments.
This makes it clearer what is going on.
2021-03-31 14:34:16 -04:00
Matthias Clasen
53e75936cb
ngl: Add sonme comments
...
The GskNglRenderOffscreen struct is a mix of in and
out arguments. Better annotate that a little bit.
2021-03-31 14:32:47 -04:00
Matthias Clasen
5f0fe09423
Merge branch 'ebassi/for-master' into 'master'
...
Update the gi-docgen repository
See merge request GNOME/gtk!3352
2021-03-31 11:34:56 +00:00
Benjamin Otte
9e402fa064
Merge branch 'wip/otte/for-master' into 'master'
...
gstmedia: Properly detect stream metadata when preparing
See merge request GNOME/gtk!3377
2021-03-30 21:54:57 +00:00
Emmanuele Bassi
d84440969a
Merge branch 'ebassi/docs-ci' into 'master'
...
ci: Add missing graphviz dependency
See merge request GNOME/gtk!3376
2021-03-30 20:44:51 +00:00
Benjamin Otte
e7dc82fa32
gstmedia: Properly detect stream metadata when preparing
...
We can look at the GstPlayerMediaInfo to get all the info we care about.
2021-03-30 22:26:26 +02:00
Emmanuele Bassi
f1b3492700
ci: Add missing graphviz dependency
...
We generate the hierarchy graph for GTK types, and in order to do so, we
need the dot utility from graphviz in the CI image.
2021-03-30 21:08:43 +01:00
Anders Jonsson
6c95fc7e87
Update Swedish translation
2021-03-30 17:13:11 +00:00
Matthias Clasen
f4cc9a47ad
Merge branch 'docs' into 'master'
...
docs: Cover corner-case of @line_number = total lines in buffer
See merge request GNOME/gtk!3373
2021-03-30 16:09:34 +00:00
Matthias Clasen
ccbbc2f2ba
4.2.0
2021-03-30 11:00:55 -04:00
Matthias Clasen
8bc2ee63eb
Actually build docs for releases
2021-03-30 11:00:54 -04:00
Matthias Clasen
68d634b31c
Disable the border-image-url reftest
...
It seems to make assumptions about text positioning that
are not holding with subpixel positioning. I'm not 100%
sure how that leads to exactly the artifacts that are seen
here, but I am just disabling the test until that is fully
understood.
2021-03-30 11:00:54 -04:00
Matthias Clasen
d1c66f75e3
Disable flaky focus tests
2021-03-30 11:00:54 -04:00
Matthias Clasen
eba9cd8775
Disable the label-background reftest
...
It makes assumptions about text positioning that are
not holding with subpixel positioning. There is no
guarantee that the next word in a multi-word text
starts on an even pixel boundary, as it does when
you break the text into multiple, separately rendered
blocks.
2021-03-30 11:00:54 -04:00
Matthias Clasen
9606945ed8
Fix tests for new version
2021-03-30 11:00:54 -04:00
Matthias Clasen
d50d382032
Merge branch 'ebassi/dist-docs' into 'master'
...
build: Dist the API references
See merge request GNOME/gtk!3375
2021-03-30 14:58:53 +00:00
Emmanuele Bassi
5da3308572
build: Dist the API references
...
Copy them into the dist root from the build root, so that they will be
available in the release archive.
2021-03-30 15:42:40 +01:00
Jonas Ådahl
fb48699ba4
Merge branch 'issue3791-gtk4' into 'master'
...
gdk/wayland: Defer processing of globals closures
Closes #3791
See merge request GNOME/gtk!3374
2021-03-30 14:06:33 +00:00
Robert Mader
56d37ceed0
gdk/wayland: Defer processing of globals closures
...
... until all globals have been received.
The dependency tracking introduced in 4e9be39518 only allows to
specify required globals and processes the closures as soon as
the requirements have been met. There are, however, also optional
dependencies - most notably the primary_selection protocol.
Currently we rely on the fact that compositors like Mutter announce
it before `wl_seat`, even though the order is not specified in
the spec.
Process globals closures only after all globals have been announced,
so optional dependencies can be accommodated.
Closes https://gitlab.gnome.org/GNOME/gtk/-/issues/3791
2021-03-30 15:20:00 +02:00
Avinash Sonawane
622bb9186e
docs: Cover corner-case of @line_number = total lines in buffer
2021-03-30 17:00:33 +05:30
Matthias Clasen
b77e05ce37
Merge branch 'ngl-text-tweaks' into 'master'
...
Ngl text tweaks
See merge request GNOME/gtk!3367
2021-03-30 11:15:13 +00:00
Matthias Clasen
ba4e66d189
ngl: Avoid a goto
...
Reshuffle the code slightly, so we can use a continue
instead.
2021-03-30 00:34:52 -04:00
Matthias Clasen
2c33550048
gsk: Avoid empty glyphs early
...
Strip out PANGO_GLYPH_EMPTY when text nodes are
constructed. Then we don't have to check this special
case in the inner loop in visit_text_node.
2021-03-30 00:34:52 -04:00
Matthias Clasen
3add99a9a8
ngl: Speed up glyph loop
...
Move some work out of the loop in visit_text_node.
This takes advantage of the fact that the yoffset
of most glyphs is zero, so yphase generally does
not change in a line of text.
2021-03-30 00:19:28 -04:00
Matthias Clasen
d4ea2e848d
ngl: We only need two bits for phases
...
We use 4 phases, so 2 bits are enough.
2021-03-30 00:19:28 -04:00
Matthias Clasen
4c06889243
Updates
2021-03-30 00:18:48 -04:00
Matthias Clasen
ef544a8c3b
Merge branch 'ngl-trivia' into 'master'
...
Ngl trivia
See merge request GNOME/gtk!3372
2021-03-30 04:16:00 +00:00
Matthias Clasen
6db9215dd1
Merge branch 'video-player-images' into 'master'
...
gtk-demo: Allow opening images in video player
See merge request GNOME/gtk!3371
2021-03-30 03:54:13 +00:00
Matthias Clasen
8b64f0147c
gtk-demo: Allow opening images in video player
...
It works, so why not.
2021-03-29 23:40:17 -04:00
Matthias Clasen
5847f75c57
ngl: Cosmetics
...
Remove a local variable in gsk_render_job_visit_text_node.
2021-03-29 15:17:20 -04:00
Matthias Clasen
ce2c3efc91
ngl: Improve packing
...
Pack texture cache entries slightly better.
There was a 4 byte hole here.
2021-03-29 15:17:10 -04:00
Matthias Clasen
2599c5aed3
gsk: Typo fix
2021-03-29 15:16:44 -04:00
Matthias Clasen
bca39e2605
ngl: Typo fix
2021-03-29 15:16:25 -04:00
Matthias Clasen
ca0e1be03e
Merge branch 'frame-rate-benchmark' into 'master'
...
Add a frame benchmark
See merge request GNOME/gtk!3364
2021-03-29 15:52:51 +00:00
Benjamin Otte
6569a877d8
Merge branch 'wip/otte/for-master' into 'master'
...
Wip/otte/for master
Closes #3810
See merge request GNOME/gtk!3366
2021-03-29 15:41:55 +00:00
Benjamin Otte
38fff37dae
mediastream: Insist streams are prepared when they start playing
...
Applications expect that behavior, so don't let implementations get away
without preparing the stream.
2021-03-29 17:08:34 +02:00
Benjamin Otte
06be1f8b52
gstmedia: Ensure we prepare files without duration
...
In particular this fixes playback of images.
Fixes #3810
2021-03-29 17:08:34 +02:00
Matthias Clasen
43a1641dd7
Add a frame benchmark
...
This can be used to gauge what fps we can hope for
in the best case, on a given system.
2021-03-29 08:27:43 -04:00
Yosef Or Boczko
b21fba117f
Update Hebrew translation
...
(cherry picked from commit 1beb550830 )
2021-03-28 22:34:55 +00:00
Yosef Or Boczko
37d5f93610
Update Hebrew translation
...
(cherry picked from commit 4a7e08bb8e )
2021-03-28 21:31:44 +00:00
Matthias Clasen
52aea624a6
Merge branch 'text-node-tweak' into 'master'
...
textview: Tweak render nodes
See merge request GNOME/gtk!3362
2021-03-28 17:25:36 +00:00
Matthias Clasen
711acb6aa7
Merge branch 'smarter-diff' into 'master'
...
Smarter diff
See merge request GNOME/gtk!3361
2021-03-28 17:24:23 +00:00
Hugo Carvalho
3e94c5afa4
Update Portuguese translation
...
(cherry picked from commit ef7cbad45d )
2021-03-28 16:35:59 +00:00
Matthias Clasen
a75c038e09
textview: Tweak render nodes
...
Arrange for the contents to be in a single transform
node that is updated as we scroll. This makes the job
of the render node differ a lot easier, since it does
not have to compare to big containers one-by-one.
2021-03-28 10:59:55 -04:00
Matthias Clasen
146069058f
Add some tests for node diffing
...
Nothing deep yet, but more can be added.
2021-03-28 10:45:40 -04:00
Matthias Clasen
2d5dd7b3d7
gsk: Make rendernode diffing smarter
...
Allow comparing container nodes to any other
node, by pretending the other node is a single
child container (if it isn't one already).
This fixes a glitch where we redraw the full
entry text when the blinking cursor goes to
opacity 0, since GskSnapshot then optimizes
away first the opacity node, and then the
single-child container.
2021-03-28 10:26:06 -04:00
Matthias Clasen
0904dd29c2
gsk: Use floorf for floats
2021-03-28 10:26:06 -04:00
Matthias Clasen
279b9347fd
gsk: Cosmetics
2021-03-28 10:26:02 -04:00
Matthias Clasen
2a2ae16894
ngl: Cosmetics
...
Remove a commented out line that snuck in with
a recent commit.
2021-03-28 10:26:02 -04:00
Matthias Clasen
3e1a8aa286
Merge branch 'fix-memleaks' into 'master'
...
Fix memleaks
See merge request GNOME/gtk!3360
2021-03-28 14:23:35 +00:00
Matthias Clasen
db126a19b6
Plug a test memleak
2021-03-27 21:52:49 -04:00
Matthias Clasen
ffa50f4c24
Plug a memory leak in an error path
2021-03-27 21:44:19 -04:00
Matthias Clasen
e1866d8fbe
Ignore pthread allocations in valgrind
2021-03-27 21:43:59 -04:00
Matthias Clasen
d24a0e9606
tests: Plug a memory leak
2021-03-27 21:13:25 -04:00
Matthias Clasen
b8693cc4f4
tests: Make the pixbuf test use TAP
...
Otherwise, meson just considers this test skipped.
2021-03-27 21:03:43 -04:00
Matthias Clasen
5d5adf6ee7
asan: Ignore leaks from librsvg
...
Turns out that there are some leaks from librsvg.
2021-03-27 21:03:43 -04:00
Matthias Clasen
dda69bd16d
tests: Plug memory leaks
...
This one was pointed out by asan.
2021-03-27 21:03:43 -04:00
Matthias Clasen
926b855d14
Merge branch 'fix-memleaks' into 'master'
...
Fix memleaks
See merge request GNOME/gtk!3359
2021-03-27 23:47:05 +00:00
Matthias Clasen
afc3de6e04
notebook: Don't leak the pages property
...
We were misuing a transfer-full getter here.
2021-03-27 19:11:56 -04:00
Matthias Clasen
45f4090eec
stack: Don't leak the pages property
...
We were misusing a transfer-full getter here.
2021-03-27 19:11:56 -04:00
Matthias Clasen
4cf69fbc5e
builder: Plug a small memory leak
...
We were forgetting to free expression info
objects in one place.
2021-03-27 19:11:56 -04:00
Matthias Clasen
0c6da97147
builder: Add an assertion
...
This case is clearly not meant to happen.
Assert that it doesn't.
2021-03-27 19:11:56 -04:00
Matthias Clasen
8994635d39
settings: Plug a memory leak
...
It is rare that settings are finalized, but we
still shouldn't leak in that case.
2021-03-27 19:11:56 -04:00
Matthias Clasen
7644605dfc
Plug a small memory leak
2021-03-27 19:11:56 -04:00
Matthias Clasen
97a9e23b85
bookmarklist: Avoid an invalid read
...
This shows up when running the objects-finalize
test under valgrind.
2021-03-27 19:11:56 -04:00
Matthias Clasen
478ecf8db4
Merge branch 'ngl-uninitialized-matrix' into 'master'
...
Ngl uninitialized matrix
See merge request GNOME/gtk!3358
2021-03-27 20:59:54 +00:00
Anders Jonsson
0e857862ab
Update Swedish translation
...
(cherry picked from commit 86f3c11d1e )
2021-03-27 20:43:39 +00:00
Matthias Clasen
2bb4859031
ngl: Fix an uninitialized read
...
We were using the wrong matrix here.
valgrind pointed this point.
2021-03-27 16:32:58 -04:00
Matthias Clasen
7aef77a21a
reftests: Plug a few memory leaks
...
Noticed in passing.
2021-03-27 16:25:28 -04:00
Matthias Clasen
e7f9d56da5
ngl: Fix an uninitialized read
...
We were using the wrong matrix here.
valgrind pointed this point.
2021-03-27 16:23:40 -04:00
Matthias Clasen
34883b7142
reftests: Plug a few memory leaks
...
Noticed in passing.
2021-03-27 16:23:17 -04:00
Matthias Clasen
23706a4a6d
release: Actually include docs
2021-03-27 14:22:19 -04:00
Matthias Clasen
c52c944e33
Updates
2021-03-27 14:21:04 -04:00
Matthias Clasen
8540bea65e
Merge branch 'file-chooser-fixes' into 'master'
...
File chooser fixes
See merge request GNOME/gtk!3356
2021-03-27 14:23:15 +00:00
Matthias Clasen
8ea4721d1e
filechooser: Make / work as shortcut again
...
Typing / is meant to open the location entry, so
prevent search from capturing that key.
2021-03-27 09:57:00 -04:00
Matthias Clasen
e8a6b504f3
filechooser: Fix fallout from GtkText
...
Ever since the GtkText split, the focus is no longer
on an entry, but inside it. The filechooser was never
updated for that.
2021-03-27 09:54:20 -04:00
Matthias Clasen
06ab8f2167
filechooser: Make Ctrl-L work again
...
Prevent search from preempting the Ctrl-L shortcut
that is meant to show the location entry.
2021-03-27 09:53:43 -04:00
Matthias Clasen
b5558f3e97
layout: Be quiet about trivialities
...
Commit 8b82993dde added a noisy warning
to gtk_distribute_natural_allocation to quiet a
compiler warning. It turn out that the file chooser
managed to trigger this warning, so make it a quiet
return.
2021-03-27 08:59:21 -04:00
Matthias Clasen
bdd281c9ea
release: Update included subprojects
2021-03-27 08:55:51 -04:00
Matthias Clasen
c9ab7c5750
Merge branch 'double-dead-keys' into 'master'
...
Double dead keys
See merge request GNOME/gtk!3355
2021-03-27 01:22:41 +00:00
Matthias Clasen
01f4e5c8cd
Add some more compose tests
...
These tests changes to the algorithmic dead key
matching.
2021-03-26 20:38:45 -04:00
Matthias Clasen
8a567d7932
imcontext: Tweak dead key handling
...
Reshuffle things to allow for a limited amount of
dead key 'chaining'. We keep up to 2 dead keys in
the preedit, so you can type
<dead_acute> <dead_cedilla> <c>
to produce ḉ, while still getting ```c with
<dead_grave> <dead_grave> <dead_grave> <c>.
2021-03-26 20:38:45 -04:00
Matthias Clasen
dbcd24adf4
composetable: Limit algorithmic checking
...
Only check for combinations of up to 2 dead keys with
a base character. We don't want to spend ages generating
all permutations of long sequences.
2021-03-26 20:27:55 -04:00
Matthias Clasen
f6f07ba238
Merge branch 'icon-fallback' into 'master'
...
Icon fallback
See merge request GNOME/gtk!3353
2021-03-26 19:33:13 +00:00
Matthias Clasen
3ab07203ce
widget-factory: Add missing icons
...
This removes all the cases where we were showing a missing-image
when running with the hicolor icontheme.
2021-03-26 14:34:40 -04:00
Emmanuele Bassi
70e26d12fb
Update the gi-docgen repository
...
Do not use my personal workspace.
2021-03-26 17:41:58 +00:00
Matthias Clasen
6ba414216c
widget-factory: Drop two icons from the iconview
...
This avoids the scrollbar by default, which is nice.
2021-03-26 13:30:46 -04:00
Matthias Clasen
775b45ef57
icons: Add text-x-generic
...
The file chooser needs at least one icon that we can
fall back to for non-directories. text-x-generic is
that icon.
2021-03-26 13:17:51 -04:00
Matthias Clasen
23cb72875d
filechooser: Check that icons exist
...
Otherwise we end up showing missing-image in the
file chooser, and thats sad.
2021-03-26 13:17:51 -04:00
Matthias Clasen
5940de98dd
icontheme: Add gtk_icon_theme_has_gicon
...
Add a utility function to check whether the icontheme
will produce something better than missing-image for
a GIcon. Obviously, we can only answer this question
if the GIcon is a themed icon the begin with.
2021-03-26 13:17:51 -04:00
Matthias Clasen
4028bd5bce
widget-factory: Add emblem-shared-symbolic icon
...
We use it, so include it.
2021-03-26 11:59:37 -04:00
Matthias Clasen
b5608e93d2
icons: Sync color-select-symbolic with Adwaita
...
This icon changed a bit since we incorporated it.
2021-03-26 11:59:01 -04:00
Matthias Clasen
1ea2ea520f
icons: Add system-run-symbolic
...
This is used by Adwaita for devel headers, so include it.
2021-03-26 11:42:09 -04:00
Matthias Clasen
922b2683b3
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
See merge request GNOME/gtk!3351
2021-03-26 15:30:51 +00:00
Matthias Clasen
6dcef28e12
icon: Add a printer icon
...
This showed up as missing icon in the print dialog when
used with the hicolor icontheme.
2021-03-26 11:30:14 -04:00
Matthias Clasen
08f68cce40
gdk: Add an arg check to gdk_device_get_timestamp
...
Pointed out by Emmanuele Bassi.
2021-03-26 11:09:50 -04:00
Matthias Clasen
7849590a82
gdk: Add gdk_device_get_timestamp
...
Give each device a timestamp that reflects the last
user activity with that device, as reflected in the
events that are produced for this device.
2021-03-26 11:09:05 -04:00
Matthias Clasen
c9b312c860
icons: Add icons that are used in the inspector
...
These were showing up as missing icons when opening
the Inspector with the hicolor icontheme:
system-search-symbolic
go-previous-symbolic
go-next-symbolic
display-brightness-symbolic
2021-03-26 11:00:01 -04:00
Matthias Clasen
6110980012
Merge branch 'device-timestamp' into 'master'
...
Device timestamp
Closes #3792
See merge request GNOME/gtk!3350
2021-03-26 14:51:37 +00:00
Matthias Clasen
019855a27f
textview: Use device timestamps for obscured cursors
...
Stash away the device timestamp when obscuring
the pointer, and compare it when we decice whether
to unobscure it. This fixes a problem where synthetic
motion events would make the cursor reappear
prematurely.
Fixes : #3792
2021-03-26 10:30:33 -04:00
Matthias Clasen
cdfdf031b5
text: Use device timestamps for obscured cursors
...
Stash away the device timestamp when obscuring
the pointer, and compare it when we decice whether
to unobscure it. This fixes a problem where synthetic
motion events would make the cursor reappear
prematurely.
2021-03-26 10:30:33 -04:00
Matthias Clasen
f131d68fef
gdk: Add gdk_device_get_timestamp
...
Give each device a timestamp that reflects the last
user activity with that device, as reflected in the
events that are produced for this device.
2021-03-26 10:30:33 -04:00
Matthias Clasen
3014649455
Merge branch 'pixbuf-loader-check' into 'master'
...
Make testsuite fail if we lack pixbuf loaders
See merge request GNOME/gtk!3348
2021-03-26 11:29:47 +00:00
Matthias Clasen
2496ab0902
Be explicit when building gdk-pixbuf subproject
...
We require png and jpeg loaders.
2021-03-25 22:52:30 -04:00
Matthias Clasen
50d42093b5
Make testsuite fail if we lack pixbuf loaders
...
Add a test that requires that we have png and jpeg
loaders.
2021-03-25 21:23:11 -04:00
Matthias Clasen
44481d355e
Make testsuite fail if we lack pixbuf loaders
...
Add a test that requires that we have png and jpeg
loaders.
2021-03-25 21:22:23 -04:00
Matthias Clasen
6f82408056
Add logging for icon fallback
...
Add GTK_DEBUG=iconfallback which prints out what icon names
we fall back to image-missing for.
2021-03-25 17:26:15 -04:00
Matthias Clasen
cc64dbafbc
Merge branch 'carlosgc/clipboard-crash' into 'master'
...
clipboard: Fix a crash when GdkContentProviderUnion doesn't support the given data format
See merge request GNOME/gtk!3346
2021-03-25 20:48:28 +00:00
Carlos Garcia Campos
50b70298c0
clipboard: Fix a crash when GdkContentProviderUnion doesn't support the given data format
...
After iterating all the providers, all of them returning unsupported
error, gdk_content_provider_union_get_value() returns FALSE without
filing the given GError. Then gdk_clipboard_read_value_internal()
assumes there's a GError when FALSE is returned and
g_task_return_error() fails. We can just chain up to parent
implementation to ensure the GError is filled with unsupported error.
2021-03-25 15:10:00 +01:00
Matthias Clasen
bd7df4b816
Merge branch 'shader' into 'master'
...
ngl: Fix crash with intel driver on Windows when compiling shaders
Closes #3783
See merge request GNOME/gtk!3344
2021-03-25 12:37:12 +00:00
Xavier Claessens
086e1ed39f
ngl: Fix crash with intel driver on Windows when compiling shaders
...
Fixes #3783 .
2021-03-25 08:20:30 -04:00
Matthias Clasen
fa57f20b87
Merge branch 'wip/fix-stack-get-item' into 'master'
...
stack: Fix some list model issues
See merge request GNOME/gtk!3345
2021-03-24 20:34:47 +00:00
Mohammed Sadiq
e211740da6
stack: Fix check if page is selected
...
When there is no visible child, gtk_selection_model_is_selected()
was returning TRUE for any invalid position.
So check if the page is non-NULL and match
2021-03-24 20:23:09 +05:30
Mohammed Sadiq
0351bc766c
stack: Increase reference only if page is non-NULL
...
g_list_nth_data() may return NULL if position is off the end
2021-03-24 20:21:13 +05:30
Matthias Clasen
5531906973
Merge branch 'gles-fallback' into 'master'
...
gdkglcontext-wayland: Fallback to GLES 2.0 after legacy failed
See merge request GNOME/gtk!3327
2021-03-24 11:21:21 +00:00
Matthias Clasen
9d6190bc3c
Merge branch 'gdkmacosglcontext-fix' into 'master'
...
gdkmacosglcontext: fix compilation error
See merge request GNOME/gtk!3342
2021-03-24 11:09:51 +00:00
Tom Schoonjans
d5de73fb9d
gdkmacosglcontext: fix compilation error
...
See https://developer.apple.com/documentation/appkit/nsopenglpixelformat/1436219-initwithattributes?language=occ
2021-03-24 10:08:11 +00:00
Matthias Clasen
b539c92312
Merge branch 'builder-tool-placeholder-crash' into 'master'
...
gtk-builder-tool: Avoid a crash with <placeholder/>
Closes #3781
See merge request GNOME/gtk!3339
2021-03-23 21:02:39 +00:00
Matthias Clasen
272d8a6800
Merge branch 'wip/chergert/ngl-fix-windows-intel-driver' into 'master'
...
ngl: move uniform key mapping into uniform state
Closes #3780
See merge request GNOME/gtk!3340
2021-03-23 21:02:11 +00:00
Christian Hergert
f8a6a09896
ngl: move uniform key mapping into uniform state
...
Previously, we translated the uniform key (an enum) into a location within
the shader program in GskNglProgram. A number of performance improvements
were focused around having low nubers for the uniform locations. Generally
this is the case, but some drivers such as old Intel drivers on Windows
may use rather large numbers for those.
To combat this, we can push the translation of uniform keys into locations
at the GskNglUniformState level so that we work with unranslated keys
through the process until applying them.
Fixes #3780
2021-03-23 13:44:26 -07:00
Matthias Clasen
6a66ccd3e6
gtk-builder-tool: Avoid a crash with <placeholder/>
...
Not sure we can do much with a ui file that has
<placeholder/> elements littered throughout. But
at least we can avoid crashing while trying to
convert it.
Fixes : #3781
2021-03-23 15:25:53 -04:00
Emmanuele Bassi
1f6b556972
Merge branch 'ebassi/for-master' into 'master'
...
Ebassi/for master
See merge request GNOME/gtk!3338
2021-03-23 15:39:47 +00:00
Emmanuele Bassi
3668541eaa
docs: Add a side bar to the docs.gtk.org landing page
...
Make it look like the API references hosted on docs.gtk.org.
2021-03-23 14:58:03 +00:00
Emmanuele Bassi
a6727326e3
docs: Update the Cairo reference link
2021-03-23 14:49:20 +00:00
Emmanuele Bassi
1507099dc7
Merge branch 'ebassi/for-master' into 'master'
...
Publish docs for Pango and GdkPixbuf
See merge request GNOME/gtk!3337
2021-03-23 13:39:18 +00:00
Emmanuele Bassi
2bc7abceae
docs: Drop the external class for links to docs.gtk.org
2021-03-23 13:13:53 +00:00
Emmanuele Bassi
a9a5622214
docs: Link Pango and GdkPixbuf on docs.gtk.org
2021-03-23 13:13:53 +00:00
Emmanuele Bassi
0560397aa8
ci: Build Pango and GdkPixbuf's docs
...
We want to publish them alongside GTK's own API reference.
2021-03-23 13:13:53 +00:00
Matthias Clasen
4e06787a1b
Merge branch 'bilelmoussaoui/expressions-annotations' into 'master'
...
Add missing nullable annotations to BoolFilter/StringFilter
See merge request GNOME/gtk!3334
2021-03-23 00:49:54 +00:00
Matthias Clasen
610ba0e764
Merge branch 'issue3715-gtk4' into 'master'
...
[gtk4] x11/dnd: Ignore XErrors from the COW
Closes #3715
See merge request GNOME/gtk!3336
2021-03-22 15:09:42 +00:00
Olivier Fourdan
80ba38a0b3
x11/dnd: Ignore XErrors from the COW
...
The DnD code for X11 adds the composite overlay window (aka COW) to the
cache.
Yet the X11 requests to get and release the COW may trigger XErrors that
we ought to ignore otherwise the client will abort.
Fixes : #3715
2021-03-22 15:38:58 +01:00
Chun-wei Fan
5d3af346dd
Merge branch 'really-fix-3581' into 'master'
...
GDK-Win32: Remove extraneous call to _gdk_win32_append_event() (really fix issue #3581 )
Closes #3581
See merge request GNOME/gtk!3306
2021-03-22 14:18:44 +00:00
Matthias Clasen
d882def373
Merge branch 'meson-install-script' into 'master'
...
Meson: Use gnome.install_script()
See merge request GNOME/gtk!3135
2021-03-22 12:45:45 +00:00
Bilal Elmoussaoui
3761dbba8b
gtk: add missing nullable annotations to StringFilter
2021-03-22 12:42:19 +01:00
Bilal Elmoussaoui
ae7b19c760
gtk: add missing nullable annotations to BoolFilter
2021-03-22 12:42:13 +01:00
Matthias Clasen
157218c507
Merge branch 'wip/baedert/for-master' into 'master'
...
ngl: Remove unused function
See merge request GNOME/gtk!3332
2021-03-22 11:17:58 +00:00
Matthias Clasen
60325df7db
Merge branch 'better-dead-keys' into 'master'
...
Better dead keys
See merge request GNOME/gtk!3329
2021-03-22 02:37:14 +00:00
Matthias Clasen
64a62ebcfb
Regenerate compose sequence file
...
Update our compose sequences based on the current
update xorg Compose.pre file. Beyond that, remove
some deadkey sequences that we are now handling
(better) in code.
2021-03-21 21:48:03 -04:00
Matthias Clasen
a42a133a18
Move compose related tooling to a subdir
...
This reduces the clutter in gtk/.
2021-03-21 21:48:03 -04:00
Matthias Clasen
a41cd9b1fa
compose-parse: Add a negative lookaside
...
Make this script parse gtk-compose-remove.txt for
sequences to remove from the xorg Compose file.
This will be used for removing some deadkey combinations
that we can handle better in code.
Also, make this script explicitly python2. I tried
porting it to python3, but gave up in the end.
2021-03-21 21:48:03 -04:00
Matthias Clasen
8bfc6afe33
imcontext: Improve dead key handling more
...
For sequences like ``, we want to commit the first
deadkey and then continue preedit with the second.
The alternative is to do chained deadkeys, where
entering ~~a yields ̃̀̃̃a. But we don't do that, and
I think that would be more controversial.
2021-03-21 21:48:03 -04:00
Matthias Clasen
5b67e6817c
imcontext: Improve dead key handling
...
For sequences like `x, where we don't have a compose
sequence, we still want to commit "`x", and not silently
eat the keys.
2021-03-21 21:48:01 -04:00
Matthias Clasen
48f87c1eea
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
See merge request GNOME/gtk!3328
2021-03-21 20:48:04 +00:00
Emmanuel Gil Peyrot
aced6030ee
gdkglcontext-wayland: Fallback to GLES 2.0 after legacy failed
...
This lets the NGL backend be selected instead of the Cairo backend on
devices which expose both GL and GLES, but have better support of GLES.
Tested on a PinePhone.
2021-03-21 20:37:04 +00:00
Matthias Clasen
c5aa35f8ef
inspector: Allow inspecting Unicode
...
Add a way to show text as a Unicode sequence.
This can be helpful in understanding what is
happening with text.
2021-03-21 16:05:10 -04:00
Matthias Clasen
7a56aa910e
ngl: Fix a rounding error in subpixel positioning
...
1024 / 4 is 256, not 250.
2021-03-21 16:05:10 -04:00
Matthias Clasen
bd0df03248
gl: Fix a rounding error in subpixel positioning
...
1024 / 4 is 256, not 250.
2021-03-21 16:05:10 -04:00
Matthias Clasen
df4b564d69
build: Disable g_assert in release builds
...
The ngl renderer is heavily using g_assert, and it
is written with the assumption that these assertions
will be compiled out in release builds.
2021-03-21 16:05:10 -04:00
Matthias Clasen
9640bfb3fe
calendar: Typo fix
2021-03-21 16:05:10 -04:00
Matthias Clasen
2e69273922
ngl: Remove an unused field
...
We are ignoring the debug nodes, so the
debug_groups string chunk is unused.
2021-03-21 16:05:10 -04:00
Matthias Clasen
1e014f4291
ngl: Always populate the glyph front cache
...
There is no reason not to do this also in the
case when we upload the glyph.
2021-03-21 16:05:10 -04:00
Matthias Clasen
fbe47106e7
ngl: Use floorf consistently
2021-03-21 16:05:10 -04:00
Timm Bäder
ea93c40644
ngl: Remove unused function
2021-03-21 18:00:10 +01:00
dparisot
82b11623f4
Load icon from executable on Windows
2021-03-21 15:24:28 +01:00
Piotr Drąg
1a3f2acb95
Update Polish translation
2021-03-20 15:41:34 +01:00
Emmanuele Bassi
fb8592952d
Merge branch 'ebassi/for-master' into 'master'
...
Ebassi/for master
See merge request GNOME/gtk!3324
2021-03-20 12:31:10 +00:00
Emmanuele Bassi
216a262651
docs: Put core deps below UI links
...
We assume people will be more interested in GTK if they get to
docs.gtk.org.
2021-03-20 12:18:42 +00:00
Emmanuele Bassi
0178cdbdf2
docs: Fix typo in the docs landing page
2021-03-20 12:18:26 +00:00
Yuri Chornoivan
b84d959d31
Update Ukrainian translation
2021-03-20 08:54:01 +00:00
Yuri Chornoivan
3eca28e4b5
Update Ukrainian translation
2021-03-20 08:51:46 +00:00
Emmanuele Bassi
98a91a3290
Merge branch 'a11y-strdup' into 'master'
...
a11y: Don't copy attribute names in attribute sets
See merge request GNOME/gtk!3323
2021-03-19 22:31:37 +00:00
Matthias Clasen
3cfe69d711
a11y: Don't copy attribute names in attribute sets
...
We only need these names when serializing a11y information
for tests. And copying these strings is entirely unnecessary.
So, just pass a callback instead.
2021-03-19 17:01:28 -04:00
Matthias Clasen
b9da74590b
Merge branch 'ngl-glyph-cache' into 'master'
...
Ngl glyph cache
See merge request GNOME/gtk!3322
2021-03-19 18:59:33 +00:00
Matthias Clasen
b253aca883
ngl: Improve the glyph front cache
...
The effectiveness of the front cache is limited by
subpixel positioning making it very likely that we
will meet the same glyph in different x phases inside
a single line of text.
Factoring the xphase into the front cache key makes things
better. For the string eeeeeeeeeeeeeeeeeee
before: 0% front cache hits
after: >90% front cache hits
2021-03-19 14:32:03 -04:00
Matthias Clasen
5ac7f7c2f6
ngl: Drop an unused struct member
...
GskNglGlyphLibrary.hash_table wasn't used.
2021-03-19 14:05:15 -04:00
Matthias Clasen
9981f19409
texttag: A few typo fixes
2021-03-19 14:04:27 -04:00
Emmanuele Bassi
dae59112d7
Merge branch 'ebassi/for-master' into 'master'
...
Ebassi/for master
See merge request GNOME/gtk!3321
2021-03-19 17:57:42 +00:00
Emmanuele Bassi
f25beff7a6
docs: Restructure the list of UI libraries
...
Put GTK at the top.
2021-03-19 17:23:46 +00:00
Emmanuele Bassi
130ed3d5e5
docs: Fix typo in the docs landing page
2021-03-19 17:23:29 +00:00
Matthias Clasen
830efa6ce2
Revert "ngl: Remove duplicate check"
...
This reverts commit 1fd534ef1e .
This change revealed that we are not treating damage regions
correctly, and we regularly end up with
2021-03-19 13:17:02 -04:00
Emmanuele Bassi
a33e32ef60
Merge branch 'ebassi/for-master' into 'master'
...
Fix the landing page structure
See merge request GNOME/gtk!3320
2021-03-19 14:55:12 +00:00
Emmanuele Bassi
aaffd902fd
Fix the landing page structure
2021-03-19 14:36:34 +00:00
Emmanuele Bassi
972a06c038
Merge branch 'pages-index' into 'master'
...
Add a landing page for the GitLab pages root
See merge request GNOME/gtk!3319
2021-03-19 14:14:46 +00:00
Emmanuele Bassi
1763ede9ce
Add a landing page for the GitLab pages root
...
Right now, we land inside a 404 if we go to:
https://gnome.pages.gitlab.gnome.org/gtk/
as we have all our API references in a sub-level. We should have a
landing page for the root, similar to developer.gnome.org/references/.
2021-03-19 13:54:32 +00:00
Matthias Clasen
f5fb8a95f4
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
See merge request GNOME/gtk!3317
2021-03-19 05:44:39 +00:00
Matthias Clasen
948e032072
text tag: Typo fix
2021-03-18 22:53:37 -04:00
Matthias Clasen
21aa8ae29f
Cosmetics
...
Remove a stale comment.
2021-03-18 22:53:37 -04:00
Matthias Clasen
4fce3ceffc
Cosmetics
...
Pack the GtkTextAttributes struct better.
2021-03-18 22:53:37 -04:00
Matthias Clasen
95a5e7b438
release script: Include gi-docgen
...
This lets us say 'you don't need to package this'
about gi-docgen.
2021-03-18 22:53:27 -04:00
Matthias Clasen
8fdedbd73b
Merge branch 'ngl-by-default' into 'master'
...
gsk: Make ngl the default OpenGL renderer
See merge request GNOME/gtk!3313
2021-03-19 02:01:34 +00:00
Matthias Clasen
b962a0f166
Merge branch 'wip/chergert/fix-ngl-cache-eviction' into 'master'
...
fix ngl cache eviction
Closes #3771
See merge request GNOME/gtk!3316
2021-03-19 01:59:29 +00:00
Christian Hergert
0f0ee97e1e
ngl: clear Glyph front cache at the beginning of a frame
...
We don't want to be responsible for duplicating the effort of the hash
table, we just want to speed up subsequent lookups. Otherwise, we risk
not marking glyph usage when tracking usage for compaction.
2021-03-18 18:00:04 -07:00
Christian Hergert
af80f3a976
ngl: implement atlas compaction
...
This required finishing up the begin_frame/end_frame semantics for
GskNglTextureLibraryw which was apparently overlooked.
The driver was changed to provide more information to the library when
beginning frames. We do not need to use end_frame so that was removed.
The frame age is the same as GL (60) but I do wonder if that is based
on seconds if we should be using something longer for situations where
we have higher frame rates.
Fixes #3771
2021-03-18 17:59:56 -07:00
Matthias Clasen
1536f6a59c
Merge branch 'matthiasc/for-master' into 'master'
...
inspector: Respect GDK_DEBUG=vulkan-disable
Closes #3748
See merge request GNOME/gtk!3312
2021-03-18 21:43:14 +00:00
Matthias Clasen
574b0bf48a
Merge branch 'bilelmoussaoui/4.2-annotations' into 'master'
...
IMContext: add since annotations to the new APIs
See merge request GNOME/gtk!3315
2021-03-18 21:42:35 +00:00
Bilal Elmoussaoui
0b100229e3
IMContext: add since annotations to the new APIs
2021-03-18 22:25:38 +01:00
Matthias Clasen
19d9c78514
gsk: Make ngl the default OpenGL renderer
...
We will keep the original GL renderer around for
a while, to have an alternative. But we want to
get wider testing of the new renderer.
2021-03-18 15:00:39 -04:00
Matthias Clasen
140b7f0a61
Merge branch 'wip/chergert/fix-3770' into 'master'
...
ngl: ensure vertices buffer allocates enough vertices
Closes #3770
See merge request GNOME/gtk!3314
2021-03-18 17:55:26 +00:00
Christian Hergert
56daad9c35
ngl: ensure vertices buffer allocates enough vertices
...
It's not guaranteed that a single power of two growth will be enough.
Fixes #3770
2021-03-18 10:43:24 -07:00
Matthias Clasen
eaf09a4625
Cosmetics
...
Pango lets us pass NULL for the font desc and language
in pango_context_get_font_metrics() to use the context
values.
2021-03-18 07:52:03 -04:00
Matthias Clasen
a576bd190b
inspector: Respect GDK_DEBUG=vulkan-disable
...
Respect the debug settings for disabling Vulkan or GL,
and do not try to initialize those contexts. This can
be necessary to work around crashes.
Fixes : #3748
2021-03-17 23:19:08 -04:00
Matthias Clasen
2ce92085e1
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
Closes #3765
See merge request GNOME/gtk!3311
2021-03-18 00:31:10 +00:00
Matthias Clasen
e6b1443fbb
label: Fix tooltips on links
...
Fix pointed out by Timm Baeder.
Fixes : #3765
2021-03-17 19:46:02 -04:00
Matthias Clasen
60ccae000b
media: Always use GL with gstreamer
...
As long as we can create a GL context, pass one to
gstreamer. This at least gets us GL textures with
the ngl renderer, the previous code was arbitrarily
refusing that.
2021-03-17 16:28:12 -04:00
Timm Bäder
7ecd004d50
Merge branch 'gsk-border-node-diff-fix-typo' into 'master'
...
Fix a typo in gsk_border_node_diff
See merge request GNOME/gtk!3310
2021-03-17 16:04:57 +00:00
Andrey Kozlovskiy
6b48fb767d
Fix a typo in gsk_border_node_diff
...
Typo was introduced in !3278 and results in an incorrect handling of different uniformity.
2021-03-17 15:38:01 +00:00
Emmanuele Bassi
6d4f93bb7f
Merge branch 'select-list-model-null' into 'master'
...
gtk: Allow selection models to take null list model during construction
See merge request GNOME/gtk!3309
2021-03-17 14:09:37 +00:00
Matthias Clasen
cfe8c0e187
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
Closes #3763
See merge request GNOME/gtk!3308
2021-03-17 12:32:45 +00:00
Matthias Clasen
6d5657eee7
lpr: Fix various compiler warnings
...
gcc 11 is warning about some const mixups here.
Fix them.
2021-03-17 07:56:07 -04:00
Matthias Clasen
600cbdb7ba
treestore: Initialize some local variables
...
gcc 11 is warning that these might be used uninitialized
otherwise.
2021-03-17 07:51:27 -04:00
Matthias Clasen
8b82993dde
sizerequest: Avoid a corner case
...
gcc 11 warns that the code isn't safe when
n_requested_sizes is 0. Add a precondition check
to make it clear that that never happens.
2021-03-17 07:50:24 -04:00
Matthias Clasen
ea185cbdda
cssshadowvalue: Handle error condition propertly
...
We were parsing off the end of our array before noticing
that we've gone too far. gcc 11 warns about this.
2021-03-17 07:49:06 -04:00
Matthias Clasen
ee837dfc12
checkbutton: Add a warning about cyclic groups
...
Setting up check or toggle button group relationships
in a cycle will lead to lockups. Add a warning about
this, and catch the simplest case with a precondition
check.
Fixes : #3763
2021-03-17 07:38:57 -04:00
Matthias Clasen
1d888bff43
Drop the gtk-doc subproject
...
No longer used.
2021-03-17 07:28:31 -04:00
Chun-wei Fan
38ad068d9b
GDK-Win32: Remove extraneous call to _gdk_win32_append_event()
...
Apparently, by comparing with the other backends, we should not call
_gdk_win32_append_event() after calling gdk_scroll_event_new() but we should
call it after calling gdk_scroll_event_new_discrete(), which was why we didn't
restore the cursor after we scroll using the mouse wheel and didn't manage to
remove the shade that appears after we scrolled to the very top or very bottom.
Also, as suggested by the reporter, use IDC_SIZEALL for the system cursor that
we fall back to if no cursor theme is installed, as with other Windows
programs.
This should really fix issue #3581 .
2021-03-17 11:22:23 +08:00
Balázs Úr
45c8c6c77f
Update Hungarian translation
2021-03-16 23:49:27 +00:00
Matthias Clasen
ceed7d1ba4
Merge branch 'matthiasc/for-master' into 'master'
...
dnd: Add some warnings to the docs
See merge request GNOME/gtk!3305
2021-03-16 19:12:05 +00:00
Matthias Clasen
74e2bb4cf1
dnd: Add some warnings to the docs
...
Add some warnings about pitfalls of the async dnd api.
2021-03-16 14:48:44 -04:00
Matthias Clasen
cc6bb13242
Merge branch 'kjellahl/cairo-subproject' into 'master'
...
Fix build when cairo is a subproject
See merge request GNOME/gtk!3304
2021-03-16 11:43:06 +00:00
Kjell Ahlstedt
50beae7541
meson: Find libcairo-script-interpreter when cairo is a subproject
...
If cairo is a subproject, it's not necessarily installed when gtk
is built. In the build tree, libcairo-script-interpreter is not stored
in the same directory as other cairo libraries.
2021-03-16 11:47:28 +01:00
Kjell Ahlstedt
0f6b91109e
gdkglcontext-x11: Don't assume that cairo-xlib.h is in cairo directory
...
If cairo is a subproject, it's not necessarily installed when gtk
is built. In the source tree, cairo's headers are not stored in
a directory called 'cairo'.
2021-03-16 11:47:16 +01:00
Matthias Clasen
f279c7b1c2
Merge branch 'fix-3581' into 'master'
...
gdkcursor-win32.c: Add cursor map for all-scroll (issue #3581 )
Closes #3581
See merge request GNOME/gtk!3298
2021-03-15 22:32:23 +00:00
Matthias Clasen
08b27848e1
Merge branch 'fix-wayland-layout-changes' into 'master'
...
Fix wayland layout changes
See merge request GNOME/gtk!3303
2021-03-15 22:31:08 +00:00
Matthias Clasen
e3dcc3d369
wayland: Fix cross-layout accelerators
...
GTK traditionally lets you activate keyboard shortcuts
even if they are for a non-active layout. But it is meant
to only activate with a keysym from a non-active layout
when that symbol is not present in the current layout.
That last condition was lost when key event handling
was redone for GTK4. Bring it back.
2021-03-15 17:14:49 -04:00
Matthias Clasen
568fe2e97b
wayland: Add debug spew for active keyboard layouts
...
Print out what we think the active keyboard layout is,
when it changes, with GDK_DEBUG=input.
2021-03-15 17:14:49 -04:00
Jason Francis
cd77485193
gtk: Allow selection models to take null list model during construction
...
This brings it in line with the documentation, and with the respective
set_model() functions.
2021-03-15 15:55:47 -04:00
Matthias Clasen
ec0e76dabd
Merge branch 'issue-3757' into 'master'
...
docs: Update annotations for WidgetClass.query_action()
Closes #3757
See merge request GNOME/gtk!3301
2021-03-15 19:28:17 +00:00
Matthias Clasen
1eebf0ebd1
wayland: Emit keys-changed on layout changes
...
We were forgetting to do this in when layout changes are
communicated via handle_modifiers.
2021-03-15 12:34:23 -04:00
Emmanuele Bassi
0a7af75639
docs: Update annotations for WidgetClass.query_action()
...
The parameter_type and property_name out arguments can be set to NULL.
Fixes : #3757
2021-03-15 13:48:35 +00:00
Milo Casagrande
72012113fd
Update Italian translation
...
(cherry picked from commit affeff5472 )
2021-03-15 09:25:36 +00:00
Chun-wei Fan
54b3048584
gdkcursor-win32.c: Add cursor map for all-scroll
...
This makes sure that we don't have cursors disappearing on Windows upon
scrolling because we can't find a cursor that exists on the system during
a scroll, and unlike GTK-3.x, we do not default to the arrow pointer on GTK4.
Just mimic what we have on X11 and Wayland: the trusty standard arrow pointer.
Fixes issue #3581 .
2021-03-15 17:16:33 +08:00
Matthias Clasen
3daad8fe87
release-script: Actually compress the docs tarball
...
Somehow an x got lot and the tarball got very big. Oops...
2021-03-14 23:33:10 -04:00
Benjamin Otte
a1c1ad317b
Merge branch 'wip/otte/for-master' into 'master'
...
Wip/otte/for master
See merge request GNOME/gtk!3297
2021-03-15 02:31:45 +00:00
Benjamin Otte
dbd19bf27a
x11: Don't call _gdk_surface_update_size() all the time
...
We were calling _gdk_surface_update_size() every frame, even if the
window size didn't change. This would cause us to discard all cached
buffers and redraw the whole screen.
This was BAD.
2021-03-15 03:16:50 +01:00
Benjamin Otte
97fad45237
surface: Remove unused gdk_surface_get_unscaled_size()
...
Also remove unscaled_width/height members in the win32 backend.
Both of those are unused.
2021-03-15 02:56:28 +01:00
Matthias Clasen
cbda61d3fb
4.1.2
2021-03-14 21:48:48 -04:00
Matthias Clasen
afe195a862
Update release script
...
With gi-docgen based docs, we can try to go back to
including the docs in the main release tarball.
2021-03-14 21:48:46 -04:00
Matthias Clasen
e6adee2403
Merge branch 'menubar-accel' into 'master'
...
window: Add a way to disable F10 shortcut
Closes #3727
See merge request GNOME/gtk!3296
2021-03-15 01:27:45 +00:00
Benjamin Otte
1fd534ef1e
ngl: Remove duplicate check
...
We check the extents, so there's no need to check overlap before.
2021-03-15 01:30:34 +01:00
Matthias Clasen
cfc91b62b0
window: Add a way to disable F10 shortcut
...
This is needed for terminal emulators.
Fixes : #3727
2021-03-14 19:47:06 -04:00
Matthias Clasen
24ec2cc6a6
Merge branch 'ngl-less-shaders' into 'master'
...
Assorted ngl improvements
See merge request GNOME/gtk!3295
2021-03-14 21:04:37 +00:00
Matthias Clasen
28de2eecc9
ngl: Special-case css backgrounds
...
Recognize a common pattern: A rounded clip with
a color node, followed by a border node, with the
same outline. This is what CSS backgrounds frequently
produce, and we can render it more efficiently with
a combined shader.
2021-03-14 16:49:31 -04:00
Matthias Clasen
ed3f0012b1
ngl: Don't bother with uniform border nodes
...
Now that colors aren't uniforms anymore, we don't
win much by using the inset_shadow shader. The fragment
shaders of inset_shadow and border are identical. And
the regular border setup does nine-slicing.
2021-03-14 16:49:31 -04:00
Matthias Clasen
51074ca5df
ngl: Small shader improvements
...
Add a variant of gskSetOutputColor that saves a
few multiplications, and use it where possible.
2021-03-14 16:49:31 -04:00
Matthias Clasen
8aac574d63
ngl: Improve the coloring shader
...
Since we are now passing a float anyway, we can avoid
the branch in the fragment shader.
2021-03-14 16:49:31 -04:00
Matthias Clasen
c1f98d6837
ngl: Improve the gradient shaders
...
Use a define for MAX_COLOR_STOPS, and give the loop
a fixed limit.
2021-03-14 16:49:31 -04:00
Matthias Clasen
3f60c39de4
ngl: Rewrite gsk_ngl_render_job_visit_text_node
...
Make this more compact, and thus easier to read.
2021-03-14 16:49:31 -04:00
Matthias Clasen
4aa570ba88
ngl: Drop gsk_ngl_render_job_set_color
...
Colors are not state that we carry across draw ops,
so setting the color on the render job doesn't make
much sense. Instead, pass the color to the various
draw calls. Add a few new ones for that purpose.
Also, shorten the names of some by going from
'load_vertices_from_offscreen' to 'draw_offscreen'.
2021-03-14 16:49:31 -04:00
Matthias Clasen
233969e9e4
ngl: Refactor gsk_ngl_render_job_visit_border_node
...
With color sorting out of the picture, this can
be much simpler.
2021-03-14 16:49:31 -04:00
Matthias Clasen
19e3a6af5d
ngl: Consistently use gsk_scaled_premultiply
...
Its not going to make much of a difference, but we
can just as well be consistent.
2021-03-14 16:49:31 -04:00
Matthias Clasen
29501f5398
ngl: Fix up uniform enums
...
This got messed up when color was changed from
a uniform to an attribute in 06d5c8e72d .
2021-03-14 16:49:31 -04:00
Jiri Grönroos
3408240ba6
Update Finnish translation
...
(cherry picked from commit f5a34b53af )
2021-03-14 17:03:07 +00:00
Guillaume Bernard
e6725aa16f
Update French translation
...
(cherry picked from commit 21039681d6 )
2021-03-14 13:38:24 +00:00
Piotr Drąg
f34c0f4a99
Update Polish translation
2021-03-14 13:30:26 +01:00
Marek Černocký
52c7fd166b
Updated Czech translation
2021-03-14 09:28:17 +01:00
Matthias Clasen
346b29ad8f
Merge branch 'gles-coloring' into 'master'
...
ngl: Fix the coloring shader on GLES 2.0
See merge request GNOME/gtk!3294
2021-03-13 22:27:04 +00:00
Emmanuel Gil Peyrot
064947356a
ngl: Fix the coloring shader on GLES 2.0
...
Integer varyings didn’t exist in GLSL ES 1.00, neither did the flat
attribute.
2021-03-13 22:00:54 +00:00
Kjartan Maraas
d2258fb316
Update Norwegian Bokmål translation
...
(cherry picked from commit 70ee21db71 )
2021-03-13 16:05:15 +00:00
Matthias Clasen
dda66d580f
Merge branch 'ebassi/for-master' into 'master'
...
docs: Fix the dependencies links
See merge request GNOME/gtk!3284
2021-03-13 12:36:56 +00:00
Matthias Clasen
1d773df9f2
Merge branch 'ngl-textview-cursor' into 'master'
...
Ngl textview cursor
See merge request GNOME/gtk!3292
2021-03-13 12:33:15 +00:00
Matthias Clasen
9be2f130f0
textview: Fix blinking block cursors
...
When we have a block cursor, we need to discard the
cached node of the line containing the cursor, in order
to get a blinking cursor.
2021-03-12 21:50:07 -05:00
Matthias Clasen
e345f9a4db
textview: Fix blinking block cursors
...
When we have a block cursor, we need to discard the
cached node of the line containing the cursor, in order
to get a blinking cursor.
2021-03-12 19:44:31 -05:00
Matthias Clasen
3a928c8980
textlayout: Render cursors at the end
...
Don't place the insertion cursor render nodes in the
middle of the text nodes for all the text. This helps
the renderer batching the text draw calls together.
2021-03-12 19:28:36 -05:00
Matthias Clasen
42dfc21b2d
ngl: Fix up some debug printouts
2021-03-12 18:26:15 -05:00
Matthias Clasen
daed57c30e
Merge branch 'wip/chergert/fewer-uniforms' into 'master'
...
ngl: apply fewer uniforms
See merge request GNOME/gtk!3289
2021-03-12 22:55:00 +00:00
Matthias Clasen
de0860c1bf
Merge branch 'pgriffis/readme-fixes' into 'master'
...
readme: Fix broken doc links
See merge request GNOME/gtk!3291
2021-03-12 22:51:16 +00:00
Patrick Griffis
4fbc63f50a
readme: Fix broken doc links
2021-03-12 22:02:55 +00:00
Matthias Clasen
3e1524fade
Merge branch 'ngl-vertex-attributes' into 'master'
...
Ngl vertex attributes
See merge request GNOME/gtk!3290
2021-03-12 21:26:52 +00:00
Matthias Clasen
ebe30d851b
ngl: Identify shaders
...
Add a comment with a name to each shader. That makes
identifying the shaders in apitrace much easier.
2021-03-12 15:35:40 -05:00
Christian Hergert
f97ce21e59
ngl: reintroduce comparison checks
...
This reduces how many changes we make when recording uniform state, which
increases the chances that the data offset will be the same when applying
uniforms.
2021-03-12 11:47:15 -08:00
Christian Hergert
0b7d8e19c3
ngl: add front cache to reduce uniform changes
...
Since we make full snapshots when recording uniform state of batches, we
need to perform some deduplication to avoid so many repeated uniform calls.
This uses a closed hashtable to determine if we are likely changing the
value to something new.
This does not currently compare values, it instead only compares that we
are going to point at a new offset into the uniform buffer. We could go
further if we compare upon updating values (we did that early on in the
prototype) so that offsets are less likely to be changed.
2021-03-12 11:22:59 -08:00
Matthias Clasen
0ee6868b7f
gtk-demo: Add a test for scrolling with Emoji
...
Make a text with lots of Emoji and text. This
is exercising the GL renderers switching between
different shaders for color and plain glyphs.
2021-03-12 13:19:37 -05:00
Matthias Clasen
6a30c6b01c
ngl: Make the coloring shader more versatile
...
When the color passed is transparent black, use
the color from the texture as source, instead of
as mask. This lets use use the coloring program
both for regular and color glyphs, avoiding
program changes in text with Emoji.
2021-03-12 13:19:37 -05:00
Matthias Clasen
06d5c8e72d
ngl: Set color as vertex attribute
...
Instead of using uniforms for color used in multiple
programs, pass it as vertex attributes. This will let
us batch more draw calls, since we don't have to change
uniforms so often. In particular, for syntax-highlighted
text.
2021-03-12 13:18:47 -05:00
Matthias Clasen
3252f1e301
gsk: Give ngl its own shader sources
...
We may want to change the interface between the
shaders and the renderer for ngl, and therefore,
sharing the shaders between gl and ngl will not
be practical, going forward.
2021-03-12 13:18:47 -05:00
Matthias Clasen
7f292d34bd
Merge branch 'fix-3704' into 'master'
...
gdksurface-win32.c: Fix window menu positioning (issue #3704 )
Closes #3704
See merge request GNOME/gtk!3286
2021-03-12 14:06:33 +00:00
Emmanuele Bassi
7c29847fbf
build: Install the API references
...
We are building them, but not installing them.
2021-03-12 11:32:09 +00:00
Emmanuele Bassi
66f0547ebf
docs: Fix the dependencies links
...
Use the GitLab pages location until we can link to a proper space on
developer.gnome.org.
2021-03-12 11:18:37 +00:00
Chun-wei Fan
e941e2be7d
gdksurface-win32.c: Fix window menu positioning
...
We ought to get the coordinates of where the window menu should be
displayed using gdk_win32_surface_get_root_coords(), instead of rounding
the position that we obtained with gdk_event_get_position().
Also rename items a bit in the same function, and call
gdk_event_get_event_type() for consistency with the other backends.
Fixes issue #3704 .
2021-03-12 18:45:43 +08:00
Changwoo Ryu
28e33bc26c
Update Korean translation
...
(cherry picked from commit 7774d5d85e )
2021-03-12 08:51:03 +00:00
Emmanuele Bassi
372513a5e2
Merge branch 'bilelmoussaoui/shortcuts-annotation' into 'master'
...
g-i: fix gtk_shortcut_label_new annotation
See merge request GNOME/gtk!3285
2021-03-11 18:40:32 +00:00
Bilal Elmoussaoui
5c505aefc4
g-i: fix gtk_shortcut_label_new annotation
2021-03-11 18:21:56 +00:00
Emmanuele Bassi
9b3ca7f6b1
Merge branch 'ebassi/gidocgen' into 'master'
...
Move API reference to gi-docgen
See merge request GNOME/gtk!3222
2021-03-11 17:11:57 +00:00
Emmanuele Bassi
c5ddf5b381
docs: Add URL maps for cross links
2021-03-11 16:46:02 +00:00
Emmanuele Bassi
61712bfb3b
docs: Enable search
2021-03-11 16:37:38 +00:00
Emmanuele Bassi
c3eb3f2943
docs: Update the "running GTK apps" section
...
Style the content a bit better, and use the appropriate links.
2021-03-11 16:37:38 +00:00
Matthias Clasen
d13e592dbf
Small updates to the coding and documentation style
...
Mention summary sentences, and a few other things.
2021-03-11 16:37:38 +00:00
Emmanuele Bassi
686f65f267
build: Add missing variable definition
2021-03-11 16:37:38 +00:00
Emmanuele Bassi
bb2ee71cd8
build: Add a GIR dependency to PangoCairo
...
This is not strictly needed from an introspection perspective, but:
- GTK strictly depends on PangoCairo internally
- we want to integrate the GDK docs with PangoCairo's
So even though we don't have an explicit dependency on PangoCairo types
in our ABI, we do assume that people will be able to use the PangoCairo
API with GTK.
2021-03-11 16:37:38 +00:00
Emmanuele Bassi
816383e9ef
Handle static inline GtkOrdering function
...
The introspection scanner does not handle `static inline` functions:
they are not in the shared library, so cannot be dlsym() out of it; and
the `static` keyword tells g-ir-scanner to skip the function declaration
entirely.
We can trick the scanner into thinking the gtk_ordering_from_cmpfunc()
symbol is a real, public one, by declaring and defining a regular
function under the `__GI_SCANNER__` guard; the symbol does not appear
when actually building GTK, or any code using GTK, so we don't risk
collisions.
2021-03-11 16:37:38 +00:00
Emmanuele Bassi
90cf6bb686
docs: Show class hierarchy in the API references
2021-03-11 16:37:38 +00:00
Matthias Clasen
e930433800
label: Fix some external links
...
I had put in a bunch of [class@Pango.Attribute ],
but it needs to be [struct@Pango.Attribute ].
Know your dependencies` type hierarchy!
2021-03-11 16:37:38 +00:00
Matthias Clasen
a6b2994f8b
text: Fix some copy-paste mishap
...
A bunch of occurrances of "the self" looked like
absurdist short fiction:
"...the self scrolled off the screen to the left"
2021-03-11 16:37:38 +00:00
Matthias Clasen
8d7103116a
widget: Fix up some links
...
Fix up some links to vfuncs and to sections, as well as class methods.
2021-03-11 16:37:38 +00:00
Matthias Clasen
9d95c5a26d
shortcuttrigger: Convert docs
2021-03-11 16:37:38 +00:00
Matthias Clasen
9fbe61e01f
shortcutlabel: Convert docs
2021-03-11 16:37:38 +00:00
Matthias Clasen
7c442c1736
shortcutcontroller: Convert docs
2021-03-11 16:37:38 +00:00
Matthias Clasen
48a3b4e7cd
shortcutaction: Convert docs
2021-03-11 16:37:38 +00:00
Matthias Clasen
90ecf58a9c
shortcut: Convert docs
2021-03-11 16:37:38 +00:00
Matthias Clasen
0a966e59e6
sizegroup: Convert docs
2021-03-11 16:37:38 +00:00
Matthias Clasen
acb78afc2d
testutils: Convert docs
2021-03-11 16:37:38 +00:00
Matthias Clasen
d0ed62e747
snapshot: Convert docs
2021-03-11 16:37:38 +00:00
Matthias Clasen
44e977ef35
tooltip: Convert docs
2021-03-11 16:37:38 +00:00
Matthias Clasen
f93f975e42
settings: Convert docs
2021-03-11 16:37:38 +00:00
Matthias Clasen
9fa8b446cc
recentmanager: Convert docs
2021-03-11 16:37:38 +00:00
Matthias Clasen
e065b28d1a
mountoperation: Convert docs
2021-03-11 16:37:37 +00:00
Matthias Clasen
6108759d63
menutrackeritem: Remove SECTION
...
This is private
2021-03-11 16:37:37 +00:00
Matthias Clasen
4e315b81cc
menutracker: Remove SECTION
...
This is private.
2021-03-11 16:37:37 +00:00
Matthias Clasen
802c976d07
treesortable: Add a summary
2021-03-11 16:37:37 +00:00
Matthias Clasen
a5018ed029
treeselection: Add a summary
2021-03-11 16:37:37 +00:00
Matthias Clasen
1a09c361f5
treemodelsort: Add a summary
2021-03-11 16:37:37 +00:00
Matthias Clasen
58f64c85ca
treemodelfilter: Add a summary
2021-03-11 16:37:37 +00:00
Matthias Clasen
9a6886e5e2
treemodel: Add a summary
2021-03-11 16:37:37 +00:00
Matthias Clasen
deef6425b3
treednd: Add summaries
2021-03-11 16:37:37 +00:00
Matthias Clasen
9e3df3fac1
treestore: Add a summary
2021-03-11 16:37:37 +00:00
Matthias Clasen
03e21fc957
liststore: Add a summary
2021-03-11 16:37:37 +00:00
Matthias Clasen
3ed729e1d7
treeviewcolumn: Add a summary
2021-03-11 16:37:37 +00:00
Matthias Clasen
1cde6a2e08
treeview: Add a summary
2021-03-11 16:37:37 +00:00
Matthias Clasen
f937fe4a87
windowgroup: Convert docs
2021-03-11 16:37:37 +00:00
Matthias Clasen
190292a7da
listbox: Convert docs
2021-03-11 16:37:37 +00:00
Matthias Clasen
86d2a44850
iconview: Add a summary
2021-03-11 16:37:37 +00:00
Matthias Clasen
ef429c587b
constraintsolver: Remove SECTION
...
This is private
2021-03-11 16:37:37 +00:00
Matthias Clasen
f9cb67b32c
cellview: Add a summary
2021-03-11 16:37:37 +00:00
Matthias Clasen
f6932b885d
cellrenderertoggle: Add a summary
2021-03-11 16:37:37 +00:00
Matthias Clasen
b1ba7f4380
cellrenderertext: Add a summary
2021-03-11 16:37:37 +00:00
Matthias Clasen
2eae3e8e78
cellrendererspinner: Add a summary
2021-03-11 16:37:37 +00:00
Matthias Clasen
077fe55d81
cellrendererspin: Add a summary
2021-03-11 16:37:37 +00:00
Matthias Clasen
e92e14c845
cellrendererprogress: Add a summary
2021-03-11 16:37:37 +00:00
Matthias Clasen
8b7f39ead8
cellrendererpixbuf: Add a summary
2021-03-11 16:37:37 +00:00
Matthias Clasen
48a94ccbfc
celleditable: Add a summary
2021-03-11 16:37:37 +00:00
Matthias Clasen
a9b163cd7f
cellrenderercombo: Add a summary
2021-03-11 16:37:37 +00:00
Matthias Clasen
3236b1d1c9
cellrendereraccel: Add a summary
2021-03-11 16:37:37 +00:00
Matthias Clasen
d85fa8854e
cellrenderer: Add a summary
2021-03-11 16:37:37 +00:00
Matthias Clasen
522ae8d02f
celllayout: Add a summary
2021-03-11 16:37:37 +00:00
Matthias Clasen
7173223df5
cellareacontext: Add a summary
2021-03-11 16:37:37 +00:00
Matthias Clasen
186d2c2964
cellareabox: Add a summary
2021-03-11 16:37:37 +00:00
Matthias Clasen
ccb40688ec
cellarea: Add a summary
2021-03-11 16:37:37 +00:00
Matthias Clasen
8d888203f0
actionobserver: Drop SECTION
...
This is private.
2021-03-11 16:37:37 +00:00
Matthias Clasen
a63223b25b
actionobservable: Drop SECTION
...
This is private.
2021-03-11 16:37:37 +00:00
Matthias Clasen
3cccb00f51
actionmuxer: Drop SECTION
...
This is private.
2021-03-11 16:37:37 +00:00
Matthias Clasen
cc0df3c315
accessiblevalue: Drop SECTION
...
This is private.
2021-03-11 16:37:37 +00:00
Matthias Clasen
7b08e9b5d3
cssdataurl: Drop SECTION
...
This is private
2021-03-11 16:37:37 +00:00
Matthias Clasen
b019cabd0c
bloomfilter: Drop the SECTION
...
This is private, no need.
2021-03-11 16:37:37 +00:00
Matthias Clasen
260a4db854
accelgroup: Convert docs
...
Drop an unused SECTION, and convert links.
2021-03-11 16:37:37 +00:00
Matthias Clasen
8497f285c4
scrollbar: Tweak docs
2021-03-11 16:37:37 +00:00
Matthias Clasen
6925843221
placesview: Remove SECTION
...
Its private, no need.
2021-03-11 16:37:37 +00:00
Matthias Clasen
a6a7799dc5
placessidebar: Remove SECTION
...
Its private, no need.
2021-03-11 16:37:37 +00:00
Matthias Clasen
3205cc79a7
modelbutton: Remove SECTION
...
Its private, no need.
2021-03-11 16:37:37 +00:00
Matthias Clasen
71fce93088
filechooserwidget: Convert docs
2021-03-11 16:37:37 +00:00
Matthias Clasen
537d6e5e65
treelistmodel: Convert docs
2021-03-11 16:37:37 +00:00
Matthias Clasen
d0b1e2f7de
treeexpander: Convert docs
2021-03-11 16:37:37 +00:00
Matthias Clasen
eb675e3e7e
shortcuttrigger: Tweak docs
2021-03-11 16:37:37 +00:00
Matthias Clasen
3f201aeb21
selectionmodel: Convert docs
2021-03-11 16:37:37 +00:00
Matthias Clasen
da6b6d44c1
multiselection: Convert docs
2021-03-11 16:37:37 +00:00
Matthias Clasen
b873b83691
listlistmodel: Remove SECTION
...
Private, no point.
2021-03-11 16:37:37 +00:00
Matthias Clasen
19f649ec1d
noselection: Convert docs
2021-03-11 16:37:37 +00:00
Matthias Clasen
a786af0c19
selectionfiltermodel: Convert docs
2021-03-11 16:37:37 +00:00
Matthias Clasen
42e9cf88cf
immulticontext: Convert docs
2021-03-11 16:37:37 +00:00
Matthias Clasen
33d7aff67e
imcontextsimple: Convert docs
2021-03-11 16:37:37 +00:00
Matthias Clasen
4e4050813a
gestureswipe: Convert docs
2021-03-11 16:37:37 +00:00
Matthias Clasen
2d55e3343a
papersize: Convert docs
2021-03-11 16:37:37 +00:00
Matthias Clasen
8d8fd63b93
gesturestylus: Convert docs
2021-03-11 16:37:37 +00:00
Matthias Clasen
e2cab4d406
imcontext: Convert docs
2021-03-11 16:37:36 +00:00
Matthias Clasen
3eeaef0834
widgetpaintable: Convert docs
2021-03-11 16:37:36 +00:00
Matthias Clasen
4921497904
singleselection: Convert docs
2021-03-11 16:37:36 +00:00
Matthias Clasen
71ce79bfb8
slicelistmodel: Convert docs
2021-03-11 16:37:36 +00:00
Matthias Clasen
c76bd17ddd
gesturesingle: Convert docs
2021-03-11 16:37:36 +00:00
Matthias Clasen
ecd8d7596b
maplistmodel: Convert docs
2021-03-11 16:37:36 +00:00
Matthias Clasen
97fd0fe889
scrollable: Tweak docs
2021-03-11 16:37:36 +00:00
Matthias Clasen
96fe1218f2
overlaylayout: Add docs for GtkOverlayLayoutChild
2021-03-11 16:37:36 +00:00
Matthias Clasen
14c45be89c
gesturerotate: Convert docs
2021-03-11 16:37:36 +00:00
Matthias Clasen
d5d0cf61b9
padcontroller: Convert docs
2021-03-11 16:37:36 +00:00
Matthias Clasen
7606329617
gesturezoom: Convert docs
2021-03-11 16:37:36 +00:00
Matthias Clasen
7a1da45fff
mediafile: Convert docs
2021-03-11 16:37:36 +00:00
Matthias Clasen
4905f5e722
mediastream: Convert docs
2021-03-11 16:37:36 +00:00
Matthias Clasen
ca3363466f
gesturepan: Convert docs
2021-03-11 16:37:36 +00:00
Matthias Clasen
207c4cd9e1
propertylookuplistmodel: Remove SECTION
...
This is private, no need.
2021-03-11 16:37:36 +00:00
Matthias Clasen
6221d1b407
version: Tweak docs
2021-03-11 16:37:36 +00:00
Matthias Clasen
f6ff03bf09
viewport: Tweak docs
2021-03-11 16:37:36 +00:00
Matthias Clasen
ae315c1106
stringlist: Add docs to GtkStringObject
2021-03-11 16:37:36 +00:00
Matthias Clasen
8164cbbc5f
listbase: Tweak docs
2021-03-11 16:37:36 +00:00
Matthias Clasen
2d76ce829c
gesturelongpress: Convert docs
2021-03-11 16:37:36 +00:00
Matthias Clasen
e604c3b77c
gesturedrag: Convert docs
2021-03-11 16:37:36 +00:00
Matthias Clasen
d4f2121bc2
infobar: Tweak docs
2021-03-11 16:37:36 +00:00
Matthias Clasen
f328e5ecc1
gestureclick: Convert docs
2021-03-11 16:37:36 +00:00
Matthias Clasen
19df22f784
icontheme: Convert docs
2021-03-11 16:37:36 +00:00
Matthias Clasen
3556b605c9
gesture: Convert docs
2021-03-11 16:37:36 +00:00
Matthias Clasen
c26ac6b695
flowbox: Convert docs
2021-03-11 16:37:36 +00:00
Matthias Clasen
9f08c50791
flattenlistmodel: Convert docs
2021-03-11 16:37:36 +00:00
Matthias Clasen
95b2107728
filefilter: Convert docs
2021-03-11 16:37:36 +00:00
Matthias Clasen
2915c72a26
eventcontrollerscroll: Convert docs
2021-03-11 16:37:36 +00:00
Matthias Clasen
207a45b7e0
eventcontrollermotion: Convert docs
2021-03-11 16:37:36 +00:00
Matthias Clasen
32b3386d23
eventcontrollerlegacy: Convert docs
2021-03-11 16:37:36 +00:00
Matthias Clasen
094d5d5260
eventcontrollerkey: Convert docs
2021-03-11 16:37:36 +00:00
Matthias Clasen
8b26894759
eventcontrollerfocus: Convert docs
2021-03-11 16:37:36 +00:00
Matthias Clasen
f4ad0f32f8
expander: Tweak docs
2021-03-11 16:37:36 +00:00
Matthias Clasen
ca74f46b3e
spinner: Tweak docs
2021-03-11 16:37:36 +00:00
Matthias Clasen
d7e0af62e3
eventcontroller: Convert docs
2021-03-11 16:37:36 +00:00
Matthias Clasen
21f2a824ad
entrycompletion: Convert docs
2021-03-11 16:37:36 +00:00
Matthias Clasen
6bd46779fc
editable: Tweak docs
2021-03-11 16:37:36 +00:00
Matthias Clasen
b3f6e95d62
droptargetasync: Convert docs
2021-03-11 16:37:36 +00:00
Matthias Clasen
39dac1ff22
droptarget: Convert docs
2021-03-11 16:37:36 +00:00
Matthias Clasen
30236be2fd
dragsource: Tweak docs
2021-03-11 16:37:36 +00:00
Matthias Clasen
a9d4b6a61c
dragicon: Tweak docs
2021-03-11 16:37:36 +00:00
Matthias Clasen
c1e10473fb
builder: Tweak docs
2021-03-11 16:37:36 +00:00
Matthias Clasen
e8bba52190
border: Tweak docs
2021-03-11 16:37:36 +00:00
Matthias Clasen
1a504feab9
accessible: Tweak docs
2021-03-11 16:37:36 +00:00
Matthias Clasen
406e4a6928
csssection: Tweak docs
2021-03-11 16:37:36 +00:00
Matthias Clasen
f89e1bce90
csslocation: Tweak docs
2021-03-11 16:37:36 +00:00
Matthias Clasen
d1b472c1c8
windowcontrols: Tweak docs
2021-03-11 16:37:36 +00:00
Matthias Clasen
cabe2f5f20
treelistrowsorter: Convert docs
2021-03-11 16:37:36 +00:00
Matthias Clasen
970ae74cd5
texttag: Convert docs
2021-03-11 16:37:36 +00:00
Matthias Clasen
50139ad184
textview: Convert docs
2021-03-11 16:37:36 +00:00
Matthias Clasen
d74666de58
texttagtable: Convert docs
2021-03-11 16:37:36 +00:00
Matthias Clasen
e0df1b3fd9
textmark: Convert docs
2021-03-11 16:37:36 +00:00
Matthias Clasen
bf978ba5a6
textiter: Convert docs
2021-03-11 16:37:36 +00:00
Matthias Clasen
05b13dca55
textchild: Convert docs
2021-03-11 16:37:36 +00:00
Matthias Clasen
720f6e7a17
textbuffer: Convert docs
2021-03-11 16:37:36 +00:00
Matthias Clasen
71649fce29
text: Convert docs
2021-03-11 16:37:36 +00:00
Matthias Clasen
42aa2edf19
styleprovider: Convert docs
2021-03-11 16:37:35 +00:00
Matthias Clasen
b66c74767f
stylecontext: Convert docs
2021-03-11 16:37:35 +00:00
Matthias Clasen
39394da850
stringsorter: Convert docs
2021-03-11 16:37:35 +00:00
Matthias Clasen
da9a320a40
sortlistmodel: Convert docs
2021-03-11 16:37:35 +00:00
Matthias Clasen
5bdcd66117
sorter: Convert docs
2021-03-11 16:37:35 +00:00
Matthias Clasen
930912fd0d
revealer: Convert docs
2021-03-11 16:37:35 +00:00
Matthias Clasen
5ebd0edf72
numericsorter: Convert docs
2021-03-11 16:37:35 +00:00
Matthias Clasen
dda6458142
multisorter: Tweak docs
2021-03-11 16:37:35 +00:00
Matthias Clasen
5568025f1d
listview: Convert docs
2021-03-11 16:37:35 +00:00
Matthias Clasen
5189d3b485
listitem: Convert docs
2021-03-11 16:37:35 +00:00
Matthias Clasen
901f60bc54
gridview: Convert docs
2021-03-11 16:37:35 +00:00
Matthias Clasen
9f90100019
fixedlayout: Convert docs
2021-03-11 16:37:35 +00:00
Matthias Clasen
8db6d6750c
fixed: Convert docs
2021-03-11 16:37:35 +00:00
Matthias Clasen
36f6a76272
filterlistmodel: Convert docs
2021-03-11 16:37:35 +00:00
Matthias Clasen
8696b78e59
expression: Tweak docs
2021-03-11 16:37:35 +00:00
Matthias Clasen
493d773c18
enums: Tweak docs
2021-03-11 16:37:35 +00:00
Matthias Clasen
9247460c2f
entrybuffer: Convert docs
2021-03-11 16:37:35 +00:00
Matthias Clasen
ebadece27b
dropcontrollermotion: Convert docs
2021-03-11 16:37:35 +00:00
Matthias Clasen
f4b498031a
dragsource: Convert docs
2021-03-11 16:37:35 +00:00
Matthias Clasen
eb77ff9696
dragicon: Convert docs
2021-03-11 16:37:35 +00:00
Matthias Clasen
c11ec03642
directorylist: Convert docs
2021-03-11 16:37:35 +00:00
Matthias Clasen
7744be938f
customsorter: Convert docs
2021-03-11 16:37:35 +00:00
Matthias Clasen
646a6726a8
customlayout: Convert docs
2021-03-11 16:37:35 +00:00
Matthias Clasen
460955d578
cssprovider: Convert docs
2021-03-11 16:37:35 +00:00
Matthias Clasen
2e1114c9fa
customfilter: Convert docs
2021-03-11 16:37:35 +00:00
Matthias Clasen
a814c3b3c4
constraintlayout: Convert docs
2021-03-11 16:37:35 +00:00
Matthias Clasen
5e41ea1d2f
constraintguide: Convert docs
2021-03-11 16:37:35 +00:00
Matthias Clasen
350a775963
Constraint: Tweak docs
2021-03-11 16:37:35 +00:00
Matthias Clasen
c0da6b935d
columnviewcolumn: Convert docs
2021-03-11 16:37:35 +00:00
Matthias Clasen
a9162d2218
columnview: Convert docs
2021-03-11 16:37:35 +00:00
Matthias Clasen
102884faf1
docs: Remove anchors from list overview
...
Our markdown doesn't support this.
2021-03-11 16:37:35 +00:00
Matthias Clasen
497a399372
windowcontrols: Use markdown for css tree
2021-03-11 16:37:35 +00:00
Matthias Clasen
292643890b
window: Use markdown for css tree
2021-03-11 16:37:35 +00:00
Matthias Clasen
c46480fe7e
textview: Use markdown for css tree
2021-03-11 16:37:35 +00:00
Matthias Clasen
29f2e5f84e
switch: Use markdown for css tree
2021-03-11 16:37:35 +00:00
Matthias Clasen
9ab40d2899
stringlist: Convert docs
2021-03-11 16:37:35 +00:00
Matthias Clasen
cc03ca9df1
spinbutton: Use markdown for css tree
2021-03-11 16:37:35 +00:00
Matthias Clasen
bcb0b36238
searchentry: Use markdown for css tree
2021-03-11 16:37:35 +00:00
Matthias Clasen
7e7c81c5d2
searchbar: Use markdown for css tree
2021-03-11 16:37:35 +00:00
Matthias Clasen
d7ce5c55c8
scrollbar: Use markdown for css tree
2021-03-11 16:37:35 +00:00
Matthias Clasen
59c0bee4b8
scalebutton: Convert docs
2021-03-11 16:37:35 +00:00
Matthias Clasen
33f611a596
scale: Use markdown for css tree
2021-03-11 16:37:35 +00:00
Matthias Clasen
495c3d9c44
progressbar: Use markdown for css tree
2021-03-11 16:37:35 +00:00
Matthias Clasen
b4ad1fa44f
popovermenubar: Use markdown for css tree
2021-03-11 16:37:35 +00:00
Matthias Clasen
b093900e48
popover: Use markdown for css tree
2021-03-11 16:37:35 +00:00
Matthias Clasen
27b338a90b
passwordentry: Use markdown for css tree
2021-03-11 16:37:35 +00:00
Matthias Clasen
ca51d6dfd9
paned: Use markdown for css tree
2021-03-11 16:37:35 +00:00
Matthias Clasen
47c1b50eba
cursor: Use a table for cursor names
...
This gets all the names into view at the same time.
2021-03-11 16:37:35 +00:00
Matthias Clasen
5d68a23b55
menubutton: Put images in a table
2021-03-11 16:37:35 +00:00
Matthias Clasen
9f6e4e60d0
label: Use markdown for css tree
2021-03-11 16:37:35 +00:00
Matthias Clasen
7a60c66940
headerbar: Use markdown for css tree
2021-03-11 16:37:35 +00:00
Matthias Clasen
31245353d5
frame: Use markdown for css tree
2021-03-11 16:37:35 +00:00
Matthias Clasen
c91e141a6c
fontbutton: Use markdown for css tree
2021-03-11 16:37:35 +00:00
Matthias Clasen
87c0363cd5
expander: Use markdown for css tree
2021-03-11 16:37:35 +00:00
Matthias Clasen
71bad39f5a
entry: Use markdown for css tree
2021-03-11 16:37:35 +00:00
Matthias Clasen
40574f9ca3
emojichooser: Use markdown for css tree
2021-03-11 16:37:35 +00:00
Matthias Clasen
752477b1ae
editablelabel: Use markdown for css tree
2021-03-11 16:37:35 +00:00
Matthias Clasen
ad9849bf26
dropdown: Small doc tweak
2021-03-11 16:37:35 +00:00
Matthias Clasen
9bfe163cf1
comboboxtext: Use markdown for css tree
2021-03-11 16:37:34 +00:00
Matthias Clasen
22f072faea
combobox: Use markdown for css tree
2021-03-11 16:37:34 +00:00
Matthias Clasen
57c7d77cdf
colorbutton: Use markdown for css tree
2021-03-11 16:37:34 +00:00
Matthias Clasen
7ac7bb9543
checkbutton: Use markdown for css tree
2021-03-11 16:37:34 +00:00
Matthias Clasen
c82b5b8d8a
centerbox: Small docs tweak
2021-03-11 16:37:34 +00:00
Matthias Clasen
15aa7de547
calendar: Use markdown for css tree
2021-03-11 16:37:34 +00:00
Matthias Clasen
ee62d19115
button: Small docs tweak
2021-03-11 16:37:34 +00:00
Matthias Clasen
cdcabb7fb7
atcontext: Convert docs
2021-03-11 16:37:34 +00:00
Matthias Clasen
494bdad887
contentprovider: Convert some more markup
2021-03-11 16:37:34 +00:00
Matthias Clasen
ef09696ee5
stringfilter: Convert docs
2021-03-11 16:37:34 +00:00
Matthias Clasen
8da60587e1
stackswitcher: Convert docs
2021-03-11 16:37:34 +00:00
Matthias Clasen
3a7e9a28d3
stacksidebar: Convert docs
2021-03-11 16:37:34 +00:00
Matthias Clasen
3535b582a1
stack: Convert docs
2021-03-11 16:37:34 +00:00
Matthias Clasen
07573ef2a6
overlaylayout: Convert docs
2021-03-11 16:37:34 +00:00
Matthias Clasen
92838f9972
printdialog: Add an example image
2021-03-11 16:37:34 +00:00
Matthias Clasen
ca5f66b368
multifilter: Docs tweaks.
2021-03-11 16:37:34 +00:00
Matthias Clasen
af6af482c4
pagesetupdialog: Add an example image
2021-03-11 16:37:34 +00:00
Matthias Clasen
c65239155f
notebook: Convert docs
2021-03-11 16:37:34 +00:00
Matthias Clasen
12f0d963d9
levelbar: Docs tweaks
2021-03-11 16:37:34 +00:00
Matthias Clasen
6ab8ca4669
headerbar: Add example image
2021-03-11 16:37:34 +00:00
Matthias Clasen
d65a98f828
gridlayout: Convert docs
2021-03-11 16:37:34 +00:00
Matthias Clasen
79417d8d40
centerlayout: Convert docs
2021-03-11 16:37:34 +00:00
Matthias Clasen
8bdb2ea667
overlay: Convert docs
2021-03-11 16:37:34 +00:00
Matthias Clasen
8e887fbbf4
listitemfactory: Convert docs
2021-03-11 16:37:34 +00:00
Matthias Clasen
dc42dcf962
signallistitemfactory: Convert docs
2021-03-11 16:37:34 +00:00
Matthias Clasen
68cd66b210
builderlistitemfactory: Convert docs
2021-03-11 16:37:34 +00:00
Matthias Clasen
39a9bea066
builderscope: Convert docs
2021-03-11 16:37:34 +00:00
Matthias Clasen
0776f645fd
builder: Convert docs
2021-03-11 16:37:34 +00:00
Matthias Clasen
b408dc0706
boxlayout: Convert docs
2021-03-11 16:37:34 +00:00
Matthias Clasen
626ee40970
boolfilter: Convert docs
2021-03-11 16:37:34 +00:00
Matthias Clasen
f86c8f2077
bookmarklist: Convert docs
2021-03-11 16:37:34 +00:00
Matthias Clasen
1a501e3d53
binlayout: Convert docs
2021-03-11 16:37:34 +00:00
Matthias Clasen
c611fcc709
assistant: Small doc tweak
2021-03-11 16:37:34 +00:00
Matthias Clasen
de1101df19
aspectframe: Convert docs
2021-03-11 16:37:34 +00:00
Matthias Clasen
aca07954af
applicationwindow: Convert docs
2021-03-11 16:37:34 +00:00
Matthias Clasen
06a51c045c
application: Tweak docs
2021-03-11 16:37:34 +00:00
Matthias Clasen
7f7231038d
adjustment: Small docs tweak
2021-03-11 16:37:34 +00:00
Matthias Clasen
fd6faabe16
actionable: Convert docs
2021-03-11 16:37:34 +00:00
Matthias Clasen
26ca77d01b
aboutdialog: Small docs tweak
2021-03-11 16:37:34 +00:00
Matthias Clasen
b983133675
Include low-level printing in the gir
...
We add the sources, but not the headers. Oops.
2021-03-11 16:37:34 +00:00
Matthias Clasen
02fc352bfb
windowhandle: Convert docs
2021-03-11 16:37:34 +00:00
Matthias Clasen
180de1041b
shortcutmanager: Convert docs
2021-03-11 16:37:34 +00:00
Matthias Clasen
ded9903a83
root: Convert docs
2021-03-11 16:37:34 +00:00
Matthias Clasen
921e8e02f4
printoperationpreview: Convert docs
2021-03-11 16:37:34 +00:00
Matthias Clasen
9d536b9aef
printunixdialog: Convert docs
2021-03-11 16:37:34 +00:00
Matthias Clasen
d11b263ac2
printsettings: Convert docs
2021-03-11 16:37:34 +00:00
Matthias Clasen
a710e64bad
printeroperation: Convert docs
2021-03-11 16:37:34 +00:00
Matthias Clasen
b257a58417
printjob: Convert docs
2021-03-11 16:37:34 +00:00
Matthias Clasen
eca14b763c
printer: Convert docs
2021-03-11 16:37:34 +00:00
Matthias Clasen
5225a0f253
printcontext: Convert docs
2021-03-11 16:37:34 +00:00
Matthias Clasen
60b3effce3
pagesetupdialog: Convert docs
2021-03-11 16:37:34 +00:00
Matthias Clasen
b3e7e31bb0
pagesetup: Convert docs
2021-03-11 16:37:34 +00:00
Matthias Clasen
3ab954882d
layoutmanager: Convert docs
2021-03-11 16:37:34 +00:00
Matthias Clasen
7dd436ab17
filter: Add sections for AnyFilter and EveryFilter
2021-03-11 16:37:34 +00:00
Matthias Clasen
085b0b7c08
adjustment: Convert docs
2021-03-11 16:37:34 +00:00
Matthias Clasen
76fa6dcef6
shortcutmanager: Convert docs
2021-03-11 16:37:34 +00:00
Matthias Clasen
dde3de34c9
popovermenubar: Convert docs
2021-03-11 16:37:34 +00:00
Matthias Clasen
e88f0d4b77
popovermenu: Convert docs
2021-03-11 16:37:34 +00:00
Matthias Clasen
172ab2f20a
native: Convert docs
2021-03-11 16:37:34 +00:00
Matthias Clasen
0ca97cd218
emojichooser: Convert docs
2021-03-11 16:37:34 +00:00
Matthias Clasen
645c951fb6
mediacontrols: Convert docs
2021-03-11 16:37:34 +00:00
Matthias Clasen
4bed24a816
windowcontrols: Convert docs
2021-03-11 16:37:34 +00:00
Matthias Clasen
9104420c87
shortcutswindow: Convert docs
2021-03-11 16:37:33 +00:00
Matthias Clasen
0d238f4c99
range: Convert docs
2021-03-11 16:37:33 +00:00
Matthias Clasen
9b9c9ae8d4
popover: Convert docs
2021-03-11 16:37:33 +00:00
Matthias Clasen
1f06cfd5d8
headerbar: Convert docs
2021-03-11 16:37:33 +00:00
Matthias Clasen
ddcb76ac2d
appchooserwidget: Convert docs
2021-03-11 16:37:33 +00:00
Matthias Clasen
e21156b30b
appchooserdialog: Convert docs
2021-03-11 16:37:33 +00:00
Matthias Clasen
166edeed91
appchooser: Convert docs
2021-03-11 16:37:33 +00:00
Matthias Clasen
465aca029e
Add some more widgets to the gallery
...
We already have images for menus, menubars and emoji chooser.
Use them.
2021-03-11 16:37:33 +00:00
Matthias Clasen
86604d8e01
nativedialog: Convert docs
2021-03-11 16:37:33 +00:00
Matthias Clasen
bb393f6496
fontchooserwidget: Convert docs
2021-03-11 16:37:33 +00:00
Matthias Clasen
7a099604c9
fontchooserdialog: Convert docs
2021-03-11 16:37:33 +00:00
Matthias Clasen
92009413f2
fontchooser: Convert docs
2021-03-11 16:37:33 +00:00
Matthias Clasen
7763fc55bb
filechoosernative: Convert docs
2021-03-11 16:37:33 +00:00
Matthias Clasen
042af94048
filechooserdialog: Convert docs
2021-03-11 16:37:33 +00:00
Matthias Clasen
d91fb26409
filechooser: Convert docs
2021-03-11 16:37:33 +00:00
Matthias Clasen
3124a784fe
searchbar: Convert docs
2021-03-11 16:37:33 +00:00
Matthias Clasen
936a2c2c59
colorchooserdialog: Fixup
2021-03-11 16:37:33 +00:00
Matthias Clasen
53d3b46d4a
actionbar: Convert docs
2021-03-11 16:37:33 +00:00
Matthias Clasen
fc55478890
paned: Convert docs
...
Convert links, add example image, clean things up.
2021-03-11 16:37:33 +00:00
Matthias Clasen
d41c3e3c2d
colorchooser: Convert docs
...
Convert link syntax.
2021-03-11 16:37:33 +00:00
Matthias Clasen
886ba1680d
colorchooserwidget: Convert docs
...
Convert links, and clean things up.
2021-03-11 16:37:33 +00:00
Matthias Clasen
11c5523142
colorchooserdialog: Convert docs
...
Convert link syntax, add example image, clean things up.
2021-03-11 16:37:33 +00:00
Matthias Clasen
c0be9c5b97
colorbutton: Small doc tweaks
2021-03-11 16:37:33 +00:00
Matthias Clasen
ad2dad6612
assistant: Convert docs
...
Convert link syntax, an example image, clean things up.
2021-03-11 16:37:33 +00:00
Matthias Clasen
5950bcd754
frame: Convert docs
...
Convert link syntax, add an example image, add property
annotations.
2021-03-11 16:37:33 +00:00
Matthias Clasen
067b43fb5b
aboutdialog: Add property annotations
...
Connect properties, getters, and setters with annotations
2021-03-11 16:37:33 +00:00
Matthias Clasen
b39160243f
aboutdialog: Improve example image
...
Use our logo, and update the copyright years.
2021-03-11 16:37:33 +00:00
Matthias Clasen
b460ffd120
dialog: Convert docs
...
Convert links, add an example image, generally clean up docs.
2021-03-11 16:37:33 +00:00
Matthias Clasen
a61c677a0d
docs: Add dialogs to the gallery
2021-03-11 16:37:33 +00:00
Matthias Clasen
7afc1291a8
window: Convert docs
...
Convert link format, add an example image, add
property annotations. General cleanup.
2021-03-11 16:37:33 +00:00
Matthias Clasen
cc2d9f0cb5
scrollable: Convert docs
...
Convert link format, add property annotations. General cleanup.
2021-03-11 16:37:33 +00:00
Matthias Clasen
73b66428a7
viewport: Convert docs
...
Convert link format, add property annotations. General cleanup.
2021-03-11 16:37:33 +00:00
Matthias Clasen
3a62b28344
scrolledwindow: Convert docs
...
Convert link format, add property annotations. General cleanup.
2021-03-11 16:37:33 +00:00
Matthias Clasen
f3b16d0e9d
messagedialog: Convert docs
...
Convert link format, add an example image, add
property annotations. General cleanup.
2021-03-11 16:37:33 +00:00
Matthias Clasen
e999773566
grid: Convert docs
...
Convert link format, add an example image, add
property annotations. General cleanup.
2021-03-11 16:37:33 +00:00
Matthias Clasen
6aaa98f669
expander: Convert docs
...
Convert link format, add an example image, add
property annotations. General cleanup.
2021-03-11 16:37:33 +00:00
Matthias Clasen
f800178e7f
centerbox: Convert docs
...
Convert link format, add an example image, add
property annotations. General cleanup.
2021-03-11 16:37:33 +00:00
Matthias Clasen
07a2b60f45
box: Convert docs
...
Convert link format, add an example image, add
property annotations. General cleanup.
2021-03-11 16:37:33 +00:00
Matthias Clasen
f5fe5c1fa6
appchooserbutton: Add property annotations
...
Connect properties, getters, and setters with annotations
2021-03-11 16:37:33 +00:00
Matthias Clasen
e353cf38ec
colorbutton: Add property annotations
...
Connect properties, getters, and setters with annotations
2021-03-11 16:37:33 +00:00
Matthias Clasen
947ebee7d4
dropdown: Add property annotations
...
Connect properties, getters, and setters with annotations
2021-03-11 16:37:33 +00:00
Matthias Clasen
d4eb11142a
fontbutton: Add property annotations
...
Connect properties, getters, and setters with annotations
2021-03-11 16:37:33 +00:00
Matthias Clasen
e4054d62fe
switch: Add property annotations
...
Connect properties, getters, and setters with annotations
2021-03-11 16:37:33 +00:00
Matthias Clasen
37855e2b53
spinbutton: Add property annotations
...
Connect properties, getters, and setters with annotations
2021-03-11 16:37:33 +00:00
Matthias Clasen
08371b25dc
menubutton: Add property annotations
...
Connect properties, getters, and setters with annotations
2021-03-11 16:37:33 +00:00
Matthias Clasen
26100ad5d1
lockbutton: Add property annotations
...
Connect properties, getters, and setters with annotations
2021-03-11 16:37:33 +00:00
Matthias Clasen
69427e98d5
editablelabel: Add property annotations
...
Connect properties, getters, and setters with annotations
2021-03-11 16:37:33 +00:00
Matthias Clasen
d3e8607f58
combobox: Add property annotations
...
Connect properties, getters, and setters with annotations
2021-03-11 16:37:33 +00:00
Matthias Clasen
cf6f57b41c
passwordentry: Add property annotations
...
Connect properties, getters, and setters with annotations
2021-03-11 16:37:33 +00:00
Matthias Clasen
d5a024c7f8
linkbutton: Add property annotations
...
Connect properties, getters, and setters with annotations
2021-03-11 16:37:33 +00:00
Matthias Clasen
67fdc0491a
checkbutton: Add property annotations
...
Connect properties, getters, and setters with annotations
2021-03-11 16:37:33 +00:00
Matthias Clasen
5d69584a53
togglebutton: Add property annotations
...
Connect properties, getters, and setters with annotations
2021-03-11 16:37:33 +00:00
Matthias Clasen
ef5b781e0c
entry: Minor docs fixes
2021-03-11 16:37:33 +00:00
Matthias Clasen
72505acb9e
searchentry: Minor docs tweaks
2021-03-11 16:37:33 +00:00
Matthias Clasen
d7b55cfd0c
editable: Convert docs
2021-03-11 16:37:33 +00:00
Matthias Clasen
7803a09f31
entry: Add property annotations
...
Connect properties, getters, and setters with annotations
2021-03-11 16:37:33 +00:00
Emmanuele Bassi
4f36509e5f
Mark padding fields as private
...
And mention that they should be removed in the next version of GTK.
Padding fields in interfaces are unnecessary, as they don't contribute
to the ABI.
2021-03-11 16:37:33 +00:00
Emmanuele Bassi
198c0be5e7
flowbow: Mark private fields as private
2021-03-11 16:37:33 +00:00
Matthias Clasen
c0bd352c88
scale: Add property annotations
...
Connect properties, getters, and setters with annotations
2021-03-11 16:37:33 +00:00
Matthias Clasen
3a62913a97
entry: Add property annotations
...
Connect properties, getters, and setters with annotations
2021-03-11 16:37:33 +00:00
Matthias Clasen
abb951daf1
button: Add property annotations
...
Connect properties, getters, and setters with annotations
2021-03-11 16:37:32 +00:00
Matthias Clasen
4131cb4c7b
bitset: Convert docs
2021-03-11 16:37:32 +00:00
Matthias Clasen
7450427757
gsktransform: Convert docs
2021-03-11 16:37:32 +00:00
Matthias Clasen
b836707979
gskroundedrect: Convert docs
2021-03-11 16:37:32 +00:00
Matthias Clasen
70f805cdfe
rendernode: Add property annotations
...
Connect properties, getters, and setters with annotations
2021-03-11 16:37:32 +00:00
Matthias Clasen
458bc5500c
gskrenderer: Add property annotations
...
Connect properties, getters, and setters with annotations
2021-03-11 16:37:32 +00:00
Matthias Clasen
22b375534e
glshader: Add property annotations
...
Connect properties, getters, and setters with annotations
2021-03-11 16:37:32 +00:00
Emmanuele Bassi
e60afc6011
docs: Remove stray backtick
2021-03-11 16:37:32 +00:00
Matthias Clasen
30073de932
widget: Add property annotations
...
Connect properties, getters, and setters with annotations.
2021-03-11 16:37:32 +00:00
Matthias Clasen
b674bba155
video: Add property annotations
...
Connect properties, getters, and setters with annotations.
2021-03-11 16:37:32 +00:00
Matthias Clasen
50df5e0ec2
textview: Add property annotations
...
Connect properties, getters, and setters with annotations.
2021-03-11 16:37:32 +00:00
Matthias Clasen
693f3d6b41
separator: Add property annotations
...
Connect properties, getters, and setters with annotations.t
2021-03-11 16:37:32 +00:00
Matthias Clasen
e78302c4e5
scrollbar: Add property annotations
...
Connect properties, getters, and setters with annotations.
2021-03-11 16:37:32 +00:00
Matthias Clasen
0559e9e763
scale: Add property annotations
...
Connect properties, getters, and setters with annotations.
2021-03-11 16:37:32 +00:00
Matthias Clasen
8eacbc3a20
picture: Add property annotations
...
Connect properties, getters, and setters with annotations.
2021-03-11 16:37:32 +00:00
Matthias Clasen
3fd3187d8f
orientable: Add property annotations
...
Connect properties, getters, and setters with annotations.
2021-03-11 16:37:32 +00:00
Matthias Clasen
723d979be2
infobar: Add property annotations
...
Connect properties, getters, and setters with annotations.
2021-03-11 16:37:32 +00:00
Matthias Clasen
0c56522de1
image: Add property annotations
...
Connect properties, getters, and setters with annotations.
2021-03-11 16:37:32 +00:00
Matthias Clasen
8db308be4d
glarea: Add property annotations
...
Connect properties, getters, and setters with annotations.
2021-03-11 16:37:32 +00:00
Matthias Clasen
30d32a1f9d
drawingarea: Add property annotations
...
Connect properties, getters, and setters with annotations.
2021-03-11 16:37:32 +00:00
Matthias Clasen
08509acc04
claendar: Add property annotations
...
Connect properties, getters, and setters with annotations.
2021-03-11 16:37:32 +00:00
Matthias Clasen
6ff78c99fa
accessible: Annotate properties
2021-03-11 16:37:32 +00:00
Matthias Clasen
34443546a8
visual index: Reorder some widgets
...
This improves the alignment a bit.
2021-03-11 16:37:32 +00:00
Matthias Clasen
d5e9e10d0a
toplevel: Add property annotations
...
Connect properties, getters, and setters with annotations.
2021-03-11 16:37:32 +00:00
Matthias Clasen
d262f740b2
texture: Add property annotations
...
Connect properties, getters, and setters with annotations.
2021-03-11 16:37:32 +00:00
Matthias Clasen
d886ab9229
surface: Add property annotations
...
Connect properties, getters, and setters with annotations.
2021-03-11 16:37:32 +00:00
Matthias Clasen
6be66205cc
seat: Add property annotations
...
Connect properties, getters, and setters with annotations.
2021-03-11 16:37:32 +00:00
Matthias Clasen
abb6fe326f
popup: Add property annotations
...
Connect properties, getters, and setters with annotations.
2021-03-11 16:37:32 +00:00
Matthias Clasen
d6c763f2ae
monitor: Add property annotations
...
Connect properties, getters, and setters with annotations.
2021-03-11 16:37:32 +00:00
Matthias Clasen
34533b544a
glcontext: Add property annotations
...
Connect properties, getters, and setters with annotations.
2021-03-11 16:37:32 +00:00
Matthias Clasen
d92647a92b
drop: Add property annotations
...
Connect properties, getters, and setters with annotations.
2021-03-11 16:37:32 +00:00
Matthias Clasen
553a959102
drawcontext: Add property annotations
...
Connect properties, getters, and setters with annotations.
2021-03-11 16:37:32 +00:00
Matthias Clasen
9a33a1852a
drag: Add property annotations
...
Connect properties, getters, and setters with annotations.
2021-03-11 16:37:32 +00:00
Matthias Clasen
ce83a0e5bb
displaymanager: Add property annotations
...
Connect properties, getters, and setters with annotations.
2021-03-11 16:37:32 +00:00
Matthias Clasen
d724ea294d
display: Add property annotations
...
Connect properties, getters, and setters with annotations.
2021-03-11 16:37:32 +00:00
Matthias Clasen
038006d582
devicetool: Add property annotations
...
Connect properties, getters, and setters with annotations.
2021-03-11 16:37:32 +00:00
Matthias Clasen
4a4301be38
device: Add property annotations
...
Connect properties, getters, and setters with annotations.
2021-03-11 16:37:32 +00:00
Matthias Clasen
50fe533246
cursor: Add property annotations
...
Connect properties, getters, and setters with annotations.
2021-03-11 16:37:32 +00:00
Matthias Clasen
11022fc485
contentprovider: Add property annotations
...
Connect properties, getters, and setters with annotations.
2021-03-11 16:37:32 +00:00
Matthias Clasen
c51585bab1
clipboard: Add property annotations
...
Connect properties, getters, and setters with annotations.
2021-03-11 16:37:32 +00:00
Matthias Clasen
701ebd55c7
applaunchcontext: Add property annotations
...
Connect properties and getters with annotations.
2021-03-11 16:37:32 +00:00
Matthias Clasen
4c50c312c1
statusbar: Remove SECTION
2021-03-11 16:37:32 +00:00
Matthias Clasen
55f1ed171a
infobar: Add property annotations
...
Connect properties, getters, and setters with annotations.
2021-03-11 16:37:32 +00:00
Matthias Clasen
97c4e46e39
progressbar: Add property annotations
...
Connect properties, getters, and setters with annotations.
2021-03-11 16:37:32 +00:00
Matthias Clasen
3ed2e94f29
levelbar: Add property annotations
...
Connect properties, getters, and setters with annotations.
2021-03-11 16:37:32 +00:00
Matthias Clasen
e98ea46d87
spinner: Add property annotations
...
Connect properties, getters, and setters with annotations.
2021-03-11 16:37:32 +00:00
Matthias Clasen
a8a15d48ad
label: Add property annotations
...
Connect properties, getters, and setters with annotations.
2021-03-11 16:37:32 +00:00
Emmanuele Bassi
6bc69a12cc
docs: Update the documentation style guide
2021-03-11 16:37:32 +00:00
Emmanuele Bassi
c6b23f8f89
constraint: Port to the new docs format
...
- Drop the "SECTION".
- Add attributes annotations for properties and getter methods.
- Remove excessive linking and redundant types
2021-03-11 16:37:32 +00:00
Emmanuele Bassi
be93dd98f7
Hide GtkSettingsValue
...
This is a private type that has no public API, and no business being in
a public header.
2021-03-11 16:37:32 +00:00
Emmanuele Bassi
a8f36b8381
Hide GtkTextBTree's typedef
...
It's a private type, and has no business in a public header.
2021-03-11 16:37:32 +00:00
Emmanuele Bassi
1fb5824e1e
treemodel: Update the description format
...
Also add a description for GtkTreePath.
2021-03-11 16:37:32 +00:00
Emmanuele Bassi
35e438a62e
treeview: Update the description format
2021-03-11 16:37:32 +00:00
Emmanuele Bassi
cf707cbfaa
expression: Update docs format
...
And add documentation stanzas for GtkExpression sub-types.
2021-03-11 16:37:32 +00:00
Emmanuele Bassi
1eb9d699b5
Box GtkExpressionWatch
...
Otherwise bindings won't know how to deal with memory management.
2021-03-11 16:37:32 +00:00
Emmanuele Bassi
da94b461e0
csssection: Update docs syntax
2021-03-11 16:37:32 +00:00
Emmanuele Bassi
ec32ff04b8
application: Convert docs
...
Drop mentions of command line arguments parsed by gtk_init(), and of the
GDK lock.
2021-03-11 16:37:32 +00:00
Emmanuele Bassi
8d12dce174
docs: Fix property annotation
2021-03-11 16:37:32 +00:00
Matthias Clasen
63dc97fb29
spinbutton: Convert docs
...
Change link syntax, add an example image, generally clean things up.
2021-03-11 16:37:31 +00:00
Matthias Clasen
6c315b1b8a
searchentry: Convert docs
...
Change link syntax, add an example image, generally clean things up.
2021-03-11 16:37:31 +00:00
Matthias Clasen
231a19abb9
passwordentry: Convert docs
...
Change link syntax, add an example image, generally clean things up.
2021-03-11 16:37:31 +00:00
Matthias Clasen
99a3dbef00
editablelabel: Convert docs
...
Change link syntax, add an example image, generally clean things up.
2021-03-11 16:37:31 +00:00
Matthias Clasen
9934f9c43b
constrainttarget: Convert docs
2021-03-11 16:37:31 +00:00
Matthias Clasen
c4e43c1cd5
buildable: Convert docs
...
Change link syntax.
2021-03-11 16:37:31 +00:00
Matthias Clasen
3549914d0f
accessible: Convert docs
...
Change link syntax.
2021-03-11 16:37:31 +00:00
Matthias Clasen
e034046724
widget: Convert docs
...
Some work toward converting the docs to markdown.
More work needed, in particular around vfuncs and
class functions.
2021-03-11 16:37:31 +00:00
Matthias Clasen
c975216f47
entry: Convert docs
...
Change link syntax, add an example image, generally clean things up.
2021-03-11 16:37:31 +00:00
Matthias Clasen
18e5192a58
switch: Convert docs
...
Change link syntax, add an example image, generally clean things up.
2021-03-11 16:37:31 +00:00
Matthias Clasen
dc8ee5a992
volumebutton: Convert docs
...
Change link syntax, add an example image, generally clean things up.
2021-03-11 16:37:31 +00:00
Matthias Clasen
e75c3d0380
fontbutton: Convert docs
...
Change link syntax, add an example image, generally clean things up.
2021-03-11 16:37:31 +00:00
Matthias Clasen
47cb0771f5
colorbutton: Convert docs
...
Change link syntax, add an example image, generally clean things up.
2021-03-11 16:37:31 +00:00
Matthias Clasen
6884a1a5c6
dropdown: Convert docs
...
Change link syntax, add an example image, generally clean things up.
2021-03-11 16:37:31 +00:00
Matthias Clasen
d028f7ed9a
appchooserbutton: Convert docs
...
Change link syntax, add an example image, generally clean things up.
2021-03-11 16:37:31 +00:00
Matthias Clasen
fc6f16cb61
lockbutton: Convert docs
...
Change link syntax, add an example image, generally clean things up.
2021-03-11 16:37:31 +00:00
Matthias Clasen
1692b41b30
comboboxtext: Convert docs
...
Change link syntax, add an example image, generally clean things up.
2021-03-11 16:37:31 +00:00
Matthias Clasen
8e6b6ae26e
combobox: Convert docs
...
Change link syntax, add an example image, generally clean things up.
2021-03-11 16:37:31 +00:00
Emmanuele Bassi
9a16b1b971
docs: Remove duplicate documentation stanzas
2021-03-11 16:37:31 +00:00
Emmanuele Bassi
895aa1d3ab
docs: Fix typos
2021-03-11 16:37:31 +00:00
Emmanuele Bassi
da6861188b
docs: Fix value annotation
...
Drop the `:`.
2021-03-11 16:37:31 +00:00
Emmanuele Bassi
1dd240974b
docs: Fix copy-paste error in GdkDevice
2021-03-11 16:37:31 +00:00
Emmanuele Bassi
b6b30c9bcf
docs: Fix the MenuButton direction property links
2021-03-11 16:37:31 +00:00
Matthias Clasen
47b9a554ac
menubutton: Convert docs
...
Change link syntax, add an example image, generally clean things up.
2021-03-11 16:37:31 +00:00
Matthias Clasen
3d8c810ab7
checkbutton: Convert docs
...
Change link syntax, add an example image, generally clean things up.
2021-03-11 16:37:31 +00:00
Matthias Clasen
dfb68fb13d
docs: Split images for check and radio buttons
...
Its the same widget, but two images fit better in the gallery,
and will be easier to use as example images in the docs.
2021-03-11 16:37:31 +00:00
Matthias Clasen
f854136676
linkbutton: Convert docs
...
Change link syntax, add an example image, generally clean things up.
2021-03-11 16:37:31 +00:00
Matthias Clasen
18f525f7b4
docs: Improve the togglebutton image
...
Make it actually show toggles.
2021-03-11 16:37:31 +00:00
Matthias Clasen
4ee4c88e43
wayland: Fix a link
...
gi-docgen currently can't handle links without namespace
in the Wayland docs.
2021-03-11 16:37:31 +00:00
Matthias Clasen
ec78bf3309
togglebutton: Convert docs
...
Change link syntax, add an example image, generally clean things up.
2021-03-11 16:37:31 +00:00
Matthias Clasen
4bf7bfb41a
button: Convert docs
...
Change link syntax, add an example image, generally clean things up.
2021-03-11 16:37:31 +00:00
Emmanuele Bassi
538f935d44
docs: Fix the annotation for GtkTextView:justification
2021-03-11 16:37:31 +00:00
Emmanuele Bassi
952fc31dbc
docs: Fix up the 3-to-4 migration guide
2021-03-11 16:37:31 +00:00
Matthias Clasen
93326164e2
docs: Add backend links to the gdk docs
...
These are placeholders for when we know how to
link across namespaces.
2021-03-11 16:37:31 +00:00
Matthias Clasen
b78895e449
docs: Add separate toml files for gdk backends
...
Reusing the same one duplicates the standalone
docs, which doesn't quite seem right.
2021-03-11 16:37:31 +00:00
Matthias Clasen
205a13eaa0
docs: Brush up the Wayland backend docs
...
Add some content here.
2021-03-11 16:37:31 +00:00
Matthias Clasen
a9dd352986
gdk: Some more tweaks of the docs
2021-03-11 16:37:31 +00:00
Matthias Clasen
e82d090bf5
docs: Add some links to the pango chapter
2021-03-11 16:37:31 +00:00
Matthias Clasen
9132f1831c
docs: Rework the gdk docs
...
Convert links, make things more concise.
2021-03-11 16:37:31 +00:00
Matthias Clasen
3d04c0f4be
docs: Move GdkEvent docs inline
...
This is not really worth a chapter of its own.
2021-03-11 16:37:31 +00:00
Matthias Clasen
ca3120919f
docs: Improve gsk docs
...
Convert link formats, add summaries, and make
a few missing things show up in the docs.
2021-03-11 16:37:31 +00:00
Matthias Clasen
e5bed812f5
docs: Tweak X11 section
...
Remove unsupported heading anchors.
2021-03-11 16:37:31 +00:00
Matthias Clasen
d88a4629f9
docs: Tweaks Windows section
...
Remove unsupported heading anchors.
2021-03-11 16:37:31 +00:00
Matthias Clasen
24c04b5bb9
docs: Tweak Wayland section
...
Remove unsupported heading anchors.
2021-03-11 16:37:31 +00:00
Matthias Clasen
4c3ea25745
docs: Tweak a11y section
...
Convert link syntax.
2021-03-11 16:37:31 +00:00
Matthias Clasen
231814a595
docs: Tweak running chapter
...
Remove unsupported heading anchors, fix definition
list use.
2021-03-11 16:37:31 +00:00
Matthias Clasen
820f37be0b
docs: Tweak input overview
...
Remove unsupported heading anchors.
2021-03-11 16:37:31 +00:00
Matthias Clasen
02ec00dc5a
docs: Tweak drawing model overview
...
Fix link syntax, remove gtk-doc markup.
2021-03-11 16:37:30 +00:00
Matthias Clasen
4d2e4309f0
docs: Tweak css properties section
...
Fix the use of definition lists.
2021-03-11 16:37:30 +00:00
Matthias Clasen
d2ba09ec98
docs: Tweak the actions overview
...
Fix use of definition lists, and remove some gtk-doc
markup.
2021-03-11 16:37:30 +00:00
Matthias Clasen
41ddce152a
building: Minor tweaks
...
Remove unsupported anchors from headings.
2021-03-11 16:37:30 +00:00
Matthias Clasen
df9c469acd
video: Convert docs
...
Change link syntax, add an example image, generally clean things up.
2021-03-11 16:37:30 +00:00
Matthias Clasen
8cf04b3345
glarea: Convert docs
...
Change link syntax, add an example image, generally clean things up.
2021-03-11 16:37:30 +00:00
Matthias Clasen
1072b56970
drawingarea: Convert docs
...
Change link syntax, add an example image, generally clean things up.
2021-03-11 16:37:30 +00:00
Matthias Clasen
f94fc28eb5
textview: Convert docs
...
Change link syntax, add an example image, generally clean things up.
2021-03-11 16:37:30 +00:00
Matthias Clasen
3b42440805
picture: Convert docs
...
Change link syntax, add an example image, generally clean things up.
2021-03-11 16:37:30 +00:00
Matthias Clasen
dcf53bced2
scale: Convert docs
...
Change link syntax, add an example image, generally clean things up.
2021-03-11 16:37:30 +00:00
Matthias Clasen
76e9a7bbb4
image: Convert docs
...
Change link syntax, add an example image, generally clean things up.
2021-03-11 16:37:30 +00:00
Matthias Clasen
12ccc68c99
separator: Convert docs
...
Change link syntax and add an example image.
2021-03-11 16:37:30 +00:00
Matthias Clasen
834295dde0
calendar: Convert docs
...
Change link syntax, add an example image, generally clean things up.
2021-03-11 16:37:30 +00:00
Matthias Clasen
b7f4f5d234
scrollbar: Convert docs
...
Change link syntax, add an example image, generally clean things up.
2021-03-11 16:37:30 +00:00
Matthias Clasen
61d85f32a2
infobar: Convert docs
...
Change link syntax, add an example image, generally clean things up.
2021-03-11 16:37:30 +00:00
Emmanuele Bassi
6d489a9e81
docs: Generate the DevHelp file for our namespaces
2021-03-11 16:37:30 +00:00
Emmanuele Bassi
85774d2bcd
docs: Update the "Getting Started" page
...
Drop the Pandoc stuff, add the gi-docgen links, and remove a stray
docbook element.
2021-03-11 16:37:30 +00:00
Matthias Clasen
03c5b680ec
statusbar: Convert docs
...
Change link syntax, add an example image, generally clean things up.
2021-03-11 16:37:30 +00:00
Matthias Clasen
8de0a2c7c6
infobar: Convert docs
...
Change link syntax, add an example image, generally clean things up.
2021-03-11 16:37:30 +00:00
Matthias Clasen
d58655b4ae
progressbar: Convert docs
...
Change link syntax, add an example image, generally clean
things up.
2021-03-11 16:37:30 +00:00
Matthias Clasen
f2b482ef65
levelbar: Convert docs
...
Change link syntax, add an example image, generally
clean things up.
2021-03-11 16:37:30 +00:00
Matthias Clasen
a2e8bd24ca
spinner: Convert docs
...
Change link syntax and add an example image.
2021-03-11 16:37:30 +00:00
Matthias Clasen
584e978840
aboutdialog: tweak the docs
...
Add a short summary.
2021-03-11 16:37:30 +00:00
Matthias Clasen
f00f900224
label: Convert docs
...
Change link syntax, add singl-line summaries,
add missing property docs.
2021-03-11 16:37:30 +00:00
Matthias Clasen
b9a02b0c24
docs: Bring the widget gallery back
...
We have all the images, lets put them to use.
2021-03-11 16:37:30 +00:00
Emmanuele Bassi
af8d8113eb
docs: Remove the last few remaining '+' from GTK
2021-03-11 16:37:30 +00:00
Emmanuele Bassi
e8b6e6cad0
docs: Clean up the first paragraph for various symbols
...
The documentation engine will use the first paragraph as the summary for
a type or constant.
2021-03-11 16:37:30 +00:00
Emmanuele Bassi
701f1b837b
docs: Show summary in the namespace index
2021-03-11 16:37:30 +00:00
Emmanuele Bassi
6781de96a5
docs: Start porting GtkImage to the new style
2021-03-11 16:37:30 +00:00
Emmanuele Bassi
4fef62c38d
docs: Port GtkAboutDialog to the new syntax
...
We should also clean up the annotations, while we're at it.
2021-03-11 16:37:30 +00:00
Emmanuele Bassi
3ef95b4065
build: Quiet down gi-docgen
...
We are only interested in the warnings and errors.
2021-03-11 16:37:30 +00:00
Emmanuele Bassi
d621a37a60
docs: Fix up the style of the X11 content file
2021-03-11 16:37:30 +00:00
Emmanuele Bassi
6f93e63d21
docs: Move detached sections into their own content file
2021-03-11 16:37:30 +00:00
Emmanuele Bassi
04fb95ce9f
docs: Split GdkDrag and GdkDrop sections
...
This way we have a section for each class.
2021-03-11 16:37:30 +00:00
Emmanuele Bassi
548280da9f
docs: Rename GdkTexture section
...
The name needs to match the class.
2021-03-11 16:37:30 +00:00
Emmanuele Bassi
b9f0cf1c8b
docs: Move gdkcairo section to an external file
2021-03-11 16:37:30 +00:00
Emmanuele Bassi
abb33bd65f
docs: Move the gtkmain section to its own document
...
The introspection data does not handle unattached sections like gtk-doc
does, so we need to move what was gtkmain into its own Markdown
document.
2021-03-11 16:37:30 +00:00
Emmanuele Bassi
542b959933
docs: Use new link syntax
2021-03-11 16:37:30 +00:00
Emmanuele Bassi
b2a99642a9
docs: Begin porting GtkWidget to the new format
2021-03-11 16:37:30 +00:00
Emmanuele Bassi
6f7e933713
doc: Port GtkConstraint to the new format
2021-03-11 16:37:30 +00:00
Emmanuele Bassi
3c0f047597
docs: De-indent GtkRecentInfo.get_applications() return value
...
Otherwise the four spaces will be treated as a pre-formatted block by
Markdown.
2021-03-11 16:37:30 +00:00
Emmanuele Bassi
a6da2db4ea
docs: Start porting GtkConstraintLayout to the new doc format
...
Drop the old gtk-doc'isms, and use the gi-docgen links instead.
2021-03-11 16:37:30 +00:00
Emmanuele Bassi
f85b847410
docs: Add metadata preamble to GTK's content files
2021-03-11 16:37:30 +00:00
Emmanuele Bassi
a6ee0dd8aa
docs: Drop gtk-doc files
...
We don't use gtk-doc to generate our API reference, so we don't need its
files lying around any more.
2021-03-11 16:37:30 +00:00
Emmanuele Bassi
0ba2a3a191
Generate GTK API reference(s) with gi-docgen
...
Stop using gtk-doc, and switch to gi-docgen.
The gi-docgen tool generates API references through the introspection
data, which has various benefits:
- it does not parse C code
- it does not generate and run C code to introspect types at build time
- it does not present a different API from the one we're exporting
Additionally, gi-docgen:
- does not generate DocBook XML in order to generate HTML
- does not go through xsltproc
- parses proper Markdown
Which makes it markedly faster than gtk-doc has ever been.
2021-03-11 16:37:30 +00:00
Emmanuele Bassi
761c327ac5
Add gi-docgen as a subproject
...
While we're developing gi-docgen it's better to have it as part of our
build.
2021-03-11 16:37:30 +00:00
Emmanuele Bassi
3760051169
ci: Update the fedora-docs Docker image
...
Use the latest base image.
2021-03-11 16:37:29 +00:00
Emmanuele Bassi
787830d360
ci: Update the CI image for docs building
...
We don't use Pandoc any more, but we need a bunch of Python modules for
gi-docgen.
2021-03-11 16:37:29 +00:00
Emmanuele Bassi
4018417ceb
ci: Update the reference job
2021-03-11 16:37:29 +00:00
Emmanuele Bassi
386256a424
Rename base version argument in run-docker.sh
...
The `--base-version` argument trips up everyone. Might as well rename it
to `--version`.
2021-03-11 16:37:29 +00:00
Matthias Clasen
f3701ff961
Merge branch 'fix-menubutton-tooltips' into 'master'
...
Limit tooltip queries to the same native
Closes #3719
See merge request GNOME/gtk!3283
2021-03-11 14:25:53 +00:00
Matthias Clasen
27295bc555
Limit tooltip queries to the same native
...
Without this, the menubuttons tooltip pops up
when hovering the popover, which is suprising
and unintended.
Fixes : #3719
2021-03-11 08:56:56 -05:00
Matthias Clasen
e62f9e33a1
Merge branch 'gdk-win32-use-window-from-point-for-master' into 'master'
...
GdkWin32: Fix mouse events in presence of transparent windows on the desktop
Closes #370 , #417 , and gimp#1082
See merge request GNOME/gtk!2800
2021-03-11 01:09:39 +00:00
Matthias Clasen
fe45f283af
Merge branch 'matthiasc/for-master' into 'master'
...
inspector: Fix surface transform regression
See merge request GNOME/gtk!3280
2021-03-09 23:59:05 +00:00
Matthias Clasen
5556907194
inspector: Fix surface transform regression
...
Ever since we added surface-to-widget transforms,
the autofading of the fps overlay did not work anymore,
since it was given the transient transform node, most
of the time.
Fix this by passing both the root of the node tree and
the node for the toplevel widget to prepare_render, and
hande the widget node to the overlays. Update the
affected overlays that need to have their positioning
adjusted.
2021-03-09 18:27:04 -05:00
Мирослав Николић
9d51821e84
Update Serbian translation
...
(cherry picked from commit f33a2febc7 )
2021-03-09 21:23:22 +00:00
Benjamin Otte
c696385130
Merge branch 'wip/otte/for-master' into 'master'
...
Wip/otte/for master
See merge request GNOME/gtk!3279
2021-03-09 19:11:09 +00:00
Benjamin Otte
0a9d075b47
wayland: Fix memleaks when rendering with Cairo
...
We were leaking buffers. This wasn't caught by valgrind and friends
because it was shared memory (with the compositor), but top(1) would
instantly see memory consumption of the app and the shell go through the
roof.
2021-03-09 19:52:59 +01:00
Benjamin Otte
b63c4d6722
wayland: Don't call _gdk_surface_update_size() all the time
...
We were calling _gdk_surface_update_size() every frame, even if the
window size didn't change. This would cause us to discard all cached
buffers and redraw the whole screen.
This was BAD.
2021-03-09 19:50:56 +01:00
Matthias Clasen
221825394f
Merge branch 'ngl-rect-borders' into 'master'
...
Speed up border rendering
See merge request GNOME/gtk!3278
2021-03-09 17:56:57 +00:00
Matthias Clasen
124f60593b
nodeparser: Print debug message before child
...
This puts the message up top, where it can be seen,
and not at the other end of an endless tree of children.
Update tests to match.
2021-03-09 12:15:25 -05:00
Matthias Clasen
09af40faeb
ngl: Render simple borders simply
...
Use 4 color commands for uniform, rectilinear
borders. Most of our borders are rounded with
Adwaita, but there are still some of these.
2021-03-09 12:15:25 -05:00
Matthias Clasen
bf59ddd01d
gsk: Add gsk_border_node_get_uniform_color
...
Maintain this bit of information separately,
it will be useful in the next commit.
2021-03-09 12:15:25 -05:00
Benjamin Otte
fea67dea6a
vulkan: Improve rounded rect clipping
...
Handle the case where the inner rounded rect is fully contained
within the outer rounded rect.
2021-03-09 17:43:28 +01:00
Benjamin Otte
9f18c138d1
vulkan: Fix invalid read
...
Look at the right rect to compute circularness
2021-03-09 17:43:28 +01:00
Matthias Clasen
bfa68223e1
Merge branch 'meson-override-dep' into 'master'
...
meson: override gtk4 dependency
See merge request GNOME/gtk!3277
2021-03-09 03:00:18 +00:00
Xavier Claessens
629e70f89d
Meson: Use gnome.post_install()
...
See https://github.com/mesonbuild/meson/pull/8272 and
https://github.com/mesonbuild/meson/issues/8268 .
2021-03-08 21:19:09 -05:00
Xavier Claessens
405dc7f557
meson: override gtk4 dependency
...
This allows applications that depends on gtk4 to build it as subproject
without hardcoding 'gtk_dep' variable name in their build definition.
2021-03-08 21:06:33 -05:00
Matthias Clasen
cba8c40aa0
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
See merge request GNOME/gtk!3276
2021-03-09 00:12:11 +00:00
Matthias Clasen
98b13933d9
Merge branch 'bilelmoussaoui/size-request-annotations' into 'master'
...
g-i: update distribute_natural_allocation annotation
See merge request GNOME/gtk!3271
2021-03-08 23:07:18 +00:00
Matthias Clasen
062383bfd3
node-format: Small docs fixes
2021-03-08 17:49:21 -05:00
Matthias Clasen
91e94556ad
spinbutton: Interpret localized digits
...
Interpret input where the characters have numeric values.
See #3387
2021-03-08 17:49:21 -05:00
Matthias Clasen
07ca46e92c
Merge branch 'ngl-clip-classification' into 'master'
...
Ngl clip classification
See merge request GNOME/gtk!3274
2021-03-08 20:20:50 +00:00
Matthias Clasen
57e354c297
glsl: Make rounded rect clipping cheaper
...
Add early acceptance checks for non-corner cases.
2021-03-08 14:41:48 -05:00
Matthias Clasen
fb0814602e
Merge branch 'matthiasc/for-master' into 'master'
...
Revert "ngl: Remove a few redundant checks"
See merge request GNOME/gtk!3273
2021-03-08 13:38:12 +00:00
Matthias Clasen
5f664dbbbb
Revert "ngl: Remove a few redundant checks"
...
This reverts commit 4375f8e382 .
These were not redundant after all, as pointed out by Timm.
2021-03-08 08:10:35 -05:00
Matthias Clasen
5d30569575
Add some more rounded rect tests
2021-03-07 21:28:19 -05:00
Matthias Clasen
46d1fc1c24
gsk: Use clip defines in shaders
...
Use the NO_CLIP and RECT_CLIP defines to make
simpler shaders for these cases.
Note: This does not work yet.
2021-03-07 20:30:45 -05:00
Matthias Clasen
2c05b758c7
ngl: Add infrastructure for clip-variants of shaders
...
Make ngl compile each shader three times.
Once with #define NO_CLIP 1
once with #define RECT_CLIP 1
and once as before.
2021-03-07 20:30:45 -05:00
Matthias Clasen
5788338a14
ngl: Classify clips
...
Maintain the 'fully contained' information in the clip
stack. This will let us pick simpler shaders in the future.
2021-03-07 20:30:45 -05:00
Matthias Clasen
d786e1d614
Merge branch 'ebassi/iface-macros' into 'master'
...
Remove invalid class macros
See merge request GNOME/gtk!3270
2021-03-07 20:22:14 +00:00
Matthias Clasen
c60a316e22
Move gtk_rounded_rect_scale_affine to the right place
...
This function should live with the rest of the
GskRoundedRect code in gskroundedrect.c.
2021-03-07 15:17:32 -05:00
Matthias Clasen
b73c9e992f
imcontext: Fix a docs mishap
2021-03-07 15:16:59 -05:00
Bilal Elmoussaoui
4980f620f9
g-i: update distribute_natural_allocation annotation
2021-03-07 20:59:01 +01:00
Matthias Clasen
87b800c11d
Merge branch 'bilelmoussaoui/gi-annotations' into 'master'
...
g-i: add missing since annotations for 4.2
See merge request GNOME/gtk!3268
2021-03-07 19:46:59 +00:00
Bilal Elmoussaoui
6e903e13a5
g-i: add missing since annotations for 4.2
2021-03-07 19:50:32 +01:00
Matthias Clasen
83c466dcd1
Merge branch 'scalable-svg' into 'master'
...
icons: Rename two icons which had the wrong extension
See merge request GNOME/gtk!3269
2021-03-07 18:43:50 +00:00
Emmanuele Bassi
676ea489cc
docs: Remove invalid macros
2021-03-07 18:34:53 +00:00
Emmanuele Bassi
70fbfd8ede
treesortable: Remove class check macro
2021-03-07 18:26:31 +00:00
Emmanuele Bassi
6234ccc974
orientable: Remove class macros
2021-03-07 18:25:55 +00:00
Emmanuele Bassi
0cfe3d45f5
celleditable: Remove class cast check macro
2021-03-07 18:25:07 +00:00
Emmanuele Bassi
41371ccae6
buildable: Remove "class" macro
2021-03-07 18:23:23 +00:00
Emmanuel Gil Peyrot
5807fee893
icons: Rename two icons which had the wrong extension
...
Fixes two warnings when opening the inspector on my PinePhone, these two
files were attempted to be loaded as PNG (as per the extension) instead
of SVG.
Signed-off-by: Emmanuel Gil Peyrot <linkmauve@linkmauve.fr >
2021-03-07 18:59:04 +01:00
Christian Hergert
b2c1d6bc9b
Merge branch 'ngl-misc-fixes' into 'master'
...
Ngl misc fixes
See merge request GNOME/gtk!3267
2021-03-07 15:59:59 +00:00
Rūdolfs Mazurs
5fd22e5981
Update Latvian translation
...
(cherry picked from commit 1d62020a19 )
2021-03-07 15:26:30 +00:00
Matthias Clasen
d0dce4cfa1
ngl: Treat radial gradients like others
...
Handle colorstop overflow for radial gradients
the same way we do for linear and conic gradients.
2021-03-07 10:18:47 -05:00
Matthias Clasen
4375f8e382
ngl: Remove a few redundant checks
...
We bail early on invisible nodes. No need to
repeat that check in individual visit functions.
2021-03-07 10:18:47 -05:00
Matthias Clasen
42b515a1e5
Merge branch 'matthiasc/for-master' into 'master'
...
Revert "flatpak: No need to build sassc anymore"
See merge request GNOME/gtk!3266
2021-03-07 14:59:57 +00:00
Matthias Clasen
6ab779cd06
roundedrect: Remove unclear language from the docs
...
The various intersection function for rounded rects are
precise. No need to add wordy disclaimers about the handling
of the corners.
2021-03-07 09:04:43 -05:00
Matthias Clasen
a261e9fca2
Revert "flatpak: No need to build sassc anymore"
...
This reverts commit 9a540841fd .
2021-03-06 16:03:41 -05:00
Matthias Clasen
50ccab487f
Merge branch 'matthiasc/for-master' into 'master'
...
vulkan: Add visible fallback rendering
See merge request GNOME/gtk!3264
2021-03-06 19:29:50 +00:00
Guillaume Bernard
ddd5e5717d
Update French translation
...
(cherry picked from commit 5b18df9b5e )
2021-03-06 18:49:41 +00:00
Мирослав Николић
390a278606
Update Serbian translation
...
(cherry picked from commit b9a451423f )
2021-03-06 18:43:51 +00:00
Changwoo Ryu
00423c54b5
Update Korean translation
...
(cherry picked from commit 60a714a25f )
2021-03-06 18:11:58 +00:00
Jordi Mas
f8f90d85ad
Update Catalan translation
2021-03-06 09:44:50 +01:00
Benjamin Otte
91932ada63
vulkan: Handle simple transforms in the clipping code
...
Requires pushing the GskTransform into the clipping code so that we
can actually look at its category.
2021-03-05 19:36:36 -05:00
Matthias Clasen
dbb264dfc9
vulkan: Add visible fallback rendering
...
Hook up the "Show fallback rendering" switch for Vulkan.
This brings home the sobering truth that the Vulkan renderer
is doing *all* fallback, since we switched from offset nodes
to transform nodes.
2021-03-05 18:42:04 -05:00
Matthias Clasen
3aa89efcf4
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
See merge request GNOME/gtk!3263
2021-03-05 20:30:54 +00:00
Matthias Clasen
82f40a92c1
searchentry: Typo fix
2021-03-05 15:07:02 -05:00
Matthias Clasen
ae1a950a93
flatpak: Fix the gtk4-demo build
...
This was overlooked in 8e7e821033 .
2021-03-05 15:06:20 -05:00
Matthias Clasen
2228181b35
Merge branch 'wip/exalm/window-shadow-dark-4' into 'master'
...
Adwaita: Use transparent black for window border in dark too
See merge request GNOME/gtk!3261
2021-03-05 19:41:39 +00:00
Matthias Clasen
7357120c81
Merge branch 'wip/jimmac/fix-flatpak-build' into 'master'
...
Flatpak: Update build manifests
See merge request GNOME/gtk!3259
2021-03-05 19:11:36 +00:00
Alexander Mikhaylenko
0942e863f2
Adwaita: Use transparent black for window border in dark too
...
Avoid smear when the background behind the window is dark. Adjust opacity
to make it appear roughly the same as before on white background.
2021-03-05 22:59:25 +05:00
Matthias Clasen
08f3618a47
Merge branch 'wip/jimmac/sidebar-focus' into 'master'
...
Adwaita: Regular focus ring for sidebar rows
Closes #3708
See merge request GNOME/gtk!3258
2021-03-05 17:17:04 +00:00
Jakub Steiner
8e7e821033
Flatpak: Update build manifests
...
- point to the upstream repo for wayland
- disable disabling of sassc
- switch wayland from autotools to meson
2021-03-05 18:00:17 +01:00
Jakub Steiner
11d6f2ddd0
Adwaita: Regular focus ring for sidebar rows
...
- style sidebar rows as regular items like buttons wrt focus
- define transition as part of the focus-ring(),
only animate outline related properties rather than `all`
Fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/3708
2021-03-05 17:45:58 +01:00
Kukuh Syafaat
490384c69f
Update Indonesian translation
...
(cherry picked from commit e54dc87a15 )
2021-03-05 11:53:01 +00:00
Matthias Clasen
468242b13b
Merge branch 'iconbrowser-fix' into 'master'
...
iconbrowser: fix search<>category interaction
Closes #3717
See merge request GNOME/gtk!3257
2021-03-05 01:11:11 +00:00
Matthias Clasen
d3d49ce7f1
iconbrowser: fix search<>category interaction
...
Make search act like a separate, filtered view of
all icons. This is how it worked in gtk3, and how
it should be.
Fixes : #3717
2021-03-04 19:30:02 -05:00
Matthias Clasen
c303ec1553
Merge branch 'preedit-selection-fix' into 'master'
...
Preedit selection fix
Closes #1123
See merge request GNOME/gtk!3255
2021-03-04 22:48:25 +00:00
Matthias Clasen
d28df0b87e
textview: Delete selection when preedit starts
...
This prevents confusing misrendering when the preedit text
pushes the selection text out of the rendered selection.
Fixes : #1123
2021-03-04 15:18:30 -05:00
Matthias Clasen
d1fbfb9c4e
textview: Send anchor with surrounding
...
We have the api to do it now.
2021-03-04 15:18:30 -05:00
Matthias Clasen
ccae0e1732
text: Optimize away 0-change insertions and deletions
...
We can short-circuit insert and delete calls that are
not causing any change.
2021-03-04 15:18:30 -05:00
Matthias Clasen
447203ce52
text: Delete selection when preedit starts
...
This prevents confusing misrendering when the preedit text
pushes the selection text out of the rendered selection.
Fixes : #1123
2021-03-04 15:18:30 -05:00
Matthias Clasen
feccdad9d2
text: Send anchor with surrounding
...
We have the api to do it now.
2021-03-04 15:18:30 -05:00
Matthias Clasen
35fceca157
imwayland: Pass anchor with surrounding
...
This was missing in the initial implementation since
GtkIMContext did not have it in its api, but it was
added now, so we can send the information.
2021-03-04 15:18:30 -05:00
Matthias Clasen
97db959305
immulticontext: Implement [gs]et_surrounding_with_selection
...
This is the recommended api, going forward.
2021-03-04 15:18:30 -05:00
Matthias Clasen
4b9aeaf9e3
imcontext: Add [gs]et_surrounding_with_selection
...
The Wayland text protocol expects to get both ends
of the selection with its surrounding call, so make
that available via GtkIMContext. We add this as new
api and vfuncs, and fall back, so that existing
implementations keep working.
2021-03-04 15:18:30 -05:00
Matthias Clasen
053d7cfe9f
Merge branch 'wip/chergert/remove-zero-suffix-array' into 'master'
...
ngl: remove unnecessary suffix array
See merge request GNOME/gtk!3254
2021-03-03 21:53:27 +00:00
Jordi Mas
2959f219e4
Update Catalan translation
2021-03-03 22:31:04 +01:00
Christian Hergert
b368d3abde
ngl: remove unnecessary suffix array
...
We didn't end up using this in the final version, so we can just delete
it and avoid MSVC issues.
2021-03-03 13:03:24 -08:00
Matthias Clasen
b533bba3f3
Merge branch 'bilelmoussaoui/annotations-fix' into 'master'
...
update annotation of gtk_single_selection_get_selected_item
See merge request GNOME/gtk!3253
2021-03-03 15:11:00 +00:00
Bilal Elmoussaoui
aae67b8fbd
gtk: update annotation of gtk_single_selection_get_selected_item
2021-03-03 14:19:45 +01:00
Matthias Clasen
d79354dbf5
Merge branch 'wip/exalm/headerbar-css' into 'master'
...
Header bar CSS tweaks
See merge request GNOME/gtk!3252
2021-03-03 13:11:22 +00:00
Alexander Mikhaylenko
aa693159dc
adwaita: Remove the nested headerbars hack
...
We clip the window now, it's not necessary anymore.
2021-03-03 17:35:15 +05:00
Alexander Mikhaylenko
5fef637e84
adwaita: Remove headerbar sheen on backdrop
...
It's gone from active windows since c9807f5afe ,
but was still there in backdrop.
2021-03-03 17:34:22 +05:00
Matthias Clasen
208a53fa39
Merge branch 'label-mnemonic-fix' into 'master'
...
label: Fix markup parsing interactions
See merge request GNOME/gtk!3250
2021-03-03 12:00:37 +00:00
Matthias Clasen
875a92b95f
label: Fix markup parsing interactions
...
We were not handling mnemonics vs markup right
in all cases. Rewrite the _-stripping code to
do it during the link parsing, instead of as
a separate function. This avoids the issue of
stripping _ from attribute names in markup.
Add tests.
Fixes: 3706
2021-03-02 23:25:01 -05:00
Matthias Clasen
c23848c03e
Merge branch 'fix-glyph-serialization' into 'master'
...
rendernode: Fix glyph serialization
Closes #3710
See merge request GNOME/gtk!3248
2021-03-02 20:31:09 +00:00
Matthias Clasen
96ac85038b
rendernode: Fix glyph serialization
...
We serializing to a string of ASCII, we need to
escape some chars, such as '\' and '"'.
Fixes : #3710
2021-03-02 11:32:29 -05:00
Baurzhan Muftakhidinov
69f051798e
Update Kazakh translation
...
(cherry picked from commit 62e9dff536 )
2021-03-02 03:35:10 +00:00
Matthias Clasen
1c6da51000
Merge branch 'wip/chergert/fix-ngl-gles' into 'master'
...
ngl: fix typo from NGL rename
See merge request GNOME/gtk!3246
2021-03-02 00:37:00 +00:00
Christian Hergert
d6694a4408
ngl: fix typo from NGL rename
2021-03-01 10:28:26 -08:00
Matthias Clasen
0ccca910df
Merge branch 'submodules' into 'master'
...
Allow GTK4 to be added as a subproject
See merge request GNOME/gtk!3242
2021-03-01 16:01:25 +00:00
Matthias Clasen
fd2909abb2
Merge branch 'broadway-guint32' into 'master'
...
broadway: Restore guint32 type for memory size
Closes #3702
See merge request GNOME/gtk!3244
2021-02-27 23:16:28 +00:00
Rafał Dzięgiel
d586410416
broadway: Restore guint32 type for memory size
...
guint32 is used as part of the protocol in broadway backend.
Memory size declared with it was mistakenly replaced with size_t type
which does not guarantee being 32bit on all platforms, leading to a crash.
2021-02-27 23:43:12 +01:00
Jiri Grönroos
4721e760e7
Update Finnish translation
...
(cherry picked from commit 3cb5a831e3 )
2021-02-26 12:10:10 +00:00
BogDan Vatra
72700d1644
Allow GTK4 to be added as a subproject
2021-02-26 09:27:02 +02:00
Emin Tufan Çetin
c274c35583
Update Turkish translation
2021-02-25 14:28:49 +00:00
Emin Tufan Çetin
d2c3f8f496
Update Turkish translation
2021-02-25 14:02:50 +00:00
Matthias Clasen
bffb666914
Merge branch 'matthiasc/for-master' into 'master'
...
imcontext: Fixes to the state machine
See merge request GNOME/gtk!3238
2021-02-25 12:25:02 +00:00
Matthias Clasen
ab615104f5
Merge branch 'wip/carlosg/touchpad-gesture-devices' into 'master'
...
gdk/wayland: Assign logical pointer to touchpad gesture events
See merge request GNOME/gtk!3240
2021-02-25 12:23:26 +00:00
Jiri Grönroos
9c2674ee1e
Update Finnish translation
...
(cherry picked from commit 0fd0b00ec9 )
2021-02-25 10:46:56 +00:00
Carlos Garnacho
68ced9b553
gdk/wayland: Assign logical pointer to touchpad gesture events
...
These events don't make sense on physical devices (for starters, they
are relative to the logical pointer position). Use this device for
those events, also happens to be what the upper parts expect of them.
2021-02-25 01:08:07 +01:00
Matthias Clasen
177f6b377d
Merge branch 'bilelmoussaoui/gdk-draw-context' into 'master'
...
gdk: drop the latest mention of DrawingContext
See merge request GNOME/gtk!3232
2021-02-24 22:28:47 +00:00
Matthias Clasen
55f871c193
imcontext: Fixes to the state machine
...
It turns out that we we were sometimes emitting
preedit-end multiple times, and sometimes not at
all. Same for preedit-start. To fix this up, introduce
a in_compose_sequence flag, maintain it, and use it
in the right places.
After these changes, both
C-S-u 1 2 3 Enter
Compose a e
generate the right signals:
preedit-start, preedit-changed,..., preedit-end, commit
2021-02-24 13:31:31 -05:00
Carlos Garnacho
ce2835265b
Merge branch 'wip/carlosg/mark-settings-valid-again' into 'master'
...
gdk/wayland: Make more matched settings from the portal as valid
See merge request GNOME/gtk!3236
2021-02-24 16:12:13 +00:00
Carlos Garnacho
75ae0e04e1
gdk/wayland: Make more matched settings from the portal as valid
...
Commit 97b5fad131 was a forward port from a gtk3 patch, but the hunk
was applied on the wrong bits of code.
Ensure the initialization paths also do mark settings read from the
portal as valid, so the checks for optional/newer settings actually have
the expected result. It is also desirable to mark settings as valid
after configuration changes (as that patch did effectively do), but not
enough to fix all situations.
2021-02-24 16:41:13 +01:00
Matthias Clasen
1f284fcd70
4.1.1
2021-02-23 20:59:16 -05:00
Matthias Clasen
718a95c1d2
Merge branch 'matthiasc/for-master' into 'master'
...
composetable: Remove some redundant code
See merge request GNOME/gtk!3234
2021-02-24 01:57:47 +00:00
Matthias Clasen
cd2854a5c6
Merge branch 'wip/chergert/glproto' into 'master'
...
gsk: add OpenGL based GskNglRenderer
See merge request GNOME/gtk!3225
2021-02-24 01:14:14 +00:00
Fran Dieguez
86151622db
Updated Galician translations
2021-02-24 01:51:12 +01:00
Matthias Clasen
915e3f0e28
composetable: Remove some redundant code
...
Pointed out by Peter Bloomfield.
2021-02-23 19:14:26 -05:00
Matthias Clasen
a4e7b03185
inspector: Fix a typo
...
When selecting the "ngl" renderer, the inspector was
saying Renderer: Unknown, due to a typo. Fix that.
2021-02-23 18:37:32 -05:00
Matthias Clasen
e9ed874231
gsk: Replace a last instance of "next"
...
The output of GSK_RENDERER=help was still talking about
the "next" renderer, while actually looking for "ngl".
2021-02-23 18:36:41 -05:00
Christian Hergert
2a38cecd33
gsk: add OpenGL based GskNglRenderer
...
The primary goal here was to cleanup the current GL renderer to make
maintenance easier going forward. Furthermore, it tracks state to allow
us to implement more advanced renderer features going forward.
Reordering
This renderer will reorder batches by render target to reduce the number
of times render targets are changed.
In the future, we could also reorder by program within the render target
if we can determine that vertices do not overlap.
Uniform Snapshots
To allow for reordering of batches all uniforms need to be tracked for
the programs. This allows us to create the full uniform state when the
batch has been moved into a new position.
Some care was taken as it can be performance sensitive.
Attachment Snapshots
Similar to uniform snapshots, we need to know all of the texture
attachments so that we can rebind them when necessary.
Render Jobs
To help isolate the process of creating GL commands from the renderer
abstraction a render job abstraction was added. This could be extended
in the future if we decided to do tiling.
Command Queue
Render jobs create batches using the command queue. The command queue
will snapshot uniform and attachment state so that it can reorder
batches right before executing them.
Currently, the only reordering done is to ensure that we only visit
each render target once. We could extend this by tracking vertices,
attachments, and others.
This code currently uses an inline array helper to reduce overhead
from GArray which was showing up on profiles. It could be changed to
use GdkArray without too much work, but had roughly double the
instructions. Cycle counts have not yet been determined.
GLSL Programs
This was simplified to use XMACROS so that we can just extend one file
(gskglprograms.defs) instead of multiple places. The programs are added
as fields in the driver for easy access.
Driver
The driver manages textures, render targets, access to atlases,
programs, and more. There is one driver per display, by using the
shared GL context.
Some work could be done here to batch uploads so that we make fewer
calls to upload when sending icon theme data to the GPU. We'd need
to keep a copy of the atlas data for such purposes.
2021-02-23 14:41:52 -08:00
Ask Hjorth Larsen
9698d4aa2a
Updated Danish translation of gtk-properties
2021-02-23 01:23:03 +01:00
Ask Hjorth Larsen
dd2851a0ff
Updated Danish translation
2021-02-23 01:23:03 +01:00
Bilal Elmoussaoui
adf9377b61
gdk: drop the latest mention of DrawingContext
2021-02-22 22:15:14 +00:00
Matthias Clasen
700f39bfca
Merge branch 'compose-warning' into 'master'
...
imcontext: Take out the warnings
See merge request GNOME/gtk!3230
2021-02-22 20:31:19 +00:00
Matthias Clasen
baec7079e0
imcontext: Take out the warnings
...
Don't warn about Compose file constructs we don't
support. We haven't supported these for a long time,
and nobody has every complained. No need to wake
up sleeping dogs.
2021-02-22 15:08:58 -05:00
Timm Bäder
f83644edee
Merge branch 'SilverRainZ-master-patch-42810' into 'master'
...
gtk-demo: Fix typo GtkKabel -> GtkLabel
See merge request GNOME/gtk!3229
2021-02-22 08:20:34 +00:00
Emin Tufan Çetin
30d4417064
Update Turkish translation
2021-02-21 17:56:30 +00:00
Emin Tufan Çetin
b428fafade
Update Turkish translation
2021-02-21 17:51:14 +00:00
Emin Tufan Çetin
63d1dc307a
Update Turkish translation
2021-02-21 16:27:09 +00:00
Shengyu Zhang
55bfadadc4
gtk-demo: Fix typo GtkKabel -> GtkLabel
2021-02-21 16:20:22 +00:00
Piotr Drąg
179fae32a5
Update POTFILES.in
2021-02-21 12:50:44 +01:00
Matthias Clasen
e220b24b70
Merge branch 'wip/chergert/macos-gl-opaque-context' into 'master'
...
macos: make OpenGL context opaque when possible
See merge request GNOME/gtk!3226
2021-02-20 02:37:52 +00:00
Matthias Clasen
9061256122
Merge branch 'wip/chergert/fix-macos-resizing' into 'master'
...
macos: fix resizing of resizable windows on macOS
See merge request GNOME/gtk!3227
2021-02-20 02:32:15 +00:00
Christian Hergert
ea0d487f0b
macos: fix resizing of resizable windows on macOS
2021-02-19 15:43:49 -08:00
Christian Hergert
b2fd09625c
macos: make OpenGL context opaque when possible
...
If our opaque region is the entire surface, then we can make the OpenGL
context opaque like we do for decorated windows. This improves performance
as the compositor does not need to blend the surface with the contents
behind the window.
2021-02-19 13:23:26 -08:00
Matthias Clasen
5797c72e9c
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
See merge request GNOME/gtk!3224
2021-02-19 14:41:36 +00:00
Zander Brown
d02cfceb3d
Update British English translation
...
(cherry picked from commit 1f18d2638f )
2021-02-19 14:26:26 +00:00
Zander Brown
451af280a2
Update British English translation
...
(cherry picked from commit 6f26331864 )
2021-02-19 14:24:32 +00:00
Matthias Clasen
516776b630
gtk-demo: Make --version match about
...
Print the same version information in --version
that we show in the about dialog.
2021-02-18 22:52:15 -05:00
Matthias Clasen
4d0a1a97cc
widget-factory: Make --version match about
...
Print the same version information in --version
that we show in the about dialog.
2021-02-18 22:51:35 -05:00
Matthias Clasen
3ee5354e0f
imwayland: Be careful about cursor positions
...
We don't want to hand out cursor positions based on
the original preedit text and then tweak the text to
be different.
2021-02-18 15:33:01 -05:00
Matthias Clasen
07295ac169
Merge branch 'unintrusive-compose-preedit' into 'master'
...
Unintrusive compose preedit
See merge request GNOME/gtk!3220
2021-02-18 17:36:08 +00:00
Matthias Clasen
447e6db847
Merge branch 'wip/carlosg/font-setting-lookups' into 'master'
...
gdk/wayland: Look for font settings recursively
Closes #3680
See merge request GNOME/gtk!3218
2021-02-18 17:18:37 +00:00
Matthias Clasen
d84a028455
imwayland: Tweak preedit text
...
Tweak the preedit text we get from IBus (via the compositor) to
match what GtkIMContextSimple produces for Compose sequences now.
This provides a unified experience.
2021-02-18 11:44:09 -05:00
Matthias Clasen
4327a866f4
imcontext: Make Compose preedit less intrusive
...
Tweak the preedit display for Compose sequences to
be not so distracting. We only show the Compose key
when it occurs in the middle of the sequence or is
the only key so far, and use · instead of ⎄ for it.
Also, make sure to display dead keys more adequately.
2021-02-18 11:44:09 -05:00
Carlos Garnacho
1fbdfe340e
gdk/wayland: Look for font settings recursively
...
Use the infrastructure already available to look up keys, instead.
This does the right thing and looks up the setting across all
sources.
Fixes: https://gitlab.gnome.org/GNOME/gtk/-/issues/3680
2021-02-18 16:50:45 +01:00
Matthias Clasen
4a47bdf596
Merge branch 'wip/exalm/root' into 'master'
...
widget: Don't assume GtkWindow root in gtk_widget_propagate_state()
See merge request GNOME/gtk!3217
2021-02-18 14:38:50 +00:00
Alexander Mikhaylenko
8e2f90e342
widget: Don't assume GtkWindow root in gtk_widget_propagate_state()
...
Avoid crashes with GtkDragIcon children.
2021-02-18 13:41:41 +05:00
Matthias Clasen
32c7ca50ea
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
Closes #3679 and #3678
See merge request GNOME/gtk!3216
2021-02-18 05:52:44 +00:00
Matthias Clasen
19b9967a72
text: Fix sticky preedit attrs
...
In some cases, we were inadvertedly merging the
preedit attributes into priv->attrs, instead of
keeping them separate. This was causing the underlines
to grow beyond the preedit and never go away. One
place where this was showing up is the fontchooser
preview.
Fixes : #3679
2021-02-17 23:25:31 -05:00
Matthias Clasen
da71a37945
imwayland: Return limited preedit attributes
...
It should not matter, but it is the right thing to
do to limit the preedit attributes to the length
of the preedit text.
2021-02-17 22:57:41 -05:00
Matthias Clasen
05fe2441a7
imcontext: Enable font fallback for preedit
...
Not doing so only invites hexboxes.
Fixes : #3678
2021-02-17 22:11:57 -05:00
Matthias Clasen
35488959b4
paned: Add a paned handle class
...
Instead of bending GtkGizmo to the breaking point,
split off a GtkPanedHandle class that just does
what is needed here. Its simpler, and lets us keep
GtkGizmo simpler too. Everybody wins.
2021-02-17 21:45:33 -05:00
Matthias Clasen
af1981eda2
popovercontent: Few small fixes
...
Forgot to include config.h. Oops, and we make things
a bit shorter still.
2021-02-17 21:44:53 -05:00
Matthias Clasen
38da88908d
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
Closes #3676 and #3675
See merge request GNOME/gtk!3215
2021-02-17 20:49:41 +00:00
Matthias Clasen
41abda9f03
Make gtk_im_modules_init properly private
...
Putting non-exported symbols in public headers can
only lead to confusion and day drinking. Don't do it.
Fixes : #3676
2021-02-17 15:25:42 -05:00
Matthias Clasen
5a8e2a8c2d
gsk: Add a missing GDK_AVAILABLE_IN_ALL
...
gsk_text_node_has_color_glyphs was not properlty exported,
by accident.
Fixes : #3675
2021-02-17 15:20:24 -05:00
Matthias Clasen
7390e2490c
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
See merge request GNOME/gtk!3214
2021-02-17 12:55:39 +00:00
Matthias Clasen
04daa236ad
Revert "gizmo: Add a css_changed function"
...
This reverts commit 39f72b3834 .
2021-02-16 23:51:14 -05:00
Matthias Clasen
31ceb4ddfb
Revert "gizmo: Chain up in css_changed"
...
This reverts commit bb0a1b0cfe .
2021-02-16 23:51:14 -05:00
Matthias Clasen
c2f811dd29
popover: Add a popover content class
...
Instead of bending GtkGizmo to the breaking point,
split off a GtkPopoverContent class that just does
what is needed here. Its simpler, and lets us keep
GtkGizmo simpler too.
2021-02-16 23:51:14 -05:00
Matthias Clasen
189e0c05fd
Merge branch 'wip/smcv/reftest-dedup' into 'master'
...
Reduce duplication in reftests
See merge request GNOME/gtk!3203
2021-02-17 03:55:45 +00:00
Matthias Clasen
8ee4ea4282
Merge branch 'wip/jimmac/tiled-resize-area-gtk4' into 'master'
...
Adwaita: control surface for resize tiled windows
Closes #3670
See merge request GNOME/gtk!3211
2021-02-17 03:54:27 +00:00
Jakub Steiner
edcd4c6207
Adwaita: control surface for resize tiled windows
...
- window resizing control area is implemented as where the shadows are drawn
- create a 'fake' shadow for the tiled case to allow easier resizing of
the tiled window ratio even if it's offset to the side of the border
Fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/3670
2021-02-16 14:10:14 +01:00
Matthias Clasen
f5bd591d89
Merge branch 'wip/jimmac/scrollbars-fine-tune-fix' into 'master'
...
Adwaita: avoid fine-tune scrollbars jumping
Closes #3672
See merge request GNOME/gtk!3208
2021-02-16 12:26:02 +00:00
Jakub Steiner
67b5a34bad
Adwaita: Avoid fine-tune scrollbars jumping
...
Fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/3672
2021-02-16 11:59:45 +01:00
Matthias Clasen
27071b5cfb
Merge branch 'matthiasc/for-master' into 'master'
...
wayland: Complete our buffer format listing
See merge request GNOME/gtk!3207
2021-02-16 04:33:08 +00:00
Matthias Clasen
19b9c42562
Merge branch 'fix-scrollbar-sizing' into 'master'
...
gizmo: Chain up in css_changed
See merge request GNOME/gtk!3206
2021-02-15 21:43:47 +00:00
Matthias Clasen
bf6a40f39b
wayland: Complete our buffer format listing
...
The debug spew for printing out supported buffer
formats was missing a bunch, among them the fp16
formats that are interesting for HDR support.
Add them.
Note that we still only support ARGB8888. But
at least we can print out what don't support.
2021-02-15 16:42:17 -05:00
Matthias Clasen
bb0a1b0cfe
gizmo: Chain up in css_changed
...
css_changed is a vfunc that *must* chain up.
Failure to do so broke the resizing of overlay scrollbars,
amongst other things.
This bug was introduced in 39f72b3834 .
2021-02-15 14:26:52 -05:00
Matthias Clasen
2ac5c3282f
Merge branch 'lenient-compose-parsing' into 'master'
...
imcontext: Be more lenient in parsing Compose
See merge request GNOME/gtk!3201
2021-02-15 18:08:45 +00:00
Matthias Clasen
6b3c356eb7
Merge branch 'wip/jimmac/larger-smaller-scrollbar-gtk4' into 'master'
...
Adwaita: Scrollbar transitions and size
Closes #1886
See merge request GNOME/gtk!3204
2021-02-15 18:06:00 +00:00
Jakub Steiner
5c5cd34c2f
Adwaita: Scrollbar transitions and size
...
- tone down the size of the controller again
- transition between the indicator and control fluidly
Fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/1886
2021-02-15 12:25:09 +01:00
Simon McVittie
1c6cf7a3b6
reftests: Share reftest-compare.[ch] between GSK and GTK tests
...
The only non-whitespace difference is that the copy in GSK does not
set the symbol's visibility.
Signed-off-by: Simon McVittie <smcv@debian.org >
2021-02-15 09:22:41 +00:00
Simon McVittie
6b29eeeb1c
reftest-compare: Fix spelling of "diff"
...
This is the only non-whitespace difference between the copies in
testsuite/reftests/ and testsuite/gsk/.
Signed-off-by: Simon McVittie <smcv@debian.org >
2021-02-15 09:22:41 +00:00
Matthias Clasen
2f43b8dc49
imcontext: Improve compose table parsing
...
Avoid leaking value in error cases, and actually
emit a warning for a missing quote. Pointed out
by Peter Bloomfield.
2021-02-15 01:46:00 -05:00
Jordi Mas
7b4cfd38bc
Update Catalan translation
2021-02-14 21:52:55 +01:00
Matthias Clasen
d2e074e36b
imcontext: Be more lenient in parsing Compose
...
X11 allows keysyms to be specified in addition to strings.
We only support the strings. In the past, we ignored everything
after the string. Go back to doing that, but issue a warning
that we've ignored the keysym.
2021-02-14 12:56:00 -05:00
Matthias Clasen
2623932886
Merge branch 'fix-compose-comments' into 'master'
...
Fix compose comments
Closes #3664
See merge request GNOME/gtk!3199
2021-02-14 17:25:58 +00:00
Matthias Clasen
b0a82b1dfe
Merge branch 'popup-shadow-width' into 'master'
...
Support shadows on popovers
See merge request GNOME/gtk!3089
2021-02-14 17:22:50 +00:00
Matthias Clasen
f15aa2f3e5
imcontext: Fix a regression in Compose file parsing
...
We accidentally dropped the handing of # comments.
Bring it back. Test included.
Fixes : #3664
2021-02-14 11:56:24 -05:00
Matthias Clasen
5d6792137d
testsuite: Add a missing file
2021-02-14 11:56:24 -05:00
Matthias Clasen
52a2891933
window: Add some more details to css docs
...
Mention more of the supported style classes.
2021-02-14 11:22:44 -05:00
Matthias Clasen
7ebc3a9489
Update popover css docs
...
Mention that shadows are now possible.
2021-02-14 11:14:23 -05:00
Matthias Clasen
04fb1421dc
Merge branch 'antoniof-master-patch-32022' into 'master'
...
docs: Mark heading in migration guide
See merge request GNOME/gtk!3198
2021-02-14 15:59:29 +00:00
Matthias Clasen
a4f17eaa8b
macos: Apply popup shadow width
2021-02-14 10:52:33 -05:00
Matthias Clasen
e0c48e74bd
win32: Apply popup shadow width
2021-02-14 10:52:33 -05:00
António Fernandes
a810f600bf
docs: Mark heading in migration guide
...
This heading was missing from the index because it was not marked as one
2021-02-14 15:20:54 +00:00
Matthias Clasen
ad9c813ed1
x11: Apply popup shadow with
2021-02-14 10:12:10 -05:00
Matthias Clasen
aa1d08687d
popover: Handle shadow changes
...
When the box-shadow css property of the contents
widget changes, queue a resize on the popover.
2021-02-14 10:12:10 -05:00
Matthias Clasen
39f72b3834
gizmo: Add a css_changed function
...
In a break from the current gizmo api, add a separate
setter, since the calls with long argument lists full
of NULL are getting out of hand.
2021-02-14 10:12:10 -05:00
Matthias Clasen
7332b4f1d9
Add a test for popover positioning
...
This is useful for testing the interaction of arrows, shadows
or offsets with popover positioning.
2021-02-14 10:11:17 -05:00
Matthias Clasen
b948799778
popover: Support shadows
...
Use gdk_popup_layout_set_shadow_width to take shadows into
account when positioning popovers, and set the input region
to exclude the shadow, since we aren't doing interactive
resizing and the like.
When the popover has a beak, we make the surface size be
content size + shadow + tail, and then position the content
according to the final position inside this slightly too large
surface. The surface being too large doesn't matter, since we
set up an input region.
2021-02-14 10:11:17 -05:00
Matthias Clasen
aec738745a
wayland: Set shadow width on popup surfaces
...
Take the shadow width from the popup layout into account.
2021-02-14 10:11:17 -05:00
Matthias Clasen
ea19f7c360
popuplayout: Add shadow width
...
Add shadow width to the GdkPopupLayout struct. This
information is needed by the compositor to make correct
positioning decisions about popups.
2021-02-13 21:01:46 -05:00
Matthias Clasen
0222d389ee
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
See merge request GNOME/gtk!3197
2021-02-14 01:59:35 +00:00
Matthias Clasen
b3a055a9b7
popover: Queue a resize when position changes
...
At least with an arrow, changing the position
requires a resize
2021-02-13 20:27:01 -05:00
Matthias Clasen
bd877ccf06
popover: Cosmetics
2021-02-13 20:26:54 -05:00
Balázs Meskó
a8d87f80f3
Update Hungarian translation
2021-02-14 00:07:07 +00:00
Matthias Clasen
6601d79b2d
Merge branch 'revert-82ab039a' into 'master'
...
Revert "Merge branch 'disable-macos-ci' into 'master'"
See merge request GNOME/gtk!3192
2021-02-12 21:29:08 +00:00
Matthias Clasen
5ff843f97d
Stop passing introspection=false to graphene
...
This should no longer be possible (and the introspection
option is no longer a boolean.
2021-02-12 16:04:15 -05:00
Matthias Clasen
b1c1e02c28
ci: Add debug spew on macos
2021-02-12 15:24:27 -05:00
Bartłomiej Piotrowski
0ce0402edf
Revert "Merge branch 'disable-macos-ci' into 'master'"
...
This reverts merge request !3183
2021-02-12 19:40:57 +00:00
Matthias Clasen
5d13bb7aa2
Merge branch 'win32.surface.resize' into 'master'
...
Some fixes for resizing of GDK/Win32 surfaces
See merge request GNOME/gtk!3144
2021-02-12 14:07:07 +00:00
Matthias Clasen
c5e69e83b5
Merge branch 'flatpak-tweaks' into 'master'
...
Flatpak tweaks
See merge request GNOME/gtk!3187
2021-02-12 14:03:54 +00:00
Matthias Clasen
bcfca52e9e
Merge branch 'ci-fedora-33' into 'master'
...
ci: Update the Fedora image to F33
See merge request GNOME/gtk!3188
2021-02-12 13:46:14 +00:00
Matthias Clasen
919e06a831
Merge branch 'wip/baedert/for-master' into 'master'
...
Wip/baedert/for master
See merge request GNOME/gtk!3189
2021-02-12 12:45:51 +00:00
Timm Bäder
0d5957b97a
nativedialog: Remove unused run state
2021-02-12 08:39:40 +01:00
Timm Bäder
6e4bba3d75
build: Check for mallinfo2 instead of mallinfo
...
Similar to e89fcbfad6
but the tests we use mallinfo() in really aren't important to not worth
the effort to differentiate between mallinfo and mallinfo2. Only check
for mallinfo2().
2021-02-12 08:39:40 +01:00
Matthias Clasen
3e426e4c5b
flatpak: Try harder to disable sassc
2021-02-12 00:26:10 -05:00
Matthias Clasen
8d4f4af8ef
Add devel styling to nightly flatpaks
...
Pass -Dprofile=devel to the gtk build for our nightly
flatpaks, so they pick up devel styling.
2021-02-12 00:10:30 -05:00
Matthias Clasen
3aa3c21d69
demos: Add devel styling
...
Add a -Dprofile=devel meson option, and add some visual
hints to the demos that you are running a nightly build.
2021-02-12 00:08:55 -05:00
Matthias Clasen
9a540841fd
flatpak: No need to build sassc anymore
...
We should be able to do a gtk build without rebuilding
css nowadays.
2021-02-11 23:00:19 -05:00
Matthias Clasen
0a3fa40923
ci: Update the Fedora image to F33
2021-02-11 22:02:39 -05:00
Matthias Clasen
9f10f9a595
Merge branch 'fix-network-places' into 'master'
...
placesview: Avoid use-after-free
See merge request GNOME/gtk!3186
2021-02-11 19:41:10 +00:00
Matthias Clasen
560e27a3f4
Merge branch 'wip/jimmac/tiled-shadow-fix-fix-gtk4' into 'master'
...
Adwaita: bring borders for tiled
Closes #3661
See merge request GNOME/gtk!3184
2021-02-11 17:04:47 +00:00
Matthias Clasen
4df7cc948c
Merge branch 'ebassi/memdup2' into 'master'
...
Use g_memdup2()
See merge request GNOME/gtk!3157
2021-02-11 17:02:00 +00:00
Emmanuele Bassi
b74a9445af
tests: Move from g_memdup() to g_memdup2()
...
The g_memdup() function is replaced by a safer version in newer versions
of GLib.
2021-02-11 14:22:23 +00:00
Emmanuele Bassi
a63a2b26cf
Ensure we don't overflow when using g_memdup2()
...
When we turn integers into size_t we should check we're not going to
make a mess.
2021-02-11 14:22:23 +00:00
Emmanuele Bassi
43fd9d16c5
win32: Move from g_memdup() to g_memdup2()
...
Use `size_t` and `gsize` consistently for the length argument in every
function taking a bytes array and a length.
2021-02-11 14:22:23 +00:00
Emmanuele Bassi
78e3908a00
gtk: Move from g_memdup() to g_memdup2()
...
The g_memdup() function is replaced by a safer version in newer versions
of GLib.
2021-02-11 14:22:22 +00:00
Emmanuele Bassi
a9c616284a
gsk: Move from g_memdup() to g_memdup2()
...
The g_memdup() function is replaced by a safer version in newer versions
of GLib.
2021-02-11 14:22:22 +00:00
Emmanuele Bassi
386d8326ca
gdk: Move from g_memdup() to g_memdup2()
...
The g_memdup() function is replaced by a safer version in newer versions
of GLib.
2021-02-11 14:22:22 +00:00
Emmanuele Bassi
cf3f742ad8
x11: Move from g_memdup() to g_memdup2()
...
The g_memdup() function is replaced by a safer version in newer versions
of GLib.
2021-02-11 14:22:22 +00:00
Emmanuele Bassi
3a3e029270
wayland: Move from g_memdup() to g_memdup2()
...
The g_memdup() function is replaced by a safer version in newer versions
of GLib.
2021-02-11 14:22:22 +00:00
Emmanuele Bassi
435d12680d
macos: Move from g_memdup() to g_memdup2()
...
The g_memdup() function is replaced by a safer version in newer versions
of GLib.
2021-02-11 14:22:22 +00:00
Emmanuele Bassi
504b5bbd1b
broadway: Move from g_memdup() to g_memdup2()
...
The g_memdup() function is replaced by a safer version in newer versions
of GLib.
2021-02-11 14:22:22 +00:00
Jakub Steiner
f953dfef11
Adwaita: bring borders for tiled
...
Fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/3661
2021-02-11 15:16:57 +01:00
Matthias Clasen
95d48ac2e8
placesview: Avoid use-after-free
...
The places view has questionable code for handling
'destroy', which seems to trigger use-after-free in
some cases. Clean this up a bit by acknowledging the
cancellation fully, rather than relying on the
destroyed flag.
2021-02-11 09:14:34 -05:00
Emmanuele Bassi
965e74f902
Add compatibility shim for g_memdup2()
...
We don't necessarily want to depend on a newer version of GLib, given
that we're not really using g_memdup() in the wrong way.
2021-02-11 12:57:38 +00:00
Matthias Clasen
0cc43e10a5
Merge branch 'wip/chergert/inline-transform-category' into 'master'
...
gsk: move transform structure to private.h
See merge request GNOME/gtk!3182
2021-02-11 01:14:21 +00:00
Matthias Clasen
82ab039abe
Merge branch 'disable-macos-ci' into 'master'
...
ci: Temporarily disable macOS CI job as runner is offline
See merge request GNOME/gtk!3183
2021-02-11 01:14:01 +00:00
Matthias Clasen
e823fa6665
Merge branch 'fix-filter-value' into 'master'
...
css: Avoid an invalid read
See merge request GNOME/gtk!3181
2021-02-11 00:51:40 +00:00
Matthias Clasen
8cd4b338db
ci: Temporarily disable macOS CI job as runner is offline
...
See https://gitlab.gnome.org/Infrastructure/GitLab/-/issues/495
2021-02-10 19:50:17 -05:00
Matthias Clasen
9af30aca35
Merge branch 'wip/chergert/fix-unused' into 'master'
...
snapshot: fix warning when asserts are disabled
See merge request GNOME/gtk!3180
2021-02-11 00:47:08 +00:00
Christian Hergert
6fab195643
gsk: move transform structure to private.h
...
This allows using the category without having to call a function from the
hot paths of the renderer.
2021-02-10 16:14:59 -08:00
Christian Hergert
c90ffc7363
snapshot: fix warning when asserts are disabled
2021-02-10 16:13:38 -08:00
Matthias Clasen
3eb4ec89f3
css: Avoid an invalid read
...
This was broken in ea7185bdb1 .
Pointed out by Christian Hergert.
2021-02-10 19:13:36 -05:00
Matthias Clasen
6c85a4b2f5
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
See merge request GNOME/gtk!3177
2021-02-10 13:55:50 +00:00
Matthias Clasen
befc2c3ed6
iconbrowser: Use the right icon
...
We have an app icon, lets use it.
2021-02-10 08:04:11 -05:00
Matthias Clasen
62788d5b0d
print-editor: Use the non-devel icon
...
We are no longer a nightly print editor.
2021-02-10 07:52:29 -05:00
Matthias Clasen
3c91a2b0a8
node-editor: Use the non-devel icon
...
We're now a respectable, stable node editor.
2021-02-10 07:44:59 -05:00
Matthias Clasen
d3096f079f
Merge branch 'fix-clipped-texture' into 'master'
...
gl: Fixed clipped offscreen rendering
Closes #3651
See merge request GNOME/gtk!3175
2021-02-10 05:15:14 +00:00
Matthias Clasen
dff2aa20ff
gl: Fixed clipped offscreen rendering
...
When we are rendering a texture node to an offscreen,
and we have a clip, we must force the offscreen rendering.
Otherwise, the code will notice: Hey, it already is a texture
node, so no need to render it to a texture again. But when
clipping is involved, that is exactly what we want to do.
Testcase included.
Fixes : #3651
2021-02-09 22:43:15 -05:00
Matthias Clasen
dae42c8f55
Merge branch 'wip/chergert/fix-maximized-shadows' into 'master'
...
adwaita: disable shadows when window is maximized or fullscreen
See merge request GNOME/gtk!3173
2021-02-09 23:16:49 +00:00
Jakub Steiner
da64856f37
Adwaita: don't cast shadows for halt-tiled windows
...
- while the case of a single half tiled window casting shadow is valid,
the main use case for half tiled windows is when they have a neighbor.
The :backdrop should be enough of a focus indicator and we avoid shadow
casting on neighbors that are on the same Z level.
2021-02-09 18:57:31 +01:00
Christian Hergert
461fe36707
adwaita: disable shadows when window is maximized or fullscreen
...
These shadows cause a significant draw performance drop for maximized
windows. Disabling them increases the chances we can have faster scroll
performance of text.
There is some risk here for systems where they have a dock and you expect
the shadow to draw beneath that dock for transparency reasons.
2021-02-09 09:27:22 -08:00
Matthias Clasen
4ce071721f
Merge branch 'win32-drop-formats-leak' into 'master'
...
win32: Fix some leaks
See merge request GNOME/gtk!3167
2021-02-09 12:27:35 +00:00
Matthias Clasen
3cdfb779c7
Merge branch 'wip/chergert/fix-bgr8-uploads' into 'master'
...
gl: handle B8G8R8 texture data when uploading
See merge request GNOME/gtk!3171
2021-02-09 12:11:49 +00:00
Christian Hergert
3a43663630
gl: handle B8G8R8 texture data when uploading
...
We do not need to translate this on the CPU when we can instead push it
to the GPU in the same format and allow it to swizzle.
This fixes a huge number of memory allocations found while uploading the
GTK animation in widget-factory.
2021-02-08 15:32:12 -08:00
Matthias Clasen
360a66e945
Merge branch 'wip/chergert/macos-perf-fixes' into 'master'
...
macos: various OpenGL performance fixes
See merge request GNOME/gtk!3170
2021-02-08 20:30:27 +00:00
Christian Hergert
13e162c404
macos: improve use of swap rectangles with OpenGL
2021-02-08 11:30:11 -08:00
Christian Hergert
65296228d7
macos: only flush when not attached
...
This makes it so we only flush the context for the NSView, not the context
that is the center of our center of the GL context spokes.
2021-02-08 11:30:05 -08:00
Christian Hergert
443d199868
macos: mark region as unlikely
2021-02-08 11:29:56 -08:00
Christian Hergert
86c5f2df6e
gsk: make gsk_render_node_get_node_type() use const
...
There isn't any state to modify in the type so we can use const here.
Doing so allows some of the renderer code to use const across a
number of functions so that repeated calls are elided if inlined.
2021-02-08 11:29:43 -08:00
Christian Hergert
09b447a9e1
gsk: make render node getters pure
...
These do not do modify anything so they can be marked as pure to
potentially ellide calls. Since they do dereference, I do not believe
we can make them const although that is unclear since we could technically
just return a pointer + offset. Therefore it *might* be possible to also
make these G_GNUC_CONST.
2021-02-08 11:29:39 -08:00
Christian Hergert
161ddcfa92
gsk: make render node getters const
...
This also removes the return if fail macros from these as a good portion
of them didn't have them anyway. I think it's fair to say that access to
these incorrectly is a programmer error.
It significantly reduces the amount of code generated into generally a
movss,ret.
2021-02-08 11:29:36 -08:00
Christian Hergert
226dc49602
profiler: allow using gdk profiler functions without braces
...
Just compiling these out means you have to write code slightly differently
so that you don't end up with "if ();" afterwards.
This adds a "do {} while (0)" so that we're still semantically a statement
but will also compile out.
2021-02-08 11:29:32 -08:00
Matthias Clasen
207569c4ed
Merge branch 'wip/exalm/headerbar' into 'master'
...
headerbar: Don't use gtk_widget_unparent() with GtkBox
See merge request GNOME/gtk!3169
2021-02-08 15:38:48 +00:00
Alexander Mikhaylenko
cf61d96188
headerbar: Null-check boxes when removing window controls
...
Prevent a crash when show-title-buttons value changes to FALSE during
destruction.
2021-02-08 18:46:35 +05:00
Alexander Mikhaylenko
319755662f
headerbar: Don't use gtk_widget_unparent() with GtkBox
...
gtk_widget_unparent() is for widget implementations, it's not supposed to
be used from outside.
2021-02-08 18:46:27 +05:00
Matthias Clasen
055cd9aaad
Merge branch 'printing-temporary-queues-gtk4' into 'master'
...
printing: Create temporary queues for Avahi printers
See merge request GNOME/gtk!3160
2021-02-07 16:13:46 +00:00
Matthias Clasen
15697d5c0c
Merge branch 'focus' into 'master'
...
listbox: Fix handling of non-focusable rows
Closes #3633
See merge request GNOME/gtk!3152
2021-02-07 15:57:11 +00:00
Matthias Clasen
0cd2d01f3f
Merge branch 'fix-x11-drop' into 'master'
...
x11: More dnd fixes
Closes #3654
See merge request GNOME/gtk!3166
2021-02-07 14:52:24 +00:00
Matthias Clasen
67877e403f
win32: Fix some leaks
...
My reading of the code is that gdk_drop_new() is not
consuming the content formats it is given, so the caller
must not pass a new reference.
Needs testing on Windows.
2021-02-07 09:41:34 -05:00
Matthias Clasen
0bce63e3ab
x11: More dnd fixes
...
Whenever we communicate targets, we need to the union, otherwise
we don't tell the other side about our serialization. This makes
drops of images from gtk4-icon-browser to gimp and libreoffice
succeed in transferring data.
Fixes : #3654
2021-02-07 09:03:22 -05:00
Matthias Clasen
6396bf6d89
Merge branch 'fix-x11-drop' into 'master'
...
Fix x11 drop
Closes #3652
See merge request GNOME/gtk!3165
2021-02-07 06:52:45 +00:00
Matthias Clasen
5b45f267d6
x11: Pass mimetypes when creating output stream
...
When creating the output stream for a drop, we must
pass the mimetypes we support, otherwise the picking
of the right handler does not work.
Fixes : #3652
2021-02-07 01:32:39 -05:00
Matthias Clasen
f26f15fced
x11: Fix a memory leak
...
We ref the content formats here, so we better unref it
when done.
2021-02-07 01:31:40 -05:00
Matthias Clasen
a37044f36c
x11: Some code cleanups
...
Fix some glaring misindentation.
2021-02-07 01:30:50 -05:00
Matthias Clasen
e8c8be8e37
Merge branch 'matthiasc/for-master' into 'master'
...
Implement drop-shadow css filter
See merge request GNOME/gtk!3163
2021-02-06 22:35:23 +00:00
Matthias Clasen
bfc80c32ea
Add tests for the css filter property
...
Test that we can parse filters and that we
don't accept invalid filters.
2021-02-06 16:16:44 -05:00
Matthias Clasen
5f48764ac8
cssfiltervalue: Reject invalid filters
...
The Filter Effects Spec doesn't allow negative values
for most of the filter parameters.
2021-02-06 16:16:44 -05:00
Matthias Clasen
cc6fcbfc09
cssfiltervalue: Fix blur filter interpretation
...
According to https://www.w3.org/TR/filter-effects-1/ ,
the length passed to blur() is the standard deviation,
and according to https://www.w3.org/TR/css-backgrounds-3/#shadow-blur
the blur radius is twice the standard deviation.
2021-02-06 16:16:44 -05:00
Matthias Clasen
ea7185bdb1
cssfiltervalue: Implement drop-shadows
...
We have all the pieces, so this is surprisingly easy.
2021-02-06 16:16:43 -05:00
Matthias Clasen
429dfcf483
cssshadowvalue: Add a 'filter mode'
...
Shadow values created by gtk_css_shadow_value_new_filter or
gtk_css_shadow_value_parse_filter interpret their radius value
as standard deviation. Add a flag for this mode, and use it
where necessary.
2021-02-06 16:10:34 -05:00
Matthias Clasen
be3f352b59
cssshadowvalue: Add a parsing function
...
Add a variant of the parse function that parses
just a single (non-box) shadow, as required for
the drop-shadow filter.
2021-02-06 16:10:32 -05:00
Matthias Clasen
5b8896f1db
cssshadowvalue: Add gtk_css_shadow_value_pop_snapshot
...
This is the counterpart ot gtk_css_shadow_value_push_snapshot.
To make this easy, move the determination whether we need a
shadow out of the push function and save it.
2021-02-06 16:09:21 -05:00
Matthias Clasen
4e27de7df9
cssshadowvalue: Drop the underscore
...
Rename _gtk_css_shadow_value_parse to drop the underscore.
It was the only underscore-prefixed function in this file.
2021-02-06 16:08:19 -05:00
Marek Černocký
2712f536c2
Updated Czech translation
2021-02-06 09:44:09 +01:00
Matthias Clasen
a1f7073ff5
Add tests for the css filter property
...
Test that we can parse filters.
2021-02-05 21:37:47 -05:00
Matthias Clasen
9770872d12
css: Implement the drop-shadow filter
...
We have all the pieces, so this is surprisingly easy.
2021-02-05 21:37:14 -05:00
Matthias Clasen
de24b4f91b
cssshadowvalue: Add a parsing function
...
Add a variant of the parse function that parses
just a single (non-box) shadow, as required for
the drop-shadow filter.
2021-02-05 21:36:22 -05:00
Matthias Clasen
650fd9c291
Merge branch 'module-ext' into 'master'
...
meson: use correct module file extension on macOS
Closes #3645
See merge request GNOME/gtk!3162
2021-02-06 01:15:09 +00:00
David Lechner
b509809f34
meson: use correct module file extension on macOS
...
GModule requires the .so file extension on macOS for historic reasons.
However Meson defaults to .dylib for modules, so we need to override
it to get the correct extension.
Fixes #3645 .
2021-02-05 16:54:28 -06:00
Marek Kasik
a93ab37ea9
printing: Show all Avahi advertised printers
...
This commit unsubscribes CUPS backend from a DBus
signal in idle when listening for new items on Avahi.
Since GDBus emits gathered signals in idle while
checking whether the signal has been unsubscribed
it could happen that a signal was not processed
because it was removed from hash table of
subscribed signals.
This caused the situation where printers advertised
on Avahi were not listed in CUPS backend sometimes.
We need those signals since this happens when switching
from a general subscription which listens to signals
for all Avahi services to a specific one which listens
to just _ipp._tcp and _ipps._tcp (chicken and egg problem).
2021-02-05 18:35:56 +01:00
Marek Kasik
5d7364960a
printing: Create temporary queues for Avahi printers
...
This change extends set of Avahi advertised printers which
works with Gtk's CUPS print backend.
It creates a temporary queue (local printer) for each
Avahi printer in CUPS instead of accessing them directly
(via CUPS library).
This makes some printers work which did not work before and
also gives users more options to change in the print dialog.
This also changes naming of printers to be in accordance with CUPS.
It uses '_' instead of '-' and has hostname appended for CUPS remote
printers.
2021-02-05 18:35:56 +01:00
Matthias Clasen
60ff231fac
Merge branch 'matthiasc/for-master' into 'master'
...
iconbrowser: Make image dnd work again
Closes #3648
See merge request GNOME/gtk!3159
2021-02-05 12:48:10 +00:00
Emmanuele Bassi
958005317b
Merge branch 'master' into 'master'
...
Improve the docs of GtkWidget and GtkGrid
See merge request GNOME/gtk!2946
2021-02-05 12:14:26 +00:00
Matthias Clasen
15c36aaa1e
iconbrowser: Make image dnd work again
...
We need to drag a texture, not a paintable.
Fixes : #3648
2021-02-04 20:47:19 -05:00
Matthias Clasen
482b73c376
Merge branch 'matthiasc/for-master' into 'master'
...
docs: Rewrite the long description for GtkDialog
Closes #3646
See merge request GNOME/gtk!3156
2021-02-05 00:10:47 +00:00
Matthias Clasen
4a8bf6e13d
Merge branch 'doc-typo' into 'master'
...
gtkshow: Fix doc typo
See merge request GNOME/gtk!3158
2021-02-05 00:07:18 +00:00
Maximiliano Sandoval R
3e2e6633b0
gtkshow: Fix doc typo
2021-02-04 21:02:22 +01:00
Matthias Clasen
4724f9907c
docs: Rewrite the long description for GtkDialog
...
As was pointed out in #3646 , some of the content here
was a bit outdated.
Fixes : #3646
2021-02-04 13:05:28 -05:00
Matthias Clasen
26e84a7b8c
Merge branch 'matthiasc/for-master' into 'master'
...
More work on css transition tests
See merge request GNOME/gtk!3154
2021-02-04 13:28:59 +00:00
Matthias Clasen
d5838f14f9
Drop the installed test for now
...
It fails in ci, and I have no idea why.
2021-02-04 07:26:10 -05:00
Matthias Clasen
5c532104e4
Merge branch 'pvs-fixes' into 'master'
...
Pvs fixes
See merge request GNOME/gtk!3155
2021-02-04 12:20:24 +00:00
Matthias Clasen
2f42e1fb89
treemodelfilter: Drop unreachable code
...
We never get here. The compiler says so.
Pointed out in https://www.viva64.com/en/b/0793/
2021-02-04 00:40:14 -05:00
Matthias Clasen
b5200bd076
css: Drop a bit of unreachable code
...
We never get here. The compiler says so.
Pointed out in https://www.viva64.com/en/b/0793/
2021-02-04 00:39:34 -05:00
Matthias Clasen
aa5bd38137
a11y: Avoid out-of-bounds access
...
Don't use the index before we've checked its good.
Pointed out in https://www.viva64.com/en/b/0793/
2021-02-04 00:34:05 -05:00
Matthias Clasen
0eba833595
gdk: Remove a redundant check
...
We already know desktop_notification_id is not NULL.
Pointed out in https://www.viva64.com/en/b/0793/
2021-02-04 00:29:51 -05:00
Matthias Clasen
1e0ea21297
messagedialog: Don't initialize twice
...
We don't need to set these fields more than once.
Pointed out in https://www.viva64.com/en/b/0793/
2021-02-04 00:25:36 -05:00
Matthias Clasen
e91e75173d
composetable: Remove a redundant check
...
We already know seq_index is not NULL here.
Pointed out in https://www.viva64.com/en/b/0793/
2021-02-04 00:22:52 -05:00
Matthias Clasen
927fdb9a83
x11: A case of argument order confusion
...
translate_keysym was expecting its arguments the
other way around.
Pointed out in https://www.viva64.com/en/b/0793/
2021-02-04 00:20:26 -05:00
Matthias Clasen
041f410838
textbtree: Avoid line vs char count confusion
...
The post_insert_fixup helper function was confused about
its argument order.
Pointed out in https://www.viva64.com/en/b/0793/
2021-02-04 00:17:55 -05:00
Matthias Clasen
c71c8919fe
listbase: Don't specify the same thing twice
...
We only need to set EXPLICIT_NOTIFY once.
Pointed out in https://www.viva64.com/en/b/0793/
2021-02-04 00:13:53 -05:00
Matthias Clasen
3f28399f7d
css: Fix border value parsing
...
This function was not resetting computed as it meant
to because the last loop was never executed.
Pointed out in https://www.viva64.com/en/b/0793/
2021-02-04 00:12:51 -05:00
Matthias Clasen
3c15fa96bc
vulkan: Fix image uploading by regions
...
This code did not make sense; it was incrementing
the wrong variable.
Pointed out in https://www.viva64.com/en/b/0793/
2021-02-04 00:12:44 -05:00
Matthias Clasen
0a0a059397
docs: Mention css drop-shadow filter
...
We don't support this filter, currently.
2021-02-03 22:10:13 -05:00
Matthias Clasen
18e83fe16d
Add more css transition tests
2021-02-03 22:10:13 -05:00
Matthias Clasen
90d7ed5dd1
Rename test to transition
...
Thats what it is about, so name it clearly.
Add missing installed tests too.
2021-02-03 22:10:13 -05:00
Matthias Clasen
3c6e7569ff
Add more css transition tests
...
Test font size transitions.
2021-02-03 22:10:13 -05:00
Matthias Clasen
4e2ec2d68d
testsuite: Pass GDK_DEBUG=default-settings to css tests
...
Otherwise, settings might creep in and change css defaults.
2021-02-03 22:10:13 -05:00
Matthias Clasen
1af72eac21
cssvalue: Cosmetic change
...
Don't return FALSE from pointer-returning functions.
2021-02-03 22:10:13 -05:00
Matthias Clasen
640273a0e2
Improve the css value tests
...
The test code had some bugs. Fix those, and
print out useful information when tests fail.
2021-02-03 22:10:13 -05:00
Matthias Clasen
a14a0c6315
css: Fix shadow value equal
...
This function was not doing the right thing.
Once we are doing the right thing and not compare
shadows as unequal, some reftests that inhibit
snapshots for a few frames now hang forever, since
we are no more redrawing unnecessarily. Fix that
with an explicit queue_draw.
2021-02-03 22:10:13 -05:00
Matthias Clasen
38481680e1
Merge branch 'wip/jimmac/colored-list-image-buttons' into 'master'
...
Adwaita: allow suggested and destructive action buttons in lists
Closes #3643
See merge request GNOME/gtk!3153
2021-02-04 01:38:47 +00:00
Matthias Clasen
12a540c284
Merge branch 'ebassi/for-master' into 'master'
...
Graphene is a dependency of Gsk, not Gdk
See merge request GNOME/gtk!3149
2021-02-04 01:38:09 +00:00
Jakub Steiner
289bf078bf
Adwaita: allow suggested and destructive action buttons in lists
...
Fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/3643
2021-02-03 23:15:30 +01:00
Elias Projahn
a7ae94c06e
listbox: Fix handling of non-focusable rows
...
This commit modifies the gtk_list_box_row_grab_focus() implementation to
correctly return FALSE in case the row couldn't be focused. This behavior will
also be honored by gtk_list_box_row_focus() to properly handle focus in that
case. To achieve that, the method has been restructured slightly.
Closes #3633
2021-02-03 21:22:55 +01:00
Matthias Clasen
58ab9ddc40
Merge branch 'x11-dnd-fix' into 'master'
...
x11: Handle X-specific targets in drops
Closes #3642
See merge request GNOME/gtk!3151
2021-02-03 20:11:33 +00:00
Matthias Clasen
c78036fc51
x11: Handle X-specific targets in drops
...
This code is very similar to the handling for these
targets in the clipboard case.
Fixes : #3642
2021-02-03 14:17:04 -05:00
Matthias Clasen
120f2768e6
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
See merge request GNOME/gtk!3150
2021-02-03 15:17:34 +00:00
Emmanuele Bassi
592b33cb48
Graphene is a dependency of Gsk, not Gdk
...
So let's put it in the right place when building the introspection data.
2021-02-03 14:05:27 +00:00
Matthias Clasen
7a9bc1f1d8
Link the data url tests statically
...
Thats the cleaner way to test internal apis.
2021-02-03 09:02:06 -05:00
Matthias Clasen
9cc6f3ee29
Add tests for css value transitions
...
Just a few cases for now, enough to test a recently
fixed regression with shadow transitions.
2021-02-03 08:56:57 -05:00
Chun-wei Fan
9efaa0b51d
Merge branch 'uac.meson.master' into 'master'
...
gtk4-update-icon-cache: Avoid UAC on 32-bit Windows
Closes #3632
See merge request GNOME/gtk!3141
2021-02-03 02:16:58 +00:00
Chun-wei Fan
f0967fa5e4
gtk4-update-icon-cache: Avoid UAC on 32-bit Windows
...
As the program executable name has 'update' in its filename,
gtk4-update-icon-cache.exe is considered to be an installer program on 32-bit
Windows [1], which will cause the program to fail to run unless it is running
with elevated privileges (i.e. UAC).
Avoid this situation by embedding a manifest file into the final executable
that tells Windows that this is not a program that requires elevation.
Fixes issue #3632 .
[1]: https://docs.microsoft.com/en-us/previous-versions/windows/it-pro/windows-vista/cc709628(v=ws.10)?redirectedfrom=MSDN ,
under section "Installer Detection Technology"
2021-02-03 02:16:58 +00:00
Matthias Clasen
f8529983f9
Merge branch 'matthiasc/for-master' into 'master'
...
css: Allow transitioning different-size shadows
See merge request GNOME/gtk!3145
2021-02-03 00:43:44 +00:00
Matthias Clasen
919c08d4fd
css: Allow transitioning different-size shadows
...
The code handles it just fine. The length check was
an erronous addition.
2021-02-02 15:27:42 -05:00
Matthias Clasen
e9b06b6346
Merge branch 'im-context-work' into 'master'
...
Some im context work
Closes #1004 , #186 , and #3521
See merge request GNOME/gtk!3143
2021-02-02 17:29:14 +00:00
Matthias Clasen
949c783187
composetable: Parse hex escapes too
...
This was a small omission from the Compose file
syntax that doesn't cost us much to support.
Add a test for this syntax too.
Fixes : #1004
2021-02-02 12:05:19 -05:00
Matthias Clasen
814a4a781a
Add tests for string values
...
Add a test that checks we parse values with
multiple characters correctly.
2021-02-02 11:55:00 -05:00
Matthias Clasen
676f875bf6
composetable: Support string values in the cache
...
Change the cache format to include the character
data that we need to hold string values in the table.
2021-02-02 11:55:00 -05:00
Matthias Clasen
140c5c5333
composetable: Don't use GSlice for big blobs
...
This just doesn't make sense. This will use malloc
anyway, so just call malloc directly.
2021-02-02 11:55:00 -05:00
Matthias Clasen
cebf2b2009
composetable: Keep multi-char values
...
Keep string values in the table, and return them
from the check function. This commit temporarily
disables the table caching, since the cache format
does not handle string values yet.
Fixes : #186
2021-02-02 11:54:53 -05:00
Matthias Clasen
86b437a1b6
Merge branch 'wip/silence-bounds-warnings' into 'master'
...
gdk/toplevelsize: Remove warnings about exceeding bounds
Closes #3035
See merge request GNOME/gtk!3142
2021-02-02 16:38:20 +00:00
Matthias Clasen
773ae0cd0f
composetable: Parse multi-char values
...
Rewrite the value parsing function to accept strings
that hold more than a single Unicode character.
2021-02-02 09:03:53 -05:00
Matthias Clasen
564793d5b5
composetable: Another step towards multi-char values
...
Change the parser data structures to hold a string, rather
than a gunichar. We still only put a single Unicode character
into it, currently.
2021-02-02 09:02:46 -05:00
Matthias Clasen
9142aa0f51
composetable: Prepare for multi character values
...
Make it possible for gtk_compose_table_check to return
a string instead of just a single Unicode character.
Currently, we only ever return strings holding a single
character, still.
2021-02-02 09:02:00 -05:00
Chun-wei Fan
39e136e9b7
Gdk/Win32: Fix resizing surfaces
...
This attempts to fix the counter-intuitive resizing of surfaces in GTK4 where
the surface grows or shrinks at the right and/or bottom edge when the window
resized from the top and/or left edge(s).
This is not yet perfect as the window stutters upon resizing from the top
and/or left edges, but at least makes resizing more intuitive.
2021-02-02 17:36:32 +08:00
Chun-wei Fan
652b892fc1
gdkwin32surface.[c|h]: Clean up code a bit
...
Remove the 'resized' member from the GdkWin32Surface structure, as we already
have a structure with a member that keeps track of whether a surface is being
resized, so we can just use that and avoid some confusion in the process
2021-02-02 17:36:32 +08:00
Matthias Clasen
af9a578d68
imcontext: Prepare for multi-char values
...
Reshuffle things so we can easily handle values
that are strings instead of just single Unicode
characters.
2021-02-01 23:43:59 -05:00
Matthias Clasen
ecb072fdd0
composetable: Check algorithmic matching
...
Just some spot checks, enough to verify the
fix in the previous commit.
2021-02-01 21:59:21 -05:00
Matthias Clasen
ef053ebb4a
composetable: Fix algorithmic matching
...
The code wasn't paying attention to (lack of) nul-termination
in one place, causing it to not match when it should.
2021-02-01 21:51:51 -05:00
Matthias Clasen
8d18d93742
composetable: Add tests for compact table matching
...
Not very exhaustive, just some spot checks.
2021-02-01 21:10:44 -05:00
Matthias Clasen
10fcdd88e3
imcontext: Code cleanup
...
Get rid of auxiliary check_table function.
2021-02-01 20:41:45 -05:00
Matthias Clasen
5d9509c51b
imcontext: Move code around
...
Move all the checking code to gtkcomposetable.c, and
add api that we can use in tests.
2021-02-01 20:27:38 -05:00
Matthias Clasen
c9cac5fbc3
composetable: Add tests for matching
...
This tests the api we use to match key sequences
against compose tables.
2021-02-01 19:55:56 -05:00
Matthias Clasen
aa9054a5f1
imcontext: Use gtk_compose_table_check
...
Use the just-introduced api.
2021-02-01 19:41:07 -05:00
Matthias Clasen
9ebf3fac73
composetable: Add api to check tables
...
This copies the check_table code from gtkimcontextsimple.c,
in order to have an api for tests.
2021-02-01 19:40:22 -05:00
Matthias Clasen
569294070b
Add tests for GtkComposeTable
...
Add some tests for the code that parses Compose files.
This tests the fix in the previous commit.
2021-02-01 19:02:31 -05:00
Matthias Clasen
be35c46ce9
composetable: Drop table debug code
...
This is better off in the tests that we are going to add.
2021-02-01 19:02:21 -05:00
Matthias Clasen
dbbcb13721
composetable: Parser fixes
...
We were not handling octal escapes right.
2021-02-01 16:05:05 -05:00
Matthias Clasen
edeaf9c040
imcontext: Drop GTK_MAX_COMPOSE_LEN
...
Drop GTK_MAX_COMPOSE_LEN from docs. It is no longer
used by GTK at all. We leave the define in place
for now, to avoid breaking 3rd party code that might
use it.
2021-02-01 12:31:23 -05:00
Matthias Clasen
61f709811c
composetable: Warn when ignoring things
...
We should at least give a hint that we've seen the line,
otherwise people will wonder why nothing happened.
2021-02-01 12:27:41 -05:00
Matthias Clasen
f7c4375509
composetable: parse long sequences
...
Allow compose sequences of up to 20 code points.
Fixes : #3521
2021-02-01 12:27:35 -05:00
Matthias Clasen
52fb900ced
composetable: Fix an off-by-one
...
Fix an off-by-one in the code parsing octal escapes
in compose files.
2021-02-01 12:10:05 -05:00
Matthias Clasen
031944ad30
imcontext: Stop using GTK_MAX_COMPOSE_LEN
...
Allocate the compose_buffer, and resize it when needed
to match the tables we use.
2021-02-01 12:10:05 -05:00
Matthias Clasen
bf8b974f68
imcontext: Code cleanup
...
Use g_clear_pointer instead of opencoding it in
multiple places.
2021-02-01 12:10:05 -05:00
Jonas Ådahl
6ad2a049e7
gdk/toplevelsize: Remove warnings about exceeding bounds
...
Sometimes the size will exceed the minimum bounds. For example crazy
applications like the widget factory that contains the world, or when a
user interactively resizes a window to be larger than the monitor the
window is on is.
The former is questionable, but the latter is not, and from here we
can't really see the difference, so just stop complaining.
Closes: https://gitlab.gnome.org/GNOME/gtk/-/issues/3035
2021-02-01 11:31:11 +01:00
Matthias Clasen
3d85d53e5d
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
Closes #2319
See merge request GNOME/gtk!3140
2021-02-01 06:20:40 +00:00
Matthias Clasen
094a346539
imcontext: Allow sequences of length GTK_MAX_COMPOSE_LEN
...
There was an off-by-one error, making us reject sequences
of this length. But the rest of the code handles them
just fine.
Fixes : #2319
2021-02-01 00:55:25 -05:00
Matthias Clasen
162814f969
imcontext: Improve an error message
...
This error message was misleading, as pointed out
by Ralf Jung.
2021-02-01 00:44:41 -05:00
Matthias Clasen
e39b5c99f1
imcontext: Add a precondition check
2021-02-01 00:43:44 -05:00
Matthias Clasen
8883243aaa
imcontext: Show preedit for compose sequences
...
Show the sequences as they are entered, using ⎄ for
the compose key, to match what IBus does nowadays.
Also handle backspace to allow corrections.
2021-02-01 00:37:43 -05:00
Matthias Clasen
89511eecf1
imcontext: Update our check for dead keys
...
A bunch of keysyms for dead keys have been added since this
code was last touched. Update the check to cover the full
range from dead_grave to dead_greek.
2021-01-31 23:56:24 -05:00
Matthias Clasen
2c304ca80d
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
See merge request GNOME/gtk!3139
2021-02-01 01:48:47 +00:00
Matthias Clasen
bf4102e664
Merge branch 'wip/exalm/consumes-motion' into 'master'
...
Drag fixes and cleanups
Closes #3513
See merge request GNOME/gtk!3001
2021-02-01 01:34:45 +00:00
Matthias Clasen
b86153cee3
Remove a forgotten file
...
The example series only has 9 steps now. Remove remnants
of step 10.
2021-01-31 20:26:02 -05:00
Matthias Clasen
7985d277b3
nativedialog: Add more docs
...
Emphasize that native dialogs aren't widgets, and are not
kept alive by GTK.
2021-01-31 20:25:44 -05:00
Matthias Clasen
752da5c2a5
Merge branch 'tool-static' into 'master'
...
tools: Don't static and dynamic link on libgtk4
See merge request GNOME/gtk!3138
2021-02-01 00:44:08 +00:00
Matthias Clasen
de4b8d547b
Merge branch 'wip/exalm/activate' into 'master'
...
listitemwidget: Activate on release instead of press
Closes #3345
See merge request GNOME/gtk!3008
2021-02-01 00:32:05 +00:00
Xavier Claessens
1048ad1a01
tools: Don't static and dynamic link on libgtk4
2021-01-31 11:09:20 -05:00
Ungedummt
4d11158d97
GtkGrid: Add xml example for GtkBuildable to docs
...
Added an example and a short discription for the properties
2021-01-31 10:19:14 +01:00
Ungedummt
293b81cad2
Fix small typo in the docs of GtkWidget
...
In a XML example was MyGrid as a class defined; replaced with GtkGrid
2021-01-31 10:19:08 +01:00
Matthias Clasen
65c38111f9
4.1.0
2021-01-30 19:57:24 -05:00
Matthias Clasen
ec8db379a6
tests: Disable the textview-margins reftest
...
It is too flaky to be useful.
2021-01-30 19:57:24 -05:00
Matthias Clasen
1484b4ae9f
node editor: Add a dark mode toggle
...
This is useful to see light rendering clearly.
2021-01-30 19:57:24 -05:00
Rafael Fontenelle
4cecbf1654
Update Brazilian Portuguese translation
...
(cherry picked from commit 056c3e11a1 )
2021-01-30 19:16:02 +00:00
Timm Bäder
234ba90e2b
Merge branch 'mcclurgm-master-patch-63249' into 'master'
...
Document nullability of gtk_list_box_get_selected_row
See merge request GNOME/gtk!3137
2021-01-30 17:58:33 +00:00
Rafael Fontenelle
bdd2244f75
Update Brazilian Portuguese translation
...
(cherry picked from commit f224c8fab9 )
2021-01-30 16:00:45 +00:00
Michael McClurg
cd7ec8ac92
Document nullability of gtk_list_box_get_selected_row
2021-01-30 15:23:41 +00:00
Piotr Drąg
cc5edbbbb2
Update POTFILES.in
2021-01-30 14:21:32 +01:00
Matthias Clasen
94d9e34dd3
Merge branch 'fix-unfocus-on-unmap' into 'master'
...
Fix unsetting focus
Closes #3623
See merge request GNOME/gtk!3136
2021-01-30 03:25:19 +00:00
Matthias Clasen
3dbf5038fa
Fix unsetting focus
...
Make _gtk_window_unset_focus_and_default queue the changes
for after the next draw. This achieves two things: first,
it avoids invalidating css at the wrong time (e.g. when
setting child-visible during size-allocation), and second,
it defers the focus change until after the widget is
hidden, so that moving the focus has the desired effect
of picking a different, visible widget.
Fixes : #3623
2021-01-29 21:41:16 -05:00
Matthias Clasen
456a2f3bcf
Merge branch 'msvc.nounistd' into 'master'
...
testsuite/testutils.c: Fix build on Visual Studio
See merge request GNOME/gtk!3131
2021-01-29 20:16:13 +00:00
Matthias Clasen
8e1fa52d14
Merge branch 'gst-vaapi-fix' into 'master'
...
gtkgstsink: Sync texture before handing it to GDK
See merge request GNOME/gtk!3114
2021-01-29 19:06:03 +00:00
Matthias Clasen
cbf2feb633
Merge branch 'ci-gstreamer-deps' into 'master'
...
Ci gstreamer deps
See merge request GNOME/gtk!3133
2021-01-29 19:05:47 +00:00
Matthias Clasen
afe8ee501c
Merge branch 'ebassi/for-master' into 'master'
...
Ebassi/for master
See merge request GNOME/gtk!3134
2021-01-29 18:47:31 +00:00
Jan Alexander Steffens (heftig)
4644dab081
gtkgstsink: Sync texture before handing it to GDK
...
We need to synchronize when moving the texture between contexts, or we
get glitches with VA-API decoding.
2021-01-29 18:58:17 +01:00
Matthias Clasen
b37a69d76c
ci: Add mesa-libGLES-devel
...
Try again, since libglvnd-devel is not the right choice.
2021-01-29 12:55:46 -05:00
Emmanuele Bassi
51bc6ce2e4
build: Disable subproject Cairo tests
...
There's really no point in running them.
2021-01-29 16:31:10 +00:00
Emmanuele Bassi
988ebc2248
docs: Annotate XML fragments as such
...
This way we can get syntax highlighting.
2021-01-29 16:31:10 +00:00
Emmanuele Bassi
9f31e95420
docs: Escape bare tags
...
Otherwise tools processing the description of GtkWidget will be *very*
confused.
2021-01-29 16:31:10 +00:00
Emmanuele Bassi
3a076e26f7
docs: Use the appropriate syntax for code block language
2021-01-29 16:31:09 +00:00
Emmanuele Bassi
e3e85fc6f3
docs: Remove stray code block end marker
2021-01-29 16:31:09 +00:00
Jonas Ådahl
ad3a35b4c5
Merge branch 'gtk-surface-release-4' into 'master'
...
wayland: Signal gtk-shell surface destruction to the server
See merge request GNOME/gtk!3129
2021-01-29 16:21:05 +00:00
Matthias Clasen
454caa3eec
ci: Use v26 of the Fedora image
...
This includes libglvnd-devel and should fix using the
gstreamer gl support.
2021-01-29 11:14:54 -05:00
Matthias Clasen
0ffe67ffed
ci: Add libglvnd-devel to images
...
gstreamers gl support included headers from this
package without depending on it. Work around this
packaging error by explicitly adding the needed
dependencies.
2021-01-29 11:07:11 -05:00
Matthias Clasen
8eb46bbfb2
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
Closes #3615
See merge request GNOME/gtk!3132
2021-01-29 15:15:43 +00:00
Chun-wei Fan
d8e8b3c235
testsuite/testutils.c: Fix build on Visual Studio
...
Visual Studio does not come with unistd.h, but Windows do have write() and
close() in io.h, so include io.h instead of unistd.h on Windows.
For MinGW, unistd.h in turn includes io.h.
2021-01-29 17:59:10 +08:00
Timm Bäder
79f273348d
gl renderer: Fix viewport computation when rendering offscreen
...
Fixes #3615
2021-01-29 10:37:48 +01:00
Timm Bäder
fc99081658
showrendernode: Monitor input file
2021-01-29 09:45:25 +01:00
Timm Bäder
aba14e6a43
node editor: Show some default node data
...
Show case the icon and the render node format this way.
2021-01-29 09:45:25 +01:00
Timm Bäder
8ebcef97ff
shader builder: Improve error output
2021-01-29 09:45:25 +01:00
Timm Bäder
00956a3770
node editor: Make help textview monospace
...
Otherwise the nice markdown tables don't line up.
2021-01-29 08:07:39 +01:00
Alexander Mikhaylenko
11f3b7730c
windowhandle: Use drag threshold instead of double click threshold
...
Now that we have gtk_drag_check_threshold_double(), be consistent with
other draggable widgets and make sure we don't take over a drag before a
child does.
Fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/3513
2021-01-29 12:01:34 +05:00
Alexander Mikhaylenko
f63e6394ac
dragsource: Use double coordinates for checking drag threshold
...
If multiple nested widgets have drag sources on them, both using bubble
phase, we need to reliably pick the inner one. Both of them will try to
start dragging, and we need to make sure there are no situations where the
outer widget starts drag earlier and cancels the inner one.
Currently, this can easily happen via integer rounding: start and current
coordinates passed into gtk_drag_check_threshold() are initially doubles
(other than in GtkNotebook and GtkIconView), and are casted to ints. Then
those rounded values are used to calculate deltas to compare to the drag
threshold, losing quite a lot of precision along the way, and often
resulting in the outer widget getting larger deltas.
To avoid it, just don't round it. Introduce a variant of the function that
operates on doubles: gtk_drag_check_threshold_double() and use it instead
of the original everywhere.
2021-01-29 12:01:34 +05:00
Alexander Mikhaylenko
bbca4c38df
entry: Fix drag threshold check
...
It was passing offsets as current oordinates.
2021-01-29 12:00:10 +05:00
Alexander Mikhaylenko
28f5d26719
windowhandle: Don't drag on capture phase
...
This was needed to work around widgets claiming event sequences on press,
by ignoring them and starting the drag anyway unless they have certain
event controllers on them.
The most visible offender was GtkButton, but since the last commit it
doesn't claim the sequence anymore and we can remove the hack.
2021-01-29 12:00:10 +05:00
Alexander Mikhaylenko
bf2620f041
checkbutton: Claim sequence on release instead of press
...
Make it possible to drag windows from check buttons in future.
2021-01-29 12:00:10 +05:00
Alexander Mikhaylenko
870b82b541
button: Stop claiming event sequence on press
...
Currently GtkButton claims the sequence both on press and on release. Stop
claiming it on press and only do it on release, allowing drags to start
from it.
This will allow to remove a hack from GtkWindowHandle.
2021-01-29 12:00:10 +05:00
Matthias Clasen
1635d9fb78
Merge branch 'pango-glyph-positions' into 'master'
...
Tell pango not to round glyph positions
See merge request GNOME/gtk!2058
2021-01-29 01:41:56 +00:00
Matthias Clasen
20fb155e8c
gsk: Fix render node serialization
...
When looking for ascii glyphs, we must match
the pango shape flags that GTK is using.
2021-01-28 18:19:42 -05:00
Matthias Clasen
da59c77ae2
widget: Use subpixel positioning
...
Before turning off pangos rounding of glyph positions,
we must check if the cairo we are using is new enough
to have working subpixel positioning (the relevant
cairo commit is 52a7c79fd4ff96bb5fac175f0199819b0f8c18fc).
2021-01-28 18:17:22 -05:00
Matthias Clasen
0d0bdaa02e
gsk: Fix a thinko
...
With subpixel positioning, we need to offset the
cached glyphs by their phase.
2021-01-28 18:16:16 -05:00
Sebastian Keller
04cf5044da
wayland: Signal gtk-shell surface destruction to the server
...
This adds a "release" destructor for the gtk_surface1 interface which
signals to the server that a surface has been destroyed on the client
side, which the current "destroy" does not do.
Ideally the protocol would have specified a destroy request marked as
destructor to handle this automatically, however this is no longer
possible due to the destroy method being implicitly generated in the
absence of an explicit request in the protocol. Adding a destroy request
marked as destructor now would generate a new destroy method that
unconditionally would send the request to the server, which would break
clients running on servers not supporting that request.
2021-01-28 22:31:03 +01:00
Anders Jonsson
b005cd0bbd
Update Swedish translation
...
(cherry picked from commit 5a5bb9099e )
2021-01-28 20:39:25 +00:00
Matthias Clasen
f5379d2047
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
See merge request GNOME/gtk!3127
2021-01-28 19:12:18 +00:00
Matthias Clasen
98c247ec29
label: Drop some unused includes
2021-01-28 12:27:07 -05:00
Matthias Clasen
38e2f9138d
Remove vestigial glade support
...
These files have not been kept up to date, and
glade doesn't work with GTK4 currently.
2021-01-28 12:27:07 -05:00
Matthias Clasen
3cc7d9b8c0
Move the gesture icons in the right place
...
Put these images into gtk/icons, where they belong.
2021-01-28 12:27:07 -05:00
Matthias Clasen
1ac9400712
Drop unused logo resource
...
The inspector no longer sets a window icon.
2021-01-28 12:27:07 -05:00
Matthias Clasen
10d5705b70
Reduce use of GtkStyleContext
...
Remove some unnecessary uses of GtkStyleContext where
we can directly go to the GtkCssStyle, and and drop
unnnecessary includes.
2021-01-28 12:27:07 -05:00
Matthias Clasen
2d0d579735
Unify border-spacing handling
...
Avoid using GtkStyleContext unnecessarily, just go
to the css node directly.
2021-01-28 12:27:07 -05:00
Matthias Clasen
ac0f524722
build: Redo the tools build
...
Move the tools directory to be toplevel, and instead of
recompiling sources twice, link them with the our new
static libgtk.a.
2021-01-28 12:27:07 -05:00
Matthias Clasen
2cd0e5f60b
Merge branch 'wip/fl/gl-renderer-fixes' into 'master'
...
gskglshaderbuilder: bind correct uv location
See merge request GNOME/gtk!3128
2021-01-28 17:15:43 +00:00
Fabio Lagalla
d83502d054
gskglshaderbuilder: bind correct uv location
2021-01-28 17:08:46 +01:00
Matthias Clasen
9e539a7f59
Merge branch 'matthiasc/for-master' into 'master'
...
builder-tool: Translate GtkImage:pixbuf
See merge request GNOME/gtk!3126
2021-01-28 02:04:48 +00:00
Matthias Clasen
c60247f51f
Merge branch 'wip/fl/gl-gradients' into 'master'
...
OpenGL gradient rendering improvements and additions
See merge request GNOME/gtk!3105
2021-01-28 01:43:57 +00:00
Matthias Clasen
06321511ad
builder-tool: Translate GtkImage:pixbuf
...
The pixbuf property doesn't exist anymore. It is
commonly set to a path in ui files, so translate it
to the file property.
2021-01-27 17:01:51 -05:00
Matthias Clasen
2e7923cad0
Merge branch 'matthiasc/for-master' into 'master'
...
docs: Add gtk_widget_grab_default to migration guide
See merge request GNOME/gtk!3125
2021-01-27 21:53:02 +00:00
Matthias Clasen
3c66c27caa
docs: Add gtk_widget_grab_default to migration guide
...
Point out the replacement for this api.
2021-01-27 13:50:05 -05:00
Timm Bäder
7f4bd6917e
Merge branch 'sophie-h-master-patch-47269' into 'master'
...
widget: get_name() is not nullable
See merge request GNOME/gtk!3124
2021-01-27 18:34:10 +00:00
Sophie Herold
b89376da55
widget: get_name() is not nullable
...
Partial revert of !2905
2021-01-27 17:49:17 +00:00
Fabio Lagalla
a1dd6521e8
gskglrenderer: Remove switch fallthrough comments
2021-01-27 12:52:11 +01:00
Fabio Lagalla
0088f840fe
gskrendernode: Cache angle in conic gradients
2021-01-27 12:44:10 +01:00
Fabio Lagalla
1b698c896e
gskglrenderer: Use gboolean instead of bool
2021-01-27 12:44:10 +01:00
Fabio Lagalla
04000f28e7
gskglrenderer: First class support of repeating-radial-gradient
2021-01-27 12:44:10 +01:00
Fabio Lagalla
976a05f6eb
gskglrenderer: First class support of repeating-linear-gradient
2021-01-27 12:44:10 +01:00
Fabio Lagalla
b15902bf44
gskglrenderer: Optimize conic-gradient shader
2021-01-27 12:44:10 +01:00
Fabio Lagalla
5ac7529771
gskglrenderer: Optimize radial-gradient shader
2021-01-27 12:44:10 +01:00
Fabio Lagalla
bbf68c0d9d
gskglrenderer: Optimize linear-gradient shader
2021-01-27 12:44:10 +01:00
Matthias Clasen
eeb3dd3511
Merge branch 'fix-can-focus' into 'master'
...
widget: Fix can-focus
Closes #3610
See merge request GNOME/gtk!3123
2021-01-27 05:34:21 +00:00
Matthias Clasen
7b0ce11e46
Merge branch 'search-entry-capture' into 'master'
...
Search entry capture
Closes #3098
See merge request GNOME/gtk!3115
2021-01-27 05:14:30 +00:00
Matthias Clasen
8ef1d6a49c
widget: Fix can-focus
...
Setting can-focus to FALSE on a widget is supposed
to prevent focus from entering the entire subtree.
So when we grab focus directly to a widget, we need
to check the can-focus flag not just of the widget
itself, but all its ancestors.
Fixes : #3610
2021-01-26 23:45:06 -05:00
Matthias Clasen
7db60f958d
searchentry: Capture events in the bubble phase
...
This is an unfortunate naming clash, but it avoids
an event handling clash between the capture widget
and its children.
Fixes : #3098
2021-01-26 22:17:57 -05:00
Matthias Clasen
30043e072e
Merge branch 'css-crossfade-color' into 'master'
...
Css crossfade color
See merge request GNOME/gtk!3122
2021-01-27 03:11:17 +00:00
Matthias Clasen
5ee7606779
css: Support colors in cross fades
...
The CSS Image Spec (Level 4) allows colors in
cross-fade expressions to specify solid-color images.
Support this.
2021-01-26 21:14:09 -05:00
Matthias Clasen
25409c5a5a
css: Add a constructor for GtkCssImageFallback
...
Add a way to create a solid color image.
2021-01-26 21:10:11 -05:00
Matthias Clasen
51122dd287
docs: Cosmetics
...
Tweak the css docs slightly.
2021-01-26 20:33:16 -05:00
Matthias Clasen
ec9159f983
Merge branch 'gst-vaapi-fix-pre' into 'master'
...
Minor fixes to gtkgstsink
See merge request GNOME/gtk!3120
2021-01-27 01:11:54 +00:00
Matthias Clasen
f3d77d1c21
Merge branch 'css-text-decoration' into 'master'
...
css: Fix text-decoration-line support
Closes #3621
See merge request GNOME/gtk!3121
2021-01-27 00:42:40 +00:00
Matthias Clasen
1258fcaaf4
css: Fix text-decoration-line support
...
This property needs to be treated as flags, not as
enum, since it should be possible to specify more
than one value, e.g.
text-decoration-line: underline overline;
Tests included.
Fixes : #3621
2021-01-26 17:53:14 -05:00
Jan Alexander Steffens (heftig)
00fd60aaa8
gtkgstsink: Use video_frame_free also for the GL path
...
The video frame needs to stay mapped while the texture is in use.
Avoid using g_memdup because the structure is not supposed to be moved.
2021-01-26 20:30:47 +01:00
Jan Alexander Steffens (heftig)
c7a7d0582a
gtkgstsink: Report allocation size even if no pool requested
...
We can do that so we should.
2021-01-26 20:30:47 +01:00
Matthias Clasen
b6e7acfb90
Merge branch 'matthiasc/for-master' into 'master'
...
docs: Update border-size docs
See merge request GNOME/gtk!3119
2021-01-26 16:25:24 +00:00
Matthias Clasen
40eae298d5
docs: Update border-size docs
...
GtkCenterLayout respected border-size as well.
2021-01-26 10:40:22 -05:00
Marek Černocký
09a9131a10
Updated Czech translation
2021-01-26 16:21:18 +01:00
Marek Černocký
c93c9f5c2a
Updated Czech translation
2021-01-26 16:12:36 +01:00
Matthias Clasen
7f08adc23e
Merge branch 'ebassi/for-master' into 'master'
...
Fixes for gdk_surface_translate_coordinates()
See merge request GNOME/gtk!3118
2021-01-26 13:57:50 +00:00
Emmanuele Bassi
f41012080f
Validate arguments
...
We're just assuming everything is not NULL or with a valid type.
2021-01-26 12:56:32 +00:00
Emmanuele Bassi
786e9d351c
Make the inout argument logic clearer
...
It's easy to misread a `+=`.
2021-01-26 12:54:53 +00:00
Emmanuele Bassi
3d2cf97fbf
Fix annotations
...
The arguments are really (inout), not (out).
2021-01-26 12:54:00 +00:00
Matthias Clasen
1fe6fb6739
Merge branch 'circular-menubutton' into 'master'
...
Allow circular menubuttons
Closes #3423 and #3523
See merge request GNOME/gtk!3117
2021-01-26 12:47:38 +00:00
Emmanuele Bassi
6710eb5eb3
Merge branch 'ricotz/for-master' into 'master'
...
gdk: Add missing g-i annotations for gdk_surface_translate_coordinates
See merge request GNOME/gtk!3112
2021-01-26 12:28:55 +00:00
Matthias Clasen
80b1d55683
Merge branch 'css-overline' into 'master'
...
css: Support overline
See merge request GNOME/gtk!3116
2021-01-26 05:44:14 +00:00
Matthias Clasen
1cebc4316b
Allow circular menubuttons
...
Fixes #3523
2021-01-26 00:20:23 -05:00
Matthias Clasen
20895d6f3f
Merge branch 'adaptive-emojichooser' into 'master'
...
Adaptive emojichooser
Closes #3307
See merge request GNOME/gtk!2989
2021-01-26 05:07:46 +00:00
Matthias Clasen
65a4118d50
css: Support overline
...
We can support text-decoration-line: overline,
since pango supports it now.
2021-01-26 00:04:04 -05:00
Matthias Clasen
4857829aaa
popover: Try to not exceed monitor bounds
...
When the natural size of the popover exceeds
the monitor width, clamp it to fit on screen.
This gives the Emoji chooser a chance to
work on phone screens.
Fixes : #3307
2021-01-25 23:33:04 -05:00
Matthias Clasen
2ea4574caf
emojichooser: Allow the section buttons to wrap
...
Use a flowbox instead of a horizontal box for
the section buttons at the bottom, so they can
wrap and allow for narrow layout.
We also need to stop giving the scrolledwindow
a content height, so it can shrink to make room
for more rows of section buttons.
2021-01-25 23:32:15 -05:00
Matthias Clasen
102b74f9eb
emojichooser: Make keynav work with != 7 columns
...
The number of 7 columns was hardcoded in a few places
related to keynav across sections. The flowbox does
not have an api for it, but we can find out anyway
how many columns there are.
2021-01-25 23:32:08 -05:00
Matthias Clasen
8a0d4dfa94
searchbar: Capture events in the bubble phase
...
This is an unfortunate naming clash, but it avoids
an event handling clash between the capture widget
and its children.
Fixes : #3098
2021-01-25 22:16:29 -05:00
Matthias Clasen
b4e645862a
searchbar: Fix documentation mishap
...
The css section was inserted between the example
and the sentence referring to it.
2021-01-25 22:15:56 -05:00
Matthias Clasen
ea48506a32
Merge branch 'simplify-get-module-path' into 'master'
...
modules: Simplify _gtk_get_module_path
See merge request GNOME/gtk!3113
2021-01-26 02:53:38 +00:00
Jan Alexander Steffens (heftig)
23f0a29260
modules: Simplify _gtk_get_module_path
...
Remove the bizarre loops.
2021-01-25 22:47:16 +01:00
Rico Tzschichholz
9249717cf4
gdk: Add missing g-i annotations for gdk_surface_translate_coordinates
2021-01-25 20:18:33 +01:00
Matthias Clasen
4196dfc374
Merge branch 'wip/jimmac/larger-scrollbars-gtk4' into 'master'
...
Adwaita: make scrollbars larger
Closes #1886
See merge request GNOME/gtk!3109
2021-01-25 13:35:47 +00:00
Jakub Steiner
23af707b41
Adwaita: make scrollbars larger
...
When using scrollbars as active controls, rather than their primary role as indicators,
increase their size as click targets.
Fixes https://gitlab.gnome.org/GNOME/gtk/issues/1886
2021-01-25 14:15:22 +01:00
Matthias Clasen
421088c3a0
Merge branch 'transform-origin' into 'master'
...
Transform origin
See merge request GNOME/gtk!3108
2021-01-25 12:58:36 +00:00
Matthias Clasen
749f1a7c00
Add a reftest for transform-origin
2021-01-24 23:47:10 -05:00
Matthias Clasen
344f9fcf05
css: Implement transform-origin
...
Implement most of transform-origin. We only
handle the xy components currently, which lets
us reuse the position value implementation that
is used for background-position.
2021-01-24 22:49:08 -05:00
Matthias Clasen
4c971cd4da
docs: Fix reference for css transform
...
Refer to the canonical location for the css
transform spec.
2021-01-24 22:48:00 -05:00
A S Alam
43d553dcfb
Update Punjabi translation
...
(cherry picked from commit 64519d73bb )
2021-01-24 22:52:47 +00:00
A S Alam
66264f9a3d
Update Punjabi translation
...
(cherry picked from commit 518331812e )
2021-01-24 22:42:39 +00:00
Efstathios Iosifidis
269f369541
Update Greek translation
...
(cherry picked from commit 281c17c400 )
2021-01-24 10:17:36 +00:00
Matthias Clasen
1973019962
Merge branch 'static-lib-for-tests' into 'master'
...
Static lib for tests
See merge request GNOME/gtk!3107
2021-01-23 16:15:23 +00:00
Matthias Clasen
fe515c4c1c
testsuite: Link some tests statically
...
Link tests for private apis statically.
2021-01-23 10:34:57 -05:00
Matthias Clasen
14f0a0addb
Create a static library
...
Rearrange our build to create a libgtk.a for the the contents of gtk/,
and build libgtk-4.so from our per-subdirectory static libraries.
This will let us link tests statically for testing internal apis.
2021-01-23 10:31:23 -05:00
Matthias Clasen
64a2d0221c
Merge branch 'lsan-leaks-2' into 'master'
...
Lsan leaks 2
See merge request GNOME/gtk!3106
2021-01-22 20:08:54 +00:00
Matthias Clasen
0ef91c3ba8
Avoid a buffer overrun
...
We were putting the '\0' behind the end. Oops.
2021-01-22 13:56:04 -05:00
Matthias Clasen
2adcb7be71
Tweak lsan suppressions
...
We don't use atk-bridge anymore, and we don't want
to see gio leaks.
2021-01-22 13:32:41 -05:00
Matthias Clasen
a332f2402a
ci: Don't print lsan suppressions
...
Printing these out breaks TAP output, and we really
aren't interested in them.
2021-01-22 13:01:09 -05:00
Matthias Clasen
131a61c51b
testsuite: Fix a leak
...
asan pointed out that the array tests leak.
2021-01-22 11:50:04 -05:00
Matthias Clasen
39d5dd89c5
Avoid a heap-use-after-free
...
_gtk_gesture_cancel_sequence frees the struct pointed to by data,
so don't write to it afterwards. Found by asan.
2021-01-22 11:39:04 -05:00
Danial Behzadi
341efe9a40
Update Persian translation
2021-01-22 14:57:52 +00:00
Matthias Clasen
5ed6f89b4a
Merge branch 'lsan-leaks' into 'master'
...
Lsan leaks
See merge request GNOME/gtk!3104
2021-01-22 12:30:22 +00:00
Matthias Clasen
4d609149d2
Merge branch 'tests-without-diff' into 'master'
...
testsuite: Stop requiring diff
See merge request GNOME/gtk!3103
2021-01-22 05:16:08 +00:00
Matthias Clasen
0d790505aa
Force malloc of g_slices in asan build
...
Otherwise leaks could be missed.
2021-01-22 00:13:13 -05:00
Matthias Clasen
a486536925
Remove libc from leak suppression list
...
Every program starts in __libc_start_main, so this would suppress
everything. This doesn't happen in practice because asan by default
is unable to unwind the stack. Setting
ASAN_OPTIONS=fast_unwind_on_malloc=0,malloc_context_size=15 can unwind
the stack, and if malloc_context_size is large enough it will indeed
suppress everything.
2021-01-22 00:12:46 -05:00
Matthias Clasen
e808fb424a
testsuite: Stop requiring diff
...
Unify the many copies of diff_with_file in one source
file, and patch it to detect diff at runtime and fall
back to a simple strcmp if we don't have it. Make all
tests use this new testutils.c, and stop requiring
diff for building the tests.
This should let us allow to build on Windows with the
default value for -Dbuild-tests.
2021-01-21 23:57:24 -05:00
Matthias Clasen
6c54abeca7
wayland: Explicitly announce ssd for kwin
...
Without this, kwin correctly assumes that we are
using client-side decorations. This is a port
of 32ae97f1 from GTK 3.24.
Fixes : #3609
2021-01-21 22:45:47 -05:00
Daniel Șerbănescu
d24b8a094c
Update Romanian translation
2021-01-21 19:27:47 +00:00
Emmanuele Bassi
c46391420f
Merge branch 'ebassi/lazier-a11y' into 'master'
...
Lazier accessibility
See merge request GNOME/gtk!3102
2021-01-21 18:57:34 +00:00
Yuri Chornoivan
68df7527f7
Update Ukrainian translation
2021-01-21 18:23:25 +00:00
Matthias Clasen
5a3c3d8210
Merge branch 'inspector-controllers' into 'master'
...
Inspector controllers
See merge request GNOME/gtk!3101
2021-01-21 18:15:57 +00:00
Emmanuele Bassi
95ceb49770
a11y: Make GtkATContext realization lazier
...
We only realize the ATContext on the top level, which will create an
GtkAtSpiRoot object and the corresponding GtkAtSpiCache object. Whenever
an AT connects to the accessibility bus, and asks for the various
objects, all the ATContext will be realized on demand.
2021-01-21 16:40:57 +00:00
Emmanuele Bassi
0bde58ffd7
a11y: Avoid signal emission during cache population
...
If we're responding to a request to get all the cached items, there's no
need to emit signals when adding an ATContext to the cache.
2021-01-21 16:40:57 +00:00
Matthias Clasen
ccd9827b63
inspector: Redo the actions page
...
Don't create widgets in bind, instead just set
the new action on the action-editor, and let it
recreate the parts that need to be recreated.
2021-01-21 10:25:13 -05:00
Matthias Clasen
db189cfb9f
inspector: Reshuffle action editor
...
Prepare the action editor for being able to change its
actions after creation.
2021-01-21 10:24:31 -05:00
Matthias Clasen
7527f181d5
inspector: Simplify action editor
...
We are not using the size group anymore, so drop it.
2021-01-21 10:20:21 -05:00
Matthias Clasen
c05b418512
inspector: Split out variant editor
2021-01-21 10:19:18 -05:00
Matthias Clasen
e97d996fe4
inspector: Redo the shortcuts page
...
Use a column view here.
2021-01-21 10:19:18 -05:00
Matthias Clasen
0537b167ca
inspector: Redo the controllers page
...
Use a column view, and only show the widgets own
controllers.
2021-01-21 10:19:18 -05:00
Matthias Clasen
40446201ff
Merge branch 'ebassi/for-master' into 'master'
...
Ebassi/for master
Closes #3607
See merge request GNOME/gtk!3100
2021-01-21 04:22:13 +00:00
Matthias Clasen
fff6b35821
inspector: Redo the controllers page
...
Use a column view, and only show the widgets own
controllers.
2021-01-20 18:51:01 -05:00
Emmanuele Bassi
75f2d7583f
Abort if the shared memory pool cannot be created
...
If we cannot allocate memory, we cannot create any windowing system
surface. There's no coming back from that.
Fixes : #3607
2021-01-20 19:10:54 +00:00
Matthias Clasen
1fd8d3b487
Merge branch 'matthiasc/for-master' into 'master'
...
docs: Update getting started section
Closes #3601
See merge request GNOME/gtk!3099
2021-01-20 15:54:37 +00:00
Emmanuele Bassi
a1216599ff
Add rename-to annotation for GtkListStore.insert_valuesv()
...
The vector-based variant should shadow the variadic arguments function
in bindings.
2021-01-20 14:10:17 +00:00
Emmanuele Bassi
8fff0e0fdf
docs: Reformat GtkListStore.insert_values()
2021-01-20 14:10:17 +00:00
Emmanuele Bassi
439727a84a
Add more directions to the issue templates
...
Let's hope people read them.
2021-01-20 14:10:17 +00:00
Matthias Clasen
3a18a6dddf
docs: Update getting started section
...
We were still talking about draw signals here,
which don't exist anymore.
Fixes : #3601
2021-01-20 08:01:54 -05:00
Matthias Clasen
d7050c63ae
Merge branch 'treeview-sort-arrows' into 'master'
...
Redo arrow icons in various widgets
Closes #3577
See merge request GNOME/gtk!3097
2021-01-19 21:24:04 +00:00
Balázs Meskó
b7c88ec87d
Update Hungarian translation
2021-01-19 20:47:20 +00:00
Matthias Clasen
5985b62f60
columnview: Redo indicator arrows
...
Use the same approach as GtkTreeViewColumn for sort
indicators. Luckily, the same css works for both.
2021-01-19 14:24:19 -05:00
Matthias Clasen
e7c29b989c
menbutton: Redo indicator arrows
...
Instead of hardcoding icon names in the widget, use
arrow.none, arrow.up, arrow.down, arrow.left, arrow.right
styles and set the icon to use with -gtk-icon-source. This
lets themes change the icons that are used here, without
forcing all uses of pan-up/down/start/end-symbolic to be
treated the same.
Document this in the menubutton CSS docs.
2021-01-19 14:02:23 -05:00
Matthias Clasen
2100e427d9
treeviewcolumn: Redo sort arrows
...
Instead of hardcoding icon names in the widget, use
sort-indicator.ascending and sort-indicator.descending styles
and set the icon to use with -gtk-icon-source. This lets themes
change the icon that is used here, without forcing all uses of
pan-up/down-symbolic to be treated the same.
Document this in the treeview CSS docs.
Fixes : #3577
2021-01-19 14:02:16 -05:00
Matthias Clasen
2550d6dc63
Merge branch 'wip/kalev/dist-HighContrast-dark' into 'master'
...
dist: Fix css theme disting after HighContrast-dark changes
See merge request GNOME/gtk!3095
2021-01-19 12:08:21 +00:00
Matthias Clasen
ca72fae884
Merge branch 'issue-2436-gtk4' into 'master'
...
macOS: fix #2436 raise transient window on focus
Closes #2436
See merge request GNOME/gtk!3094
2021-01-19 11:56:54 +00:00
Matthias Clasen
4fc1af14a7
Merge branch 'wip/kalev/NEWS.pre-4.0' into 'master'
...
Split NEWS for pre-4.0 changes
See merge request GNOME/gtk!3096
2021-01-19 11:43:58 +00:00
Kalev Lember
1a30ec6da6
dist: Fix css theme disting after HighContrast-dark changes
...
Commit f60d245e32 renamed it from
HighContrast-inverse.css to HighContrast-dark.css.
2021-01-19 10:50:30 +01:00
Kalev Lember
e77d519482
Split NEWS for pre-4.0 changes
...
Similar to commit 87e9f0895b that did the
same for older releases, this commit splits out pre-4.0 changes to
separate NEWS.pre-4.0 file.
2021-01-19 10:40:09 +01:00
Thomas Holder
59806eee38
macOS: fix #2436 raise transient window on focus
...
Ported from gtk-3-24 e278f38905
Fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/2436
2021-01-19 09:31:00 +01:00
Alexander Mikhaylenko
5968b10b0b
listitemwidget: Activate on release instead of press
...
Single click activation should only be done on release and not on press,
otherwise it breaks touch scrolling. Double-click activation still can be
done on press.
This matches the GtkListBox behavior as well.
Fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/3345
2021-01-19 12:36:32 +05:00
Matthias Clasen
e6f0103940
Merge branch 'version-bump' into 'master'
...
Version bump
See merge request GNOME/gtk!3093
2021-01-19 04:48:26 +00:00
Matthias Clasen
cbaad3dbd9
Add version macros for 4.2
...
These will be needed for adding new API.
2021-01-18 23:10:18 -05:00
Matthias Clasen
ee43a6a603
Bump version to 4.1
...
master is now open for 4.2 API additions.
Includes an update for the one test we have that
has the version number in its expected output.
2021-01-18 23:09:44 -05:00
Matthias Clasen
1ac1147ecb
Merge branch 'check_button_activate' into 'master'
...
Add activate signal to GtkCheckButton
Closes #3525 and #3550
See merge request GNOME/gtk!3012
2021-01-19 04:06:01 +00:00
Matthias Clasen
1edbc1f1f9
Merge branch 'wip/jtojnar/fix-pc-vulcan' into 'master'
...
build: Use Meson’s module for building .pc files
Closes #3517
See merge request GNOME/gtk!3005
2021-01-19 04:04:34 +00:00
Matthias Clasen
146b4c93ba
4.0.2
2021-01-18 22:23:57 -05:00
Matthias Clasen
94f90f457a
Merge branch 'fix-cell-renderer-toggle' into 'master'
...
cellrenderertoggle: Fix css node handling
Closes #3599
See merge request GNOME/gtk!3092
2021-01-19 02:09:10 +00:00
Matthias Clasen
6b7d56ac49
cellrenderertoggle: Fix css node handling
...
Commit cbbbf44dd4 tried to replace
gtk_style_context_save_named with an explicit
css node to save to, but it failed, and the failure
was showing up as crashes in the inspector.
Fix by Benjamin Otte.
Fixes : #3599
2021-01-18 20:52:59 -05:00
Emmanuele Bassi
1635d7be8c
Merge branch 'cherry-pick-gtk_file_chooser_set_current_name-fix-type' into 'master'
...
gtk_file_chooser_set_current_name: fix type of name argument
See merge request GNOME/gtk!3091
2021-01-18 23:19:00 +00:00
Thomas Holder
992cd088cf
gtk_file_chooser_set_current_name: fix type of name argument
...
The description says UTF-8 string, but the annotation said filename.
Cherry-picked from gtk-3-24 1573ff6803
2021-01-18 22:14:03 +01:00
Matthias Clasen
f6010b2a59
Merge branch 'doap-update' into 'master'
...
Update the gtk.doap file
See merge request GNOME/gtk!3088
2021-01-18 14:40:02 +00:00
Matthias Clasen
9222a5fd6d
Update the gtk.doap file
...
Add relevant people as maintainers.
2021-01-18 09:14:50 -05:00
Florentina Mușat
6f7fb6ba5a
Update Romanian translation
2021-01-18 13:06:18 +00:00
Chun-wei Fan
a57a144f8e
Merge branch 'win32-remove-layered-windows' into 'master'
...
GDK/Win32: Remove layered windows usage
See merge request GNOME/gtk!2782
2021-01-18 10:42:37 +00:00
Chun-wei Fan
7b47e3225b
GDK/Win32: Remove layered windows usage
...
In GTK4, we are now defaulting to the OpenGL renderer with the Cairo renderer
only used as a fallback, so there is no point keeping the code paths that use
layered windows as layered windows do not work well with OpenGL nor Vulkan.
2021-01-18 12:48:16 +08:00
Matthias Clasen
6aa893e091
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
Closes #3437
See merge request GNOME/gtk!3087
2021-01-17 17:51:15 +00:00
Matthias Clasen
5aa03bcb0d
aboutdialog: Fix initial focus
...
When GtkAboutDialog was changed to derive from
GtkWindow, it lost the initial focus handling that
GtkDialog has. Reinstate some of it.
Fixes : #3437
2021-01-17 11:53:53 -05:00
Matthias Clasen
d7060025e0
inspector: Avoid a critical
...
Avoid a critical when closing the inspector with the
recorder page open.
2021-01-17 10:55:53 -05:00
Matthias Clasen
00883016af
Merge branch 'wip/baedert/for-master' into 'master'
...
Wip/baedert/for master
Closes #3593
See merge request GNOME/gtk!3086
2021-01-17 14:20:13 +00:00
Fabio Tomat
f0d8b614d0
Update Friulian translation
2021-01-17 13:11:25 +00:00
Piotr Drąg
ddbd574643
Update Polish translation
2021-01-17 12:38:17 +01:00
Timm Bäder
5ea3777599
widget: Fix gtk_widget_class_add_binding() argument name
2021-01-17 08:12:14 +01:00
Timm Bäder
a3949763f2
Add nullable annotations to GtkShortcutFunc
...
Fixes #3593
2021-01-17 08:11:42 +01:00
Matthias Clasen
1b961a9ae2
Merge branch 'surface-scale' into 'master'
...
Surface scale
Closes #3578
See merge request GNOME/gtk!3085
2021-01-17 05:23:22 +00:00
Timm Bäder
d9f6b268d3
gl renderer: Use rect_contains_rect() copy
...
And this way the contains_rect() inside
rounded_inner_rect_contains_rect() goes from 3.3% to 0.79% in the
fishbowl when rendering the levelbars.
2021-01-17 04:39:26 +01:00
Timm Bäder
934b91f65f
label: Remove unneeded NULL guards
...
The pointers passed to GtkWidgetClass::measure cannot be NULL
2021-01-17 04:39:26 +01:00
Timm Bäder
c3050231d1
label: Refactor get_layout_location
...
Make this function shorter, the parameters non-nullable and the simple
cases more explicit.
2021-01-17 04:39:26 +01:00
Timm Bäder
4d7a01562e
gl renderer: Don't reset offset when drawing offscreen
2021-01-17 04:39:26 +01:00
Timm Bäder
650eed7f72
gl renderer: Properly y-flip non-offscreen children of rounded clips
2021-01-17 04:39:26 +01:00
Timm Bäder
ec8614e8e4
label: Fix a potential memory leak
...
This only happens in error cases so not very interesting. Anyway, try to
make scan-build happy.
2021-01-17 04:39:26 +01:00
Timm Bäder
cb41b96a9e
builderparser: Save finalizers in a GPtrArray
...
We get up to 370 of these when starting the widget-factory.
2021-01-17 04:39:26 +01:00
Timm Bäder
872b46a527
widget: Shorten get_halign() a bit
2021-01-17 04:39:26 +01:00
Timm Bäder
b1c8613dbe
accessible: Fix memory leak if context is unset
...
Unref the acessible values
2021-01-17 04:39:26 +01:00
Timm Bäder
de6cd4f0d2
builder: Use a GPtrArray when parsing signals
2021-01-17 04:39:26 +01:00
Timm Bäder
aec2fb939f
builderparser: Keep properties in a GPtrArray
2021-01-17 04:39:26 +01:00
Timm Bäder
69293db804
builderparser: Only allocate subparser stack when needed
...
Out of the 3.3k possibly_finish_subparser calls when opening the
widget-factory, only 300 need one.
2021-01-17 04:39:26 +01:00
Matthias Clasen
61a7ebf980
Merge branch 'matthiasc/for-master' into 'master'
...
docs: Add details
See merge request GNOME/gtk!3084
2021-01-16 20:36:44 +00:00
Matthias Clasen
f14762b026
x11: Notify on surface scale changes
...
Emit property notification when the surface scale
changes.
2021-01-16 15:22:46 -05:00
Matthias Clasen
187d261400
wayland: Notify on surface changes
...
When the width, height or scale of a surface changes,
emit property change notification.
2021-01-16 15:22:46 -05:00
Matthias Clasen
e905f7ff7c
native: Listen for scale changes
...
Connect to change notification for the surface
scale-factor property, and update the widgets
when it changes.
Fixes : #3578
2021-01-16 15:22:46 -05:00
Matthias Clasen
aefc630d29
surface: Add a scale-factor property
...
This will allow us to notify when the scale changes.
2021-01-16 15:22:46 -05:00
Matthias Clasen
a5e929ce36
docs: Add details
...
Explain the difference between GtkPicture and GtkImage,
and when you might want to use which.
2021-01-16 14:45:20 -05:00
Yuri Chornoivan
1641d365f5
Update Ukrainian translation
2021-01-16 18:44:30 +00:00
Matthias Clasen
07d9cd8efe
Merge branch 'matthiasc/for-master' into 'master'
...
inspector: Add a legend for the layout overlay
See merge request GNOME/gtk!3083
2021-01-16 18:37:58 +00:00
Matthias Clasen
29868b2a05
docs: Remove a reference to configure events
...
Those don't exist anymore.
2021-01-16 12:52:06 -05:00
Matthias Clasen
691b6b88ea
inspector: Add a legend for the layout overlay
...
Colors are more useful if you know what they represent.
2021-01-16 12:38:24 -05:00
Matthias Clasen
2ee1a00177
Merge branch 'matthiasc/for-master' into 'master'
...
overlaylayout: Set the child type in the class
See merge request GNOME/gtk!3082
2021-01-16 03:55:22 +00:00
Matthias Clasen
144cf2d040
overlaylayout: Set the child type in the class
...
We don't need to override create_layout_child here,
and setting the child type has the advantage that
the layout properties are showing up in the inspector.
2021-01-15 22:35:11 -05:00
Matthias Clasen
e1a308d151
Merge branch 'rtl-margins' into 'master'
...
Flip margin-start and -end in RTL
Closes #3583
See merge request GNOME/gtk!3081
2021-01-16 00:19:41 +00:00
Matthias Clasen
bbfaacb598
Add a reftest for box flipping
...
Test that a horizontal box changes the order of its
children in RTL, and that widget margins flip start
and end.
This tests the fix in d89ff71819 .
2021-01-15 18:43:31 -05:00
Matthias Clasen
d89ff71819
Flip margin-start and -end in RTL
...
We lost this at some point, but the widget margins
are still meant to be relative to the text direction.
Fixes : #3583
2021-01-15 14:58:21 -05:00
Matthias Clasen
141c725489
Merge branch 'macos-ci-cairo' into 'master'
...
Revert "Fix the cairo build on OS X"
See merge request GNOME/gtk!3080
2021-01-15 15:56:37 +00:00
Matthias Clasen
bbc3aa4ff9
Revert "Fix the cairo build on OS X"
...
This reverts commit 710ef00dfe .
The cairo change has been merged.
2021-01-15 09:07:02 -05:00
Marek Černocký
f7856f29fd
Updated Czech translation
2021-01-15 14:10:17 +01:00
Matthias Clasen
7b69c58deb
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
See merge request GNOME/gtk!3078
2021-01-15 05:48:00 +00:00
Matthias Clasen
f60d245e32
Make HighContrastInverse a dark variant
...
Make HighContrastInverse available as the dark variant of HighContrast,
in addition to being a standalone theme. This regularizes our theme
variants, and doesn't hurt.
2021-01-14 22:55:52 -05:00
Matthias Clasen
f04e5bd590
Make Adwaita-dark available as a theme
...
This makes Adwaita-dark available as a standalone
theme.
2021-01-14 22:42:50 -05:00
Matthias Clasen
90c428b4a7
Merge branch 'wip/carlosg/mark-valid-portal-settings' into 'master'
...
gdk/wayland: Mark matched settings from the portal as valid
See merge request GNOME/gtk!3076
2021-01-14 18:33:45 +00:00
Carlos Garnacho
97b5fad131
gdk/wayland: Mark matched settings from the portal as valid
...
Commit e6209de962 added some checks on TranslationEntry.valid in
order to figure out whether using the new font settings or the
old g-s-d ones. However that's only set in the non-sandboxed case.
This makes sandboxed applications fallback to the old (and also
non-existing with modern g-s-d) settings, possibly resulting in
ugly defaults being picked.
Fix this by also marking TranslationEntry elements as valid when
using the settings portal, precisely those entries that we are able
to read and match with our own table.
2021-01-14 15:57:29 +01:00
Matthias Clasen
285a91715d
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
See merge request GNOME/gtk!3075
2021-01-14 13:38:18 +00:00
Matthias Clasen
880468f5a3
docs: Fix a heading gotcha
...
One of the many migration guide sections was too
prominent.
2021-01-14 08:13:34 -05:00
Matthias Clasen
6ddbb2a402
doc: Clarify some migration hints
...
Don't mention GdkSurface::layout as replacement for
GtkWindow::configure-event. Instead, explain how to
save window state.
2021-01-14 07:52:36 -05:00
Daniel Mustieles
7eab565225
Updated Spanish translation
2021-01-14 10:35:43 +01:00
Daniel Mustieles
b34101d45d
Updated Spanish translation
2021-01-14 10:35:35 +01:00
Christian Hergert
6c21a7be0b
Merge branch 'nacho/macos-stylus' into 'master'
...
Support stylus devices on macos
See merge request GNOME/gtk!3058
2021-01-13 16:13:14 +00:00
Anders Jonsson
a6f2bcb220
Update Swedish translation
2021-01-12 21:55:52 +00:00
Anders Jonsson
ef0db01d5c
Update Swedish translation
2021-01-12 21:51:53 +00:00
Emmanuele Bassi
ef33ec639c
Merge branch 'ebassi/aspect-frame-doc' into 'master'
...
Ebassi/aspect frame doc
See merge request GNOME/gtk!3073
2021-01-12 16:50:31 +00:00
Matthias Clasen
27ca4434e2
Remove a misleading comment
2021-01-12 10:50:41 -05:00
Matthias Clasen
9861c7d25c
Merge branch 'dist-css' into 'master'
...
dist: Add a dist script to generate css
See merge request GNOME/gtk!3074
2021-01-12 14:04:51 +00:00
Matthias Clasen
13ef82fc4d
dist: Add a dist script to generate css
...
When I added the sassc option, I failed to ensure that
the theme css is included in the tarballs. This is required
to make tarball builds with -Dsassc=disabled work.
2021-01-12 08:42:18 -05:00
Emmanuele Bassi
b33ca43e14
Merge branch 'ebassi/atspi-path-sanitize' into 'master'
...
a11y: Fix leak
See merge request GNOME/gtk!3072
2021-01-12 12:37:31 +00:00
Emmanuele Bassi
39e07a8d56
Document limits of gtk_aspect_frame_get_ratio()
...
The GtkAspectFrame:ratio getter will return the value set, not the
actual ratio computed in case GtkAspectFrame:obey-child is TRUE.
2021-01-12 12:28:18 +00:00
Emmanuele Bassi
5286743cbe
Document GtkAspectFrame properties
2021-01-12 12:28:00 +00:00
Emmanuele Bassi
58bb998ef0
docs: GtkAspectFrame is not a GtkFrame any more
2021-01-12 12:23:14 +00:00
Emmanuele Bassi
a56b2900dd
a11y: Fix leak
...
Introduced by me in commit 03b60a2d5e .
2021-01-12 12:01:29 +00:00
Emmanuele Bassi
ff34124394
Merge branch 'ebassi/atspi-path-sanitize' into 'master'
...
a11y: Sanitize the AT-SPI object path further
See merge request GNOME/gtk!3071
2021-01-12 11:36:52 +00:00
Emmanuele Bassi
03b60a2d5e
a11y: Sanitize the AT-SPI object path further
...
When falling back to g_get_prgname(), we need to take into account that
the program name may be the full argv[0] path, which will end up messing
the DBus object path.
2021-01-12 11:15:28 +00:00
Benjamin Otte
d939d04885
Merge branch 'about-dialog-icon-size' into 'master'
...
About dialog icon size
See merge request GNOME/gtk!3070
2021-01-11 23:13:21 +00:00
Matthias Clasen
73fb28a058
iconhelper: Recreate the texture when needed
...
When the icon size changes, we want to reload themed
icons.
This was showing up as the GtkImage in about dialogs
getting a big size with the same small icon upon
changing -gtk-icon-size in the inspector.
2021-01-11 17:50:05 -05:00
Matthias Clasen
65eaf8e8c4
Adwaita: Make about dialog icons big
...
Use 128 as the icon size for the image widget
in about dialogs.
2021-01-11 17:50:05 -05:00
Matthias Clasen
beeedb5141
aboutdialog: Set icon-size for the logo
...
Make it explicit that we want large icons here.
2021-01-11 17:50:05 -05:00
Matthias Clasen
1d40750a60
aboutdialog: Set a style class
...
Add the .aboutdialog style class to toplevel
widget of about dialogs, similar to what we
do for e.g. GtkAssistant.
2021-01-11 17:46:55 -05:00
Matthias Clasen
96baf9769a
about dialog: Remove manual icon sizing
...
We have icon theme code to do that for us.
2021-01-11 17:46:55 -05:00
Matthias Clasen
5044031b53
Merge branch 'wip/kalev/gcc-11' into 'master'
...
Avoid diagnostics for gcc-11 false positive out of bounds accesses
See merge request GNOME/gtk!3064
2021-01-11 22:04:52 +00:00
Emmanuele Bassi
9f7119ee58
Merge branch 'wip/fl/glrenderer-fixes' into 'master'
...
gl renderer: print fragment shader info
See merge request GNOME/gtk!3069
2021-01-11 16:44:00 +00:00
Kalev Lember
c514c41d0e
Avoid diagnostics for gcc-11 false positive out of bounds accesses
...
This is a patch by Jeff Law <law@redhat.com > done in downstream Fedora
to fix the build with gcc 11.
2021-01-11 17:19:36 +01:00
Jakub Steiner
45848c5298
Merge branch 'wip/jimmac/adjust-for-contemporary-trends' into 'master'
...
Wip/jimmac/adjust for contemporary trends
Closes #3568 and #3560
See merge request GNOME/gtk!3060
2021-01-11 16:09:08 +00:00
Fabio Lagalla
8c61038b9f
gl renderer: print fragment shader info
...
It was logged twice the vertex shader info, instead
2021-01-11 17:06:03 +01:00
Jakub Steiner
b5cb2f7e41
Adwaita: update image assets
...
- reflect button styling
- ignore backdrop for non buttons
2021-01-11 16:24:22 +01:00
Matthias Clasen
8af0d4b51f
Merge branch 'otte/for-master2' into 'master'
...
Remove guarantees we do not intend to hold
See merge request GNOME/gtk!3066
2021-01-11 15:07:40 +00:00
Jakub Steiner
378ad75d48
Adwaita: scales border
...
- remove -alt specialcasing for a straight forward border like
everything else and avoid broken :dark and HC
2021-01-11 16:00:32 +01:00
Matthias Clasen
01d19e2aa4
Merge branch 'fix-tablet-4' into 'master'
...
Wayland: ignore touch/tablet events on destroyed surfaces [GTK4]
See merge request GNOME/gtk!3065
2021-01-11 14:44:27 +00:00
Jakub Steiner
64e16ecaf1
Merge branch 'wip/jimmac/undercorated-active' into 'master'
...
Adwaita: less dramatic :active for undecorated buttons
Closes #3575
See merge request GNOME/gtk!3068
2021-01-11 14:37:58 +00:00
Jakub Steiner
6a047e53a8
Adwaita: less dramatic :active for undecorated buttons
...
Fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/3575
2021-01-11 15:00:38 +01:00
Jakub Steiner
31a7bc70c9
Adwaita: fix button border logic
...
- tint borders dark on non default / blue / red buttons
- just use plain $borders_color otherwise
- fixes HC/HCi
- ditch -alt buttons
2021-01-11 14:08:57 +01:00
Jakub Steiner
874cae1dab
Adwaita: flatter, lighter buttons
...
- lighten up for contrast, less of an oldschool gradient
Fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/3568
2021-01-11 13:50:32 +01:00
Jakub Steiner
7a3dd41dba
Adwaita: round progress and levelbars
2021-01-11 13:50:32 +01:00
Jakub Steiner
149962670a
Adwaita: :checked:active and checked:hover states
...
Fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/3560
2021-01-11 13:50:32 +01:00
Jakub Steiner
849e3c8b4b
Adwaita: flat scales, progressbars and level bars
2021-01-11 13:50:32 +01:00
Jakub Steiner
c9807f5afe
Adwaita: remove edge highlights
...
- flat is the name of the game
- kids scream make it flat
- simplify mixins
2021-01-11 13:50:32 +01:00
Carlos Garnacho
9a9899597c
Merge branch 'avoid-pointer-reset-gtk4' into 'master'
...
wayland: avoid set_cursor() when unchanged or invisible
Closes #3350
See merge request GNOME/gtk!3062
2021-01-11 12:07:01 +00:00
Matthias Clasen
fecb7af66e
Merge branch 'surface.compute.win32' into 'master'
...
Fix surface and geometry computation for Windows (Win32)
Closes #3480
See merge request GNOME/gtk!3067
2021-01-11 11:56:42 +00:00
Ignacio Casal Quinteiro
f5efb15cba
Support stylus devices on macos
2021-01-11 11:41:00 +01:00
Chun-wei Fan
d7d4fed0f3
gdk/win32: Fix window display and resizing
...
Have an implementation of ->request_layout() and ->compute_size() for the Win32
surface backend so that we can properly display and move and resize the
windows, as we request from the Win32 APIs.
Hxndling Aerosnap properly is mostly done except for snap_up(), which needs to
to be looked at later.
2021-01-11 17:55:25 +08:00
Chun-wei Fan
c2c2635763
gdk/win32: Rename 'margins' to 'shadow'
...
This improves consistency for the code.
2021-01-11 17:53:56 +08:00
Chun-wei Fan
fb33e83c96
gdkwin32-surface.c: Fix return type
...
gdk_win32_toplevel_present() should now be returning nothing, not a gboolean.
2021-01-11 17:53:47 +08:00
Chun-wei Fan
291ad17a22
gdksurface-win32.c: Decouple mapped state from surface creation
...
In line with what is done with the Wayland backend, enable the mapped state
independently as needed from the toplevel surface presentation, and also enable
the mapped state if necessary when presenting the popup surface.
2021-01-11 17:53:38 +08:00
Benjamin Otte
0f052d46b2
Remove guarantees we do not intend to hold
...
The fact that we are using gdk-pixbuf for loading files currrently does not mean we will use it going forward.
Also, "anything gdk-pixbuf can load" does not mean anything, because what gdk-pixbuf can load is a compile-time option.
As new_from_resource() will assert() if it cannot load a resource, we must be very sure that people do not use anything but PNG and JPEG for resources and the docs were not clear on that.
2021-01-10 21:37:03 +00:00
Asier Sarasua Garmendia
506423cf23
Update Basque translation
2021-01-10 18:00:26 +00:00
Asier Sarasua Garmendia
946a496a2e
Update Basque translation
2021-01-10 17:59:56 +00:00
Piotr Drąg
d20526570b
Update Polish translation
2021-01-10 18:27:55 +01:00
wisp3rwind
8312b9d9ca
Wayland: ignore touch/tablet events on destroyed surfaces
...
When destroying a wl_surface (e.g. when a window or menu is closed), the
surface may continue to exist in the compositor slightly longer than on
the client side. In that case, the surface can still receive input
events, which need to be ignored gracefully.
In particular, this prevents segfaulting on wl_surface_get_user_data()
in that situation.
Reported in
https://gitlab.gnome.org/GNOME/gtk/-/issues/3296
The same issue for pointers/keyboards was reported in
https://bugzilla.gnome.org/show_bug.cgi?id=693338
and fixed with in
bfd7137ffb
3625f17857
a8fc099a72
2021-01-10 12:31:37 +01:00
wisp3rwind
992f092968
wayland: avoid set_cursor() when unchanged or invisible
...
In pointer_surface_update_scale(), only rescale the cursor surface when
the scale has actually changed and the cursor is on at least one output.
fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/3350
Right now, this issue is not completely understood, so it might also
involve some questionable handling of cursor surface by sway/wlroots.
However, irrespective of that issue, this patch avoids unnecessary calls to the
compositor, and there should be no drawback: Whenever the pointer enters
a new output, pointer_surface_update_scale() will be called again, such
that correct scaling of the cursor is still ensured.
There is a slight difference: When the cursor leaves the last output,
previously the image was reset to scale factor 1. Now, it keeps whatever
was last. That might be more sensible than the previous behaviour,
assuming that it's likely that when the cursor enter an output again, it
has the same scaling. Alternatively, if one cares about resource usage
at this level, it might make more sense to destroy the surface than
rescaling to 1.
2021-01-09 11:42:59 +01:00
Matthias Clasen
60835227a1
4.0.1
2021-01-09 01:30:13 -05:00
Matthias Clasen
2b6b35d91f
build: Add a sassc feature
...
Add an option to disable css rebuilds. This allows
to build GTK from release tarballs (Which are including
the css) without a sassc dependency.
2021-01-09 01:30:13 -05:00
Matthias Clasen
897164c66c
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
Closes #3565
See merge request GNOME/gtk!3061
2021-01-09 03:56:59 +00:00
Matthias Clasen
441d944c08
droptarget: Some docs cleanups
...
Fixes #3565 , among other things.
2021-01-08 22:24:42 -05:00
Chun-wei Fan
2b8ad6c4b5
gtkffmediafile.c: Use g_snprintf()
...
Visual Studio 2013 is just shy of being sufficiently C99-compliant to
build GTK master, as it did not support snprintf() in its CRT
implementation.
Use g_snprintf() to cover for this.
2021-01-08 22:24:42 -05:00
Chun-wei Fan
99b2da4c47
gtk/gtksecurememoryprivate.h: Include glib.h
...
Some compilers somehow do not have `inline` defined, so include glib.h
to ensure that keyword is defined.`
2021-01-08 22:24:42 -05:00
Matthias Clasen
8243b5493b
a11y: Avoid __ prefixes for variable names
...
Seems that msvc does not like that.
2021-01-08 22:24:42 -05:00
Matthias Clasen
d5ef906cff
Merge branch 'nacho/seatdefault' into 'master'
...
Clean ups in seat default
See merge request GNOME/gtk!3057
2021-01-09 01:04:22 +00:00
Ignacio Casal Quinteiro
a720d8bc79
seatdefault: use g_clear_pointer to unref the tools
2021-01-08 13:11:56 +01:00
Ignacio Casal Quinteiro
57691eacc5
seatdefault: rename dispose method
2021-01-08 13:10:56 +01:00
Matthias Clasen
526e24f5b1
Merge branch 'wip/nacho/associated-device' into 'master'
...
gdkdevice: use g_set_object to set the associated device
See merge request GNOME/gtk!3049
2021-01-07 21:08:46 +00:00
Matthias Clasen
2a79152762
Merge branch 'mcatanzaro/company-unparent-warning' into 'master'
...
Add critical if widget has a parent during dispose
See merge request GNOME/gtk!3053
2021-01-07 18:37:28 +00:00
Matthias Clasen
f03acaf7ab
Merge branch 'mcatanzaro/unparent' into 'master'
...
Remove incorrect unparenting guidance from migration guide
See merge request GNOME/gtk!3050
2021-01-07 18:35:37 +00:00
Matthias Clasen
4e7ce9edcf
Merge branch 'mcatanzaro/gtkbuilder-docs' into 'master'
...
Improve GtkBuilder documentation
See merge request GNOME/gtk!3055
2021-01-07 18:00:19 +00:00
Matthias Clasen
ff72619333
Merge branch 'mcatanzaro/event-controller-porting-guide' into 'master'
...
Expand event controller API changes section of GTK 4 porting guide
See merge request GNOME/gtk!3054
2021-01-07 17:55:38 +00:00
Michael Catanzaro
59692599ea
Remove incorrect unparenting guidance from migration guide
...
This rule is almost always wrong, and we're having some trouble agreeing
on replacement text. Let's remove the whole paragraph for now, to avoid
confusion.
2021-01-07 11:39:53 -06:00
Benjamin Otte
4761641098
Add critical if widget has a parent during dispose
...
This is a refcounting bug. Be very verbose about it instead of trying to
call a function that releases a reference to the widget without
references.
2021-01-07 11:39:32 -06:00
Michael Catanzaro
afaa275dc8
gtkbuilder: fix recommendations that no longer make sense in GTK 4
...
In GTK 3, it was pretty much always better to use
gtk_builder_new_from_whatever() rather than
gtk_builder_add_from_whatever(). But in GTK 4, this is no longer
generally true. Let's add some context on when you want to use one or
the other.
2021-01-07 11:34:42 -06:00
Michael Catanzaro
c736deb83b
Add section on GtkBuilder API changes to GTK 4 migration guide
...
Thanks to Benjamin for helping with the language.
2021-01-07 11:34:42 -06:00
Emmanuele Bassi
e930a20522
Merge branch 'ebassi/ci-only' into 'master'
...
ci: Specify `only` for other jobs
See merge request GNOME/gtk!3052
2021-01-07 17:17:44 +00:00
Michael Catanzaro
137f32f9ef
Expand event controller API changes section of GTK 4 porting guide
...
There is more to say about changes to GtkEventController.
2021-01-07 10:53:09 -06:00
Emmanuele Bassi
195b98f19a
ci: Only run macOS job on upstream branches
...
Don't run CI on macOS for forks.
2021-01-07 16:14:04 +00:00
Emmanuele Bassi
87e0a28482
ci: Specify only for other jobs
...
Otherwise MRs will only run macOS jobs.
2021-01-07 16:13:59 +00:00
Ignacio Casal Quinteiro
3ca3d7efef
gdkdevice: use g_set_object to set the associated device
2021-01-07 16:13:39 +01:00
Matthias Clasen
d8d8322912
Merge branch 'wip/jimmac/flat-buttons' into 'master'
...
Adwaita: fine tune flat button styling
Closes #3481
See merge request GNOME/gtk!3046
2021-01-07 13:42:42 +00:00
Matthias Clasen
1ea1a70fd2
Merge branch 'wip/jimmac/hc-switch-border' into 'master'
...
HC: switch border color
Closes #3460
See merge request GNOME/gtk!3048
2021-01-07 13:41:40 +00:00
Matthias Clasen
1d5bc2838b
Merge branch 'wip/nacho/tool-api' into 'master'
...
seat: improve api to take into account the tool type
See merge request GNOME/gtk!3047
2021-01-07 13:25:11 +00:00
Ignacio Casal Quinteiro
45ec3fc389
seat: improve api to take into account the tool type
...
Otherwise if we have several tools with the same serial
and hardware id we might match the wrong tool.
2021-01-07 12:50:48 +01:00
Jakub Steiner
3a5eee7dbe
HC: switch border color
...
- lighten inverted HC borders while darkening the regular/light variant
Fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/3460
2021-01-07 12:44:53 +01:00
Jakub Steiner
0cda6f42b8
Adwaita: fine tune flat button styling
...
- enough contrast for hover and active, while noticably different in
normal nad headerbar context (and both light and dark variants).
Fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/3481
2021-01-07 12:12:55 +01:00
Matthias Clasen
0d99ef7cee
Merge branch 'X11-surface' into 'master'
...
x11: fix crash on idle compute size without layout
See merge request GNOME/gtk!3031
2021-01-06 22:13:02 +00:00
Matthias Clasen
7583810c90
Merge branch 'wip/exalm/headerbar' into 'master'
...
headerbar: Prepend start window controls instead of appending
See merge request GNOME/gtk!3044
2021-01-06 22:10:25 +00:00
Jordi Mas
1341bc0b19
Update Catalan translation
2021-01-06 22:42:44 +01:00
Alexander Mikhaylenko
fd073deea9
headerbar: Prepend start window controls instead of appending
...
Make sure they are always in the correct position.
2021-01-06 22:04:55 +05:00
Matthias Clasen
5652ab0a61
Merge branch 'macos-ci' into 'master'
...
Macos ci
See merge request GNOME/gtk!3032
2021-01-06 14:52:11 +00:00
Matthias Clasen
2ff23b08be
Merge branch 'wip/jimmac/headerbar-specialcasing' into 'master'
...
Adwaita: specialcase switches and scales for headerbars
Closes #3504
See merge request GNOME/gtk!3043
2021-01-06 14:40:36 +00:00
Matthias Clasen
0336af06f1
ci: Limit macos runs
...
We are building the full stack here, which is pretty expensive,
so only do it for merge requests and master.
2021-01-06 09:36:54 -05:00
Matthias Clasen
2af9f1ad62
Merge branch 'wip/jimmac/hc-dim-label' into 'master'
...
HC: special case .dim-label
Closes #3507
See merge request GNOME/gtk!3042
2021-01-06 13:04:24 +00:00
Jakub Steiner
e657da6658
Adwaita: specialcase switches and scales for headerbars
...
Fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/3504
2021-01-06 13:02:21 +01:00
Jakub Steiner
fd00aa98ea
HC: special case .dim-label
...
Fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/3507
2021-01-06 12:46:35 +01:00
Timm Bäder
de8a8d7bde
Merge branch 'dlech-master-patch-65287' into 'master'
...
doc: fix annotation for GtkCssLocation
See merge request GNOME/gtk!3041
2021-01-06 08:55:57 +00:00
David Lechner
eb6fbf907f
doc: fix annotation for GtkCssLocation
...
GtkCssLocation is a type so it should be prefixed with # rather than @.
2021-01-06 04:32:09 +00:00
Christian Hergert
4035f86b6d
macos: use deprecated NSOnState for older systems
2021-01-05 16:37:30 -08:00
Christian Hergert
855b44f2ed
macos: keep array of pasteboard types
...
To support Sierra, we need to have access to pasteboard types as a
NSString. Constants are provided in later versions of macOS, but we
can emulate that with an array which is initialized on first access.
2021-01-05 16:21:05 -08:00
Christian Hergert
f2e0097cac
gtk: fix brace initialization for bloom filter
...
This was breaking CI for macOS and it is a simple enough change to ensure
that just works for the internal buckets.
2021-01-05 16:21:05 -08:00
Christian Hergert
7c9bc7a204
macos: supply NSPasteboardType when necessary
...
On older macOS systems, we might need to provide our own typedef
for the NSPasteboardType. It is just a NSString pointer anyway.
2021-01-05 13:54:07 -08:00
Christian Hergert
f4f104c9f9
macos: fix typedef on older macOS
...
On older systems, we don't have a typedef for gravity. They are a NSString
pointer and we can provide that manually just fine.
2021-01-05 13:53:22 -08:00
Christian Hergert
28a6f0df05
macos: handle point conversion on older macOS
...
On older systems, the availability of some methods seem to be incorrect
based on Apple documentation. This works around the issue by using
the rect conversion on older systems.
2021-01-05 13:52:11 -08:00
Matthias Clasen
0eab4deab0
Merge branch 'media-caps' into 'master'
...
media: Be more specific in our caps
See merge request GNOME/gtk!3037
2021-01-05 21:34:27 +00:00
Matthias Clasen
6e8e467cc9
Merge branch 'simplify-toolbar' into 'master'
...
3to4: Remove GtkToolbar::toolbar_style
See merge request GNOME/gtk!3040
2021-01-05 19:35:46 +00:00
Matthias Clasen
ca9801f5fb
3to4: Remove GtkToolbar::toolbar_style
...
The property was removed (with the rest of the widget),
so keeping it around in the ui file makes no sense.
Testcase included.
2021-01-05 13:58:58 -05:00
Matthias Clasen
6b6fc1e5d8
Merge branch 'ebassi/migrating-clipboard' into 'master'
...
Ebassi/migrating clipboard
See merge request GNOME/gtk!3039
2021-01-05 18:41:27 +00:00
Emmanuele Bassi
e3641d0568
Merge branch 'dlech-master-patch-06007' into 'master'
...
docs: fix parameter reference in gtk_bitset_contains()
See merge request GNOME/gtk!3035
2021-01-05 18:10:59 +00:00
David Lechner
a5b88a53c2
docs: fix parameter reference in gtk_bitset_contains()
...
This fixes an error in the doc comments where the first parameter was
referred to as @bitset instead of @self.
2021-01-05 11:39:43 -06:00
Emmanuele Bassi
e4d0114e0d
docs: Add migration section for GtkClipboard
...
A simple copy/paste text example, plus directing people towards the
appropriate GType to replace the old convenience API.
2021-01-05 16:51:14 +00:00
Matthias Clasen
f974c5343e
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
See merge request GNOME/gtk!3038
2021-01-05 16:49:53 +00:00
Daniel Șerbănescu
bc39da0619
Updated the Romanian Translation
2021-01-05 17:38:02 +01:00
Emmanuele Bassi
1995b7f34b
docs: Preformat some symbols
2021-01-05 16:19:21 +00:00
Matthias Clasen
36eb7c40d0
gtk-demo: Small a11y fix
...
Label the entry in the assistant demo.
2021-01-05 11:16:10 -05:00
Matthias Clasen
56af472cfc
a11y: Only spew help once
...
Make GTK_A11Y=help only spew once, and avoid a warning
when we do.
2021-01-05 11:15:33 -05:00
Matthias Clasen
d1fcfa58b9
popup: Mention the popover arrow in the docs
...
Suggested by Jonas.
2021-01-05 10:59:59 -05:00
Matthias Clasen
cf23324749
Merge branch 'no-gl-context' into 'master'
...
Disable GL support in gstreamer media backend on Windows
See merge request GNOME/gtk!3034
2021-01-05 15:22:09 +00:00
Matthias Clasen
b79c26b39e
Merge branch 'wip/baedert/for-master' into 'master'
...
Wip/baedert/for master
See merge request GNOME/gtk!3029
2021-01-05 15:20:25 +00:00
Matthias Clasen
532b8c71a8
media: Be more specific in our caps
...
We can only handle 2D textures, so tell gstreamer
about that.
2021-01-05 09:28:04 -05:00
Matthias Clasen
7c5b8911d8
Merge branch 'matthiasc/for-master' into 'master'
...
some docs tweaks
See merge request GNOME/gtk!3036
2021-01-05 14:26:38 +00:00
Matthias Clasen
e141d61593
docs: Cosmetics
2021-01-05 08:37:23 -05:00
Matthias Clasen
9595d440cf
docs: Flesh out Popup layout docs
...
We have nice illustrations for this, lets use them.
2021-01-05 08:37:23 -05:00
Yuri Chornoivan
1063924bd0
Update Ukrainian translation
2021-01-05 08:08:44 +00:00
Timm Bäder
42fedfc870
csstokenizer: Keep a GString for name parsing around
...
We only every parse one of those at a time, so keep a GString around for
it. This way we don't have to create a new GString every time we parse
an identifier. Doesn't spare us the strdup though.
2021-01-05 08:53:13 +01:00
Timm Bäder
24836c0351
csstokenizer: Add separate init functions for token types
...
Using a variadic function is just awkward there. Use different init
functions and use them as appropriate; we already know which one to call
everywhere.
2021-01-05 08:53:13 +01:00
Timm Bäder
21b6c8b5d8
builder: Remove unused typedef
2021-01-05 08:53:13 +01:00
Timm Bäder
41fb6f6a8e
builder: Remove unused function prototype
2021-01-05 08:53:13 +01:00
Timm Bäder
071ea6b559
builderparser: Use GPtrArray for stack
2021-01-05 08:53:11 +01:00
Chun-wei Fan
397a71ca8b
gstreamer media backend: Disable OpenGL on Windows
...
...for at least WGL, since we are not allowed to use wglMakeCurrent(),
which is eventually called by gdk_gl_context_make_current() to share WGL
contexts across different threads, which will cause a crash.
This means, we cannot enable WGL in the gstreamer media backend on
Windows.
2021-01-05 14:34:06 +08:00
Matthias Clasen
40c10f83e2
Merge branch 'matthiasc/gl-media-stream' into 'master'
...
Use GL in the gstreamer media backend
See merge request GNOME/gtk!3027
2021-01-05 00:54:37 +00:00
Matthias Clasen
fb31581bb4
gtk-demo: Use GtkVideo in the fishbowl
...
The demo is called 'Video', so we should actually
use a GtkVideo widget. Doing things this way has
the advantage that we get GL support, which wasn't
working with GtkPicture.
2021-01-04 18:26:29 -05:00
Matthias Clasen
536a67ec96
media: Only force GL if we're using a GL renderer
...
When we are not using a GL renderer, getting GL textures
is no advantage to us, so don't make gstreamer send its
frames as GL memory in this case.
2021-01-04 15:01:19 -05:00
Matthias Clasen
53fe751371
media: Convince gstreamer to deliver GL memory
...
Use a glsinkbin to make gstreamer deliver GL memory.
2021-01-04 15:00:36 -05:00
Benjamin Otte
7901ab857b
media: Add support for OpenGL to GtkGstMediaFile
2021-01-04 15:00:36 -05:00
Matthias Clasen
8f585f7a53
video: Realize the media stream before setting a file
...
This makes it so that we obtain a GL context before
creating the GstSink, so we at least advertise our
ability to handle GL buffer.
Gstreamer still won't send us any.
2021-01-04 15:00:36 -05:00
Matthias Clasen
874b19b27e
Merge branch 'wip/jimmac/popover-separators' into 'master'
...
Adwaita: increase cotrast of popover separators
Closes #3535
See merge request GNOME/gtk!3033
2021-01-04 18:14:00 +00:00
Jakub Steiner
fe7b11b4e9
Adwaita: increase contrast of popover separators
...
Fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/3535
2021-01-04 17:55:44 +01:00
Yetizone
601dfeeff9
checkbutton: Add activate signal to work with gtk_widget_activate()
...
Fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/3525
Fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/3550
2021-01-04 17:25:53 +02:00
Matthias Clasen
cf623ce774
Merge branch 'window-geometry-info' into 'master'
...
gtk/window: remove GtkWindowGeometryInfo from public header file
See merge request GNOME/gtk!3028
2021-01-04 13:55:08 +00:00
Aurimas Černius
36b49950e8
Updated Lithuanian translation
2021-01-04 14:10:23 +02:00
Matthias Clasen
77feb51b9c
Pass coretext=enabled to harfbuzz
...
When we use harfbuzz as a subproject on OS X,
we (or rather, pango) need coretext support.
2021-01-03 21:34:04 -05:00
Matthias Clasen
710ef00dfe
Fix the cairo build on OS X
...
Change the subproject to point to a branch that includes
an OS X build fix. Once
https://gitlab.freedesktop.org/cairo/cairo/-/issues/441
is fixed, we should switch back to master.
2021-01-03 21:34:04 -05:00
Matthias Clasen
0c8124828f
ci: Disable pixman tests on MacOS
...
The pixman tests fail to build, and I don't have
the stamina to fix all sub-sub-projects, so just
disable the tests.
2021-01-03 21:34:04 -05:00
Matthias Clasen
0605c3c167
ci: Fix the harfbuzz build on MacOS
...
We need to force c++11 at the toplevel here, since
meson can't deal with per-project compiler choice.
2021-01-03 21:34:04 -05:00
Matthias Clasen
93d795e7c0
printing: Remove cairo header checks
...
cc.has_header doesn't work with subprojects, and all this
check does is to make the build fail, so we can just...
let the build fail instead.
2021-01-03 21:34:04 -05:00
Matthias Clasen
d55f938f7c
printing: cairo-pdf is needed
...
The print backends need cairos pdf support, which is
contingent on zlib, so enable that when using cairo
as a subproject, as we do in ci for MacOS.
2021-01-03 21:34:04 -05:00
Matthias Clasen
45bb4dc80c
ci: Add a macos build
...
Most of this is cribbed from glib.
We don't use COMMON_MESON_FLAGS here, since disabling
-Werror one subproject at a time is too painful for
all the promoted sub-sub-projects. This needs a better
solution in meson.
Since this is a full rebuild of the entire stack, limit
this to master and merge requests.
2021-01-03 21:34:04 -05:00
Rafostar
53af35d256
x11: fix crash on idle compute size without layout
...
On x11 toplevel layout is not created before toplevel
is presented, but GTK tries to update it on idle
which leads to a crash due to accessing property
of undefined object. Treat soon to be created layout
as a layout with default values upon creation (resizable).
2021-01-03 18:02:31 +01:00
Philipp Kiemle
51a6b29e01
Update German translation
2021-01-03 13:41:25 +00:00
Philipp Kiemle
e3835476ba
Update German translation
2021-01-03 13:40:13 +00:00
Timm Bäder
256b094b13
messagedialog: Modernize source file
...
Move vfunc implementations above class_init, remove unneeded prototypes,
properly indent everything and remove trailing whitespace
2021-01-03 11:01:29 +01:00
Timm Bäder
699adb0b10
widget: Refactor gtk_widget_class_set_template()
...
Don't call gbytes_get_data/get_size so often and exit early if the given
bytes is already precompiled.
2021-01-03 11:01:29 +01:00
Timm Bäder
c91b5eaa41
widget: Inline setup_template_child() into only caller
...
This is a pretty short and self-contained function.
2021-01-03 11:01:29 +01:00
Timm Bäder
7e1f20bf4c
icontheme: Make a parameter const
2021-01-03 11:01:29 +01:00
Timm Bäder
f9fe640905
settings: Overallocate property_values
...
Instead of walking the pspecs twice and checking for the owner_type,
just allocate n_pspecs entries. They are the same value right now
anyway, but even if they aren't it doesn't hurt to have a few extra ones
allocated.
2021-01-03 11:01:29 +01:00
Timm Bäder
34ea99006f
settings: Load keyfiles ourselves
...
This does not change anything in the case where the .init file does not
exist. We still hit the disk once. Otherwise, we now only hit it once
instead of twice and avoid a potential race-condition.
2021-01-03 11:01:29 +01:00
Timm Bäder
06cce81a97
widget: Use gtk_widget_get_native() in get_surface_allocation()
2021-01-03 11:01:29 +01:00
Timm Bäder
4a1a7940d5
gtksettings: Remove unused defines
2021-01-03 11:01:29 +01:00
Timm Bäder
1108d00014
render: Inline function into only caller
2021-01-03 11:01:29 +01:00
Timm Bäder
034672e84e
frame: Remove unnecessary function
...
Just call the vfunc directly in the only place we used to call the old
wrapper
2021-01-03 11:01:29 +01:00
Timm Bäder
00c885c93c
gesture: Replace tabs
2021-01-03 11:01:29 +01:00
Timm Bäder
114f0bd8d6
box: Replace tabs with spaces
2021-01-03 11:01:29 +01:00
Timm Bäder
24c67efdfd
scrolledwindow: Use g_clear_handle_id
2021-01-03 11:01:29 +01:00
Timm Bäder
6a3748146d
viewport: Small cleanup
...
No need to check for visibility before calling gtk_widget_measure().
2021-01-03 11:01:29 +01:00
Timm Bäder
92ec754737
widget: Move quark_builder_set_id declaration to other GQuarks
2021-01-03 11:01:29 +01:00
Timm Bäder
d11fbbc478
widget: Re-arrange some more functions
2021-01-03 11:01:29 +01:00
Timm Bäder
f11f0da11c
wiget: Fix whitespace issues
...
Switch from tabs to spaces everywhere consistently and remove all
trailing whitespace.
2021-01-03 11:01:29 +01:00
Timm Bäder
ebdf2989f8
widget: Move a few vfunc implementations above class_init
...
And save us the prototypes at the top of the file this way.
2021-01-03 11:01:29 +01:00
Timm Bäder
bc35c5d494
nevertrigger: Remove unused instance members
2021-01-03 11:01:29 +01:00
Timm Bäder
70a3e5e8ce
shortcutmanager: Use g_list_store_find()
...
We require glib 2.66 these days, so we can unconditionally use
g_list_store_find().
2021-01-03 11:01:29 +01:00
Timm Bäder
74ff61a937
gesturelongpress: Remove a useless cast
...
We already get a GtkGestureLongPress here.
2021-01-03 11:01:29 +01:00
Timm Bäder
280d7e57bd
gesturelongpress: Keep the pspec around
...
So we can use it to notify(), like we do everywhere else.
2021-01-03 11:01:29 +01:00
Timm Bäder
03f5a368ec
label: Remove unused private functions
2021-01-03 11:01:29 +01:00
Timm Bäder
0b15aba82a
label: Remove mnemonics_visible_apply_recursively from private header
...
This is only used in gtklabel.c
2021-01-03 11:01:28 +01:00
Timm Bäder
d8fa9de93a
label: Modernize source file
...
Try to sort toplevel functions to minimize unnecessary function
prototypes at the beginning of the file, get rid of all tabs and
trailing whitespace.
2021-01-03 11:01:28 +01:00
Timm Bäder
afabbc4957
gtk4-demo: Remove unused size group
2021-01-03 11:01:28 +01:00
Timm Bäder
d978ba31d6
glcontext-wayland: Whitespace
2021-01-03 11:01:28 +01:00
Timm Bäder
71efa96ef2
gesturestylus: Only add histroy element if translation succeeded
...
Instead of always doing it and then undoing it if the translation does
not succeed.
2021-01-03 11:01:28 +01:00
Timm Bäder
e336fe2bf8
gesturestylus: Retrieve event and controller widget only once
...
Make it clear that these are not gonna chance while iterating the loop.
2021-01-03 11:01:28 +01:00
Timm Bäder
d7f15c15e9
glcontext-wayland: Avoid heap-alloacting small arrays...
...
every frame.
2021-01-03 11:01:28 +01:00
Timm Bäder
fff570538c
glcontext-wayland: Only allocate configs we use
...
We only use the first one, so don't allocate space for more than that.
2021-01-03 11:01:28 +01:00
Matthias Clasen
38166a67c7
NEWS: Updates
2021-01-02 20:17:19 -05:00
Matthias Clasen
01b94db73d
Merge branch 'matthiasc/for-master' into 'master'
...
video: Tweak the docs
See merge request GNOME/gtk!3026
2021-01-02 19:04:26 +00:00
Matthias Clasen
c804645382
video: Tweak the docs
...
Point out the limitations and use cases of GtkVideo
and mention that GtkPicture can display video just fine.
2021-01-02 12:21:03 -05:00
Matthias Clasen
384081ce0a
Merge branch 'matthiasc/for-master' into 'master'
...
video: Pause on unset too
See merge request GNOME/gtk!3025
2021-01-02 15:49:46 +00:00
Florentina Mușat
afccb86f7e
Update Romanian translation
2021-01-02 11:21:43 +00:00
Matthias Clasen
0ba5631100
video: Pause on unset too
...
When new media stream is set on the GtkVideo
widget and we're autoplaying, pause the old one.
Otherwise, the music keeps playing unexpectedly.
2021-01-02 01:33:48 -05:00
Matthias Clasen
c72589f0ee
Merge branch 'wip/chergert/fix-macos-compute-size' into 'master'
...
macos: fix compute_size and request_layout
Closes #3532
See merge request GNOME/gtk!3023
2021-01-01 23:33:01 +00:00
Matthias Clasen
f2e5775380
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
Closes #3506 and #3530
See merge request GNOME/gtk!3024
2021-01-01 22:48:11 +00:00
Benjamin Otte
a7164208d3
Merge branch 'video-stop' into 'master'
...
video: Stop playing when appropriate
See merge request GNOME/gtk!3022
2021-01-01 21:54:22 +00:00
Matthias Clasen
20f3d1608d
video: Be consistent about play/pause
...
Always check that the stream is prepared, and the
widget is mapped, before calling gtk_media_stream_play().
2021-01-01 16:25:54 -05:00
Christian Hergert
9320148d71
macos: implement compute_size and request_layout
...
These functions were not implemented when the sizing changes
landed before GTK 4 was released. This fixes an issue with non-
resizeable windows not reacting to layout changes.
Fixes #3532
2021-01-01 13:17:47 -08:00
Christian Hergert
ad617a0e06
macos: avoid setHasShadow unless shadow changes
2021-01-01 13:17:47 -08:00
Christian Hergert
62af8365f6
macos: fix toplevel present function prototype
...
No need to return anything here.
2021-01-01 13:17:47 -08:00
Matthias Clasen
29afe5a688
video: Stop playing when appropriate
...
When the widget gets unrealized or hidden, pause
the mediastream. Otherwise, audio might keep playing
unexpectedly.
2021-01-01 15:17:59 -05:00
Matthias Clasen
2d3885a44a
center layout: Fix handling of expanding center child
...
We were not taking spacing into account when adjusting
the size of an expanding center child, causing it to slip
under the end child at times.
Fixes : #3506
2021-01-01 11:02:57 -05:00
Matthias Clasen
75a297632e
Merge branch 'wip/chergert/fix-macos-window-check' into 'master'
...
macos: ensure GdkMacosWindow in surface discovery
Closes #3533
See merge request GNOME/gtk!3021
2021-01-01 15:39:08 +00:00
Matthias Clasen
572649740e
docs: Flesh out the gtk4-builder-tool man page
...
Add some details about the --3to4 conversion, and
set expectations.
2021-01-01 10:14:01 -05:00
Yuri Chornoivan
b5938faa06
Update Ukrainian translation
2021-01-01 14:50:35 +00:00
Matthias Clasen
a4baac7193
docs: Complete a sentence
...
Fixes : #3530
2021-01-01 09:40:40 -05:00
Matthias Clasen
bdde41e290
Merge branch 'encode-symbolic-debug' into 'master'
...
gtk4-encode-symbolic: Add debug output
See merge request GNOME/gtk!3017
2021-01-01 14:23:08 +00:00
Christian Hergert
d888402bf9
macos: ensure GdkMacosWindow in surface discovery
...
We want to ignore windows that are not related to those controlled
by the GDK backend.
Fixes #3533
2020-12-31 10:55:50 -08:00
Christian Hergert
378bd9fab2
Merge branch 'macos-mojave' into 'master'
...
macos: do not crash in mojave
See merge request GNOME/gtk!3020
2020-12-31 18:13:46 +00:00
Ignacio Casal Quinteiro
4ad5e77907
macos: do not crash in mojave
...
The localizedName property is not available in Mojave
so just ifdef in that case the code out.
2020-12-31 11:35:04 +01:00
David Lechner
4fb70c5e4d
gtk/window: remove GtkWindowGeometryInfo from public header file
...
GtkWindowGeometryInfo is only used by static methods in gtkwindow.c
so it doesn't need to be in the public header file.
2020-12-30 01:32:27 -06:00
Matthias Clasen
d5963ad109
Merge branch 'revert-224c2674' into 'master'
...
Revert "Merge branch 'gtk_egl_wayland' into 'master'"
See merge request GNOME/gtk!3018
2020-12-30 03:34:51 +00:00
Matthias Clasen
b5fe434fea
Revert "Merge branch 'gtk_egl_wayland' into 'master'"
...
This reverts merge request !3011
2020-12-30 03:32:18 +00:00
Matthias Clasen
224c2674ab
Merge branch 'gtk_egl_wayland' into 'master'
...
Expose gdk_wayland_surface_get_wl_egl_window()
See merge request GNOME/gtk!3011
2020-12-30 03:32:05 +00:00
Matthias Clasen
878b34fae3
gtk4-encode-symbolic: Add debug output
...
Add a --debug option that makes this tool produce
some debug output that can be helpful in tracking
down why symbolic svgs are broken.
2020-12-29 21:30:52 -05:00
Matthias Clasen
5fe433418d
Merge branch 'mcatanzaro/#3509' into 'master'
...
message dialog: use title style only if there is secondary text
Closes #3509
See merge request GNOME/gtk!3015
2020-12-29 17:47:01 +00:00
Matthias Clasen
02ba9bc1da
Merge branch 'fix-menu-alignment' into 'master'
...
Fix menu item alignment with submenus
See merge request GNOME/gtk!3016
2020-12-29 17:41:49 +00:00
Michael Catanzaro
2336120010
message dialog: use title style only if there is secondary text
...
If there is no secondary text, then the primary text is just a message,
not a title, and should not use title style.
This partially reverts 1e3ec7c1f9 . The
message dialog nown looks like it used to in GTK 3. However, it's still
styled only using a style class rather than using pango markup, as in
GTK 3.
Fixes #3509
2020-12-29 11:15:14 -06:00
Matthias Clasen
0d54d73a51
Fix menu item alignment with submenus
...
We were not aligning model button labels with nesting
submenus with indicators in their containing menu.
This was visible in the application demo of gtk4-demo.
2020-12-29 12:10:35 -05:00
Timm Bäder
6c09832b9b
Merge branch 'xndcn/fix-shader' into 'master'
...
gl: Fix implicit leaking of shader object
See merge request GNOME/gtk!3013
2020-12-29 16:58:55 +00:00
Matthias Clasen
1758f88492
Merge branch 'ebassi/issue-3522' into 'master'
...
Fix the Vulkan header check for VK_RESULT_RANGE_SIZE
Closes #3522
See merge request GNOME/gtk!3009
2020-12-29 16:36:09 +00:00
xndcn
34ffdc6e3f
gl: Fix implicit leaking of shader object
...
According to OpenGL spec, a shader object will only be flagged
for deletion unless it has been detached; when a program object
is deleted, those shader objects attached to it will be detached
but not deleted unless they have already been flagged for deletion.
So we shall detach a shader object before it is deleted, and delete
it before the program object is deleted best.
2020-12-29 23:50:45 +08:00
Timm Bäder
108933b655
Merge branch 'wip/chergert/volatile-fixes' into 'master'
...
types: fix various use of volatile in type registration
See merge request GNOME/gtk!2865
2020-12-29 07:49:12 +00:00
Vivek Kasireddy
3344bcaf92
gdk/wayland/surface: Expose gdk_wayland_surface_get_wl_egl_window()
...
Some GTK based applications such as Qemu UI create and manage
EGLSurfaces associated with the relevant GdkSurfaces. In order to create
an EGLSurface, there needs to be a way to pass the native window
object to eglCreateWindowSurface(). While running in an X environment,
the native window object can be obtained by calling
gdk_x11_surface_get_xid(). Likewise, the native window object can be
obtained by calling gdk_wayland_surface_get_wl_egl_window() while
running in a Wayland environment. Therefore, this API needs to be
exposed to apps.
Signed-off-by: Vivek Kasireddy <vivek.kasireddy@intel.com >
2020-12-28 18:20:04 -08:00
Emmanuele Bassi
f22ec063a1
Fix the Vulkan header check for VK_RESULT_RANGE_SIZE
...
The VK_RESULT_RANGE_SIZE enumeration value was removed in 1.2.140, not
1.2.142.
Fixes : #3522
2020-12-28 18:41:18 +00:00
Benjamin Otte
0fcf01ddd5
Merge branch 'gtkmediafile-pixel-aspect-ratio' into 'master'
...
gtkmediafile: Consider pixel-aspect-ratio for rendering video with the correct aspect ratio
Closes #3516
See merge request GNOME/gtk!3007
2020-12-28 14:54:30 +00:00
Asier Sarasua Garmendia
1119a74ff0
Update Basque translation
2020-12-27 17:56:02 +00:00
Sebastian Dröge
18ea60e235
gtkmediafile: Consider pixel-aspect-ratio for rendering video with the correct aspect ratio
...
Fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/3516
2020-12-27 19:33:55 +02:00
Matthias Clasen
d752828977
Merge branch 'wip/jtojnar/trivial-fix-pc-vulcan' into 'master'
...
build: Fix vulkan reference in pc file
Closes #3517
See merge request GNOME/gtk!3006
2020-12-27 17:06:52 +00:00
Fran Dieguez
1034271d9a
Update Galician translation
2020-12-27 16:56:56 +00:00
Fran Dieguez
f013d3b5d6
Update Galician translation
2020-12-27 16:51:38 +00:00
Benjamin Otte
5f41d26abc
Merge branch 'gtkgstsink-unmap-only-when-done' into 'master'
...
gtkmediafile: Only unmap the GstVideoFrame in the GBytes destroy notify
See merge request GNOME/gtk!3003
2020-12-27 06:17:36 +00:00
Jan Tojnar
7d5826ccf7
build: Fix vulkan reference in pc file
...
A mistake in string concatenation caused the vulcan dependency to be omitted.
Fixes: https://gitlab.gnome.org/GNOME/gtk/-/issues/3517
2020-12-27 06:42:29 +01:00
Jan Tojnar
2c9f2325e2
build: Use Meson’s module for building .pc files
...
Using the module will prevent trivial bugs caused by incorrect string concatenation.
This is just a literal translation. In the future we might rely on Meson auto-detecting fields from library declaration.
Fixes: https://gitlab.gnome.org/GNOME/gtk/-/issues/3517
2020-12-27 06:27:59 +01:00
Matthias Clasen
daded2bc86
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
See merge request GNOME/gtk!3004
2020-12-27 05:21:26 +00:00
Matthias Clasen
bc7619abaf
Merge branch 'gtkclip' into 'master'
...
gtk: remove GtkClipboard leftovers
See merge request GNOME/gtk!2991
2020-12-27 04:32:26 +00:00
Matthias Clasen
459d6e1349
Merge branch 'wip/carlosg/for-master' into 'master'
...
gtk/gesturestylus: Convert motion history from surface coordinates
Closes #3491
See merge request GNOME/gtk!2999
2020-12-27 04:30:38 +00:00
Sebastian Dröge
6e108d310a
gtkmediafile: Only unmap the GstVideoFrame in the GBytes destroy notify
...
The memory pointed to by GstVideoFrame::plane_data becomes invalid after
unmapping causing the GBytes to point at some random memory if the
unmapping is not deferred until its destroy notify.
When the GStreamer buffer is backed by normal system memory this is not
a problem but if it is backed by e.g. an OpenGL texture, dmabuf or some
other hardware-specific memory this will otherwise cause interesting
problems.
2020-12-26 14:26:23 +02:00
Benjamin Otte
9c84fa127a
Merge branch 'unused-static-inline' into 'master'
...
Remove unused static inline function
See merge request GNOME/gtk!3002
2020-12-25 18:05:11 +00:00
Emmanuel Gil Peyrot
84c6708366
Remove unused static inline function
...
This was causing a warning on AArch64 since __LITTLE_ENDIAN__ and
__BIG_ENDIAN__ weren’t set, but the functions were actually completely
unused.
2020-12-25 16:16:43 +01:00
Benjamin Otte
f7e3016949
Merge branch 'gles-gears' into 'master'
...
Fix gtk4-demo’s gears demo on OpenGL ES
See merge request GNOME/gtk!3000
2020-12-25 01:36:34 +00:00
Emmanuel Gil Peyrot
dd1110ca5c
Fix some of gtk4-demo’s transitions example on OpenGL ES
...
Same issue as the previous commit, int+float is error, and pow() only
works on floats.
2020-12-25 01:36:21 +01:00
Emmanuel Gil Peyrot
28c4adac24
Fix gtk4-demo’s gears demo on OpenGL ES
...
Here is a command to reproduce this testcase:
GDK_DEBUG=gl-gles gtk4-demo --run gears
Without this patch, Mesa throws this compile error:
0:130(13): error: no matching function for call to `mod(error, float)'; candidates are:
This is caused by `u_rotation - 90` being of type error since
`u_rotation` is a float and it’s illegal to subtract it with an integer.
2020-12-25 01:21:08 +01:00
Carlos Garnacho
cf20cfd31e
gtk/gesturestylus: Convert motion history from surface coordinates
...
Motion history coordinates are based on GdkSurface coordinates. Transform
the coordinates from the GtkNative they are received on, accounting for the
possible transforms (e.g. due to window borders and shadows).
Fixes: https://gitlab.gnome.org/GNOME/gtk/-/issues/3491
2020-12-24 19:59:51 +01:00
Matthias Clasen
7e579bb59a
Merge branch 'wip/otte/for-master' into 'master'
...
Wip/otte/for master
See merge request GNOME/gtk!2997
2020-12-24 07:13:22 +00:00
Benjamin Otte
96e1b85c2c
gdkarray: Add a "stolen" boolean to splice()
...
If set to TRUE, does not call the free func for the removed items.
This can be used to move items between arrays without having to do the
refcounting dance.
2020-12-24 06:38:45 +01:00
Benjamin Otte
71e616d17e
listview: Use the correct scroll policy
...
Use the horizontal policy for horizontal decisions, not the vertical
one.
This broke in 0011ce949c .
2020-12-24 06:38:45 +01:00
Benjamin Otte
f85d939e5e
docs: Put render nodes in their own sections
2020-12-24 06:38:45 +01:00
Benjamin Otte
8d014d6cb0
roundedbox: Remove unused API
2020-12-24 06:38:45 +01:00
Benjamin Otte
f7f8990f7a
picture: Fix copy/paste error in docs
2020-12-24 06:38:45 +01:00
Benjamin Otte
d6f288427a
video: When autoplaying, start playing once the video is prepared
...
This fixe video sources with longer loading times not automatically
playing.
2020-12-24 06:38:45 +01:00
Benjamin Otte
2a8f371643
gtk-demo: Don't put the search bar in the scroll area
...
1. That's a bad idea UI wise as you can't see the search after you
scrolled.
2. That's a bad idea code-wise because Listviews need to be put into
a ScrolledWindow or they won't scroll.
2020-12-24 06:38:45 +01:00
Benjamin Otte
dee863dbb2
rendernode: Bail if matrix is invalid
...
Invalid matrices are okay in GSK (and GL), but not in Cairo.
Testcase included.
2020-12-24 06:38:45 +01:00
A S Alam
7d6877ec80
Update Punjabi translation
2020-12-23 19:48:28 +00:00
Danial Behzadi
f426d23690
Update Persian translation
2020-12-23 15:53:07 +00:00
Matthias Clasen
6bd0dc3e78
colorbutton: Correct the css docs
...
Mention the wrapper colorbutton node.
2020-12-23 09:03:07 -05:00
Matthias Clasen
4f0c920a8e
fontbutton: Correct the css docs
...
Mention the wrapper fontbutton node.
2020-12-23 08:59:58 -05:00
Matthias Clasen
b0b793dd94
menubutton: Correct the css docs
...
We are using menubutton instead of button.popup now.
2020-12-23 08:56:18 -05:00
Matthias Clasen
efbb649eee
modelbutton: Center titles
...
The centering of titles was broken in b5b81dea7f .
Make it mostly work again by adding an empty end indicator.
Related: #3405
2020-12-23 00:51:51 -05:00
Matthias Clasen
e128a77eed
Merge branch 'matthiasc/for-master' into 'master'
...
window: Release application in destroy
See merge request GNOME/gtk!2994
2020-12-23 03:01:55 +00:00
Matthias Clasen
5cd2ee927a
window: Release application in destroy
...
We used to do this; it was lost in some life-cycle
reshuffling.
2020-12-22 20:34:13 -05:00
Marc-André Lureau
90dfb5e138
gtk: remove GtkClipboard leftovers
...
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com >
2020-12-22 16:39:54 +04:00
Matthias Clasen
e854b90293
Merge branch 'wip/baedert/for-master' into 'master'
...
Wip/baedert/for master
See merge request GNOME/gtk!2990
2020-12-22 04:53:31 +00:00
Matthias Clasen
6d042d9e61
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
See merge request GNOME/gtk!2988
2020-12-22 02:29:03 +00:00
Matthias Clasen
4310f24a4e
Fix warnings with Vulkan < 162
...
Tiring to watch the Vulkan people stumble through
ABI and API compat, but what can you do.
2020-12-21 20:00:16 -05:00
Matthias Clasen
aebf8e3c29
Merge branch 'mcatanzaro/fix-gtk-builder-tool' into 'master'
...
Fix buffer overruns in 'gtk-builder-tool simplify'
See merge request GNOME/gtk!2987
2020-12-21 22:49:42 +00:00
Matthias Clasen
fcd449f0d4
modelbutton: Remove an unused field
...
We're not using the centered field anymore.
2020-12-21 17:45:01 -05:00
Michael Catanzaro
ab1b117d91
Fix buffer overruns in 'gtk-builder-tool simplify'
...
Oops, here we allocate only one byte for each pointer we want to store.
We need to multiply by the size of a pointer.
2020-12-21 15:39:34 -06:00
Emmanuele Bassi
1253296387
Merge branch 'fix-printbackends' into 'master'
...
Fix the value for the print-backends setting
Closes #3486
See merge request GNOME/gtk!2986
2020-12-21 20:04:26 +00:00
Matthias Clasen
466484176f
Merge branch 'ebassi/docs-for-master' into 'master'
...
Ebassi/docs for master
See merge request GNOME/gtk!2983
2020-12-21 19:22:38 +00:00
Matthias Clasen
20289ad8e1
Fix the value for the print-backends setting
...
This was broken in the meson conversion, causing
us to default to "" instead of the built print
backends.
Fixes : #3486
2020-12-21 14:10:03 -05:00
Matthias Clasen
0abb8c6862
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
See merge request GNOME/gtk!2984
2020-12-21 19:00:10 +00:00
Matthias Clasen
147386189f
inspector: Show glyphs as in node files
...
Reuse the glyph serialization code from gsk to
show glyphs in the same way here.
2020-12-21 13:11:46 -05:00
Matthias Clasen
9cec9e4ce2
gsk: Export the glyph serialization privately
...
We want to use the same serialization in the inspector,
so export this function.
2020-12-21 13:11:08 -05:00
Matthias Clasen
26119af7a6
gsk: Improve glyph serialization
...
The special case for ASCII glyphs is unfortunately not
working very well, because of an oversight in pango:
When I added subpixel positioning, I made pango_shape()
default to not rounding, and make PangoLayout call
pango_shape_with_flags() and pass the rounding information
down. The upshot is that we need to use the _with_flags
variant here and tell it to round position, so it matches
what the text node contains.
2020-12-21 13:08:34 -05:00
Timm Bäder
478d1f71e3
Merge branch 'fix-node-glyphs' into 'master'
...
gsk: Fix serialization of glyphs
Closes #3496
See merge request GNOME/gtk!2982
2020-12-21 17:16:38 +00:00
Emmanuele Bassi
b1d952b8a2
docs: Add examples for GtkDropTarget
...
Like we did for GtkDragSource.
2020-12-21 17:11:42 +00:00
Emmanuele Bassi
b9bcdbbfdc
docs: Add examples of GtkDragSource use
...
The description is a bit terse; we should help out application
developers some more.
2020-12-21 17:03:59 +00:00
Emmanuele Bassi
6c31ed53f4
docs: Fix typo and whitespace
2020-12-21 17:03:42 +00:00
Matthias Clasen
aa95ae774f
gsk: Fix serialization of glyphs
...
We were forgetting to put a space between two numbers
in some cases, confusing the parser.
Test included.
Fixes : #3496
2020-12-21 10:49:56 -05:00
Emmanuele Bassi
65adfd9243
Merge branch 'box_docs' into 'master'
...
box: improve documentation
Closes #3499
See merge request GNOME/gtk!2981
2020-12-21 15:40:07 +00:00
Yetizone
c4a8c0893b
box: improve documentation
...
Rephrase a function parameter description and remove "." from all function parameters descriptions
Fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/3499
2020-12-21 17:26:23 +02:00
Timm Bäder
e90f5e8a20
gskpango: Don't copy fg color
...
No need to do that here, we copy it in to the individual render nodes
anyway.
2020-12-21 15:23:25 +01:00
Timm Bäder
526c76181e
gl renderer: Check for pointer equality in rounded_rect_equal
2020-12-21 15:22:08 +01:00
Timm Bäder
cf352374ae
gskpango: Correct a comment
...
Not all other draw calls will use cairo.
2020-12-21 13:23:28 +01:00
Timm Bäder
98b99201b0
gskpango: Remove bounds rect
...
We only need this to render shapes and trapezoids, i.e. only when
falling back to cairo. Remove code to measure the layout and convert the
ink_rect to a graphene_rect_t from gtk_snapshot_append_layout() and do
it when drawing shapes and trapezoids instead.
2020-12-21 12:56:38 +01:00
Timm Bäder
bce4d669ee
gskpango: Fix a potential cairo_t leak
...
The previous early return did not cairo_destroy() it.
2020-12-21 12:49:06 +01:00
Timm Bäder
e7a326e230
label: Refactor get_layout_location()
...
Rename a few local variables to be clearer about whether they belong to
the widget or to the layout.
Remove a workaround for an old bug that is no longer valid. We don't
underallocate the layout anymore. Aways center vertically, with respect
to the yalign.
2020-12-21 12:44:01 +01:00
Timm Bäder
9eaeaa8452
label: Refactor snapshot()
...
Use two early-out style if statements to reduce indentation in this
entire function.
2020-12-21 12:32:32 +01:00
Timm Bäder
2031c5bf90
textlayout: Remove dead offset_y code
2020-12-21 10:26:03 +01:00
Timm Bäder
9fefa7b44c
rendernode: Different uniformity in border nodes
...
Means they are different and a diff is impossible.
2020-12-21 10:26:03 +01:00
Timm Bäder
a2a70c3b65
rendernode: Sort diff() requirements by complexity
2020-12-21 10:26:03 +01:00
Timm Bäder
0b4ed8d791
renderborder: Avoid 0 width outline color nodes
2020-12-21 10:26:03 +01:00
Timm Bäder
c34f98931e
layoutoverlay: Avoid adding transparent color nodes
...
We have a region for the border here, but the color is defined as
transparent black because we don't want to render anything for it.
This way, the generated .node file for the listbox demo in gtk4-demo
with enabled layout borders is 3.5MB instead of 3.8MB.
2020-12-21 10:26:03 +01:00
Timm Bäder
2feac2772f
layoutoverlay: Avoid adding 0 sized color nodes
...
This way, the output node file of the listbox demo in gtk4-demo with
enabled layout borders is only 3.8MB instead of 12MB.
2020-12-21 10:26:03 +01:00
Timm Bäder
fdda4e4e99
GskTransform: Add nullable annotations to _equals()
...
Both can be NULL here.
2020-12-21 10:26:03 +01:00
Timm Bäder
e1cf0cff26
gl renderer: Proper state tracking for color matrix ops
2020-12-21 10:26:03 +01:00
Timm Bäder
634fa772c9
gl renderer: Add missing debug output for repeat ops
2020-12-21 10:26:03 +01:00
Timm Bäder
4b3bbe0ecd
gl renderer: Create shader-global uniform ops on draw()
...
This way we can render the first frame of tests/testoutsetshadowdrawing
in 153 ops instead of 183.
And the first frame of gtk4-demo in 260 instead of 300.
2020-12-21 10:26:03 +01:00
Timm Bäder
cde43541d0
gl renderer: Unify new clip/viewport rects in blur_texture()
2020-12-21 10:26:03 +01:00
Timm Bäder
186287ecfb
GskTransform: Fix identity transform class name
2020-12-21 10:26:02 +01:00
Timm Bäder
bd5d1615ac
GskTransform: Avoid a ref+unref pair
...
If gsk_transform_is_identity() returned FALSE for the next transform,
the previous code did a ref + unref pair, even though it was unneeded.
2020-12-21 10:26:02 +01:00
Timm Bäder
21299cc7e4
icontheme: Make some constant values const
2020-12-21 10:26:02 +01:00
Timm Bäder
e747ea7dfd
pixbufutils: Only convert icon size to string once
2020-12-21 10:26:02 +01:00
Timm Bäder
810cd7881e
icontheme: Make icon_paintable_ensure_texture() return an unowned value
...
It's private, has only one caller and that one doesn't need the extra
ref.
2020-12-21 10:26:02 +01:00
Timm Bäder
a8213d7f45
gl renderer: Avoid setting modelview to identical values
...
The previous comment here was incorrect. We can save the op itself, we
just can't save us the entry in the modelview stack.
2020-12-21 10:26:02 +01:00
Timm Bäder
e6f6d1e478
main: Add & use gdk_event_dup_axes()
...
The way this code is written trips up scan-build. Add
gdk_event_dup_axes() and use it in gtkmain.c.
2020-12-21 10:26:02 +01:00
Rafael Fontenelle
933d241bba
Update Brazilian Portuguese translation
2020-12-21 07:02:13 +00:00
Matthias Clasen
7249c3a09b
Merge branch 'ebassi/issue-3495' into 'master'
...
Use full path when calling gtk4-update-icon-cache
Closes #3495
See merge request GNOME/gtk!2979
2020-12-20 22:40:48 +00:00
Emmanuele Bassi
d13f8ac3a9
Call the newly installed gtk4-update-icon-cache
...
Otherwise we rely on whatever it's inside the PATH.
2020-12-20 16:33:41 +00:00
Emmanuele Bassi
fa35e3b874
Pass the bindir to the post-install script
2020-12-20 16:33:25 +00:00
Rafael Fontenelle
853883c6e5
Update Brazilian Portuguese translation
2020-12-20 14:06:52 +00:00
sicklylife
b467279c7d
Update Japanese translation
2020-12-20 08:03:00 +00:00
sicklylife
c6a5ac1d16
Update Japanese translation
2020-12-20 07:58:09 +00:00
A S Alam
e41288de4f
Update Punjabi translation
2020-12-20 06:14:42 +00:00
Jordi Mas i Hernandez
b886988a54
Update Catalan translation
2020-12-19 18:29:08 +00:00
Matthias Clasen
bb8a459fe2
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
See merge request GNOME/gtk!2978
2020-12-19 17:20:39 +00:00
Matthias Clasen
d5143a1bf0
Revert "gl renderer: Render too big textures to the clipped area"
...
This reverts commit 7f6608cbed .
2020-12-19 11:43:56 -05:00
Matthias Clasen
12611fa142
Revert "gl renderer: Take a out graphene_rect in blur_node()"
...
This reverts commit 7eece7e769 .
2020-12-19 11:43:43 -05:00
Matthias Clasen
3e319b409b
Merge branch 'ebassi/issue-3492' into 'master'
...
3to4: Remove GtkCheckButton:draw-indicator
Closes #3492
See merge request GNOME/gtk!2976
2020-12-19 16:41:14 +00:00
Emmanuele Bassi
f2b16836c2
3to4: Add test for GtkCheckButton:draw-indicator removal
2020-12-19 15:52:22 +00:00
Emmanuele Bassi
14bf45a0d5
3to4: Remove GtkCheckButton:draw-indicator
...
The property was removed from the widget, so we need to remove it from
UI files too.
Fixes : #3492
2020-12-18 23:14:24 +00:00
Timm Bäder
0c6a6b3370
Merge branch 'doc_backticks' into 'master'
...
docs: backtick fixes
See merge request GNOME/gtk!2975
2020-12-18 15:57:30 +00:00
wisp3rwind
9521f609d8
docs: backtick fixes
...
- in the gettext() examples, at least the _() triggers italics
- add missing closing backtick
2020-12-18 16:31:41 +01:00
Matthias Clasen
7533369695
Merge branch 'wip/baedert/for-master' into 'master'
...
Wip/baedert/for master
See merge request GNOME/gtk!2973
2020-12-18 05:06:35 +00:00
Matthias Clasen
f31765d5dd
Merge branch 'ebassi/mnemonic-label-remove' into 'master'
...
a11y: Fix removing mnemonic widgets
See merge request GNOME/gtk!2970
2020-12-18 00:00:48 +00:00
Matthias Clasen
d33062795c
Merge branch 'ebassi/docs-for-master' into 'master'
...
Ebassi/docs for master
See merge request GNOME/gtk!2971
2020-12-17 23:59:41 +00:00
Emmanuele Bassi
2da8d9b0ac
Do not build gdk-pixbuf's man page
...
When using it as a sub-project. We don't really need them.
2020-12-17 20:50:16 +00:00
Matthias Clasen
3f56e8191f
Merge branch 'shortcuts' into 'master'
...
docs: Add separation between kinds of shortcuts in Keyboard input
See merge request GNOME/gtk!2964
2020-12-17 19:43:38 +00:00
Chris Mayo
bf4c3dc2c5
docs: Fix list of kinds of shortcuts in Keyboard input
...
Formatting in HTML was mangled.
2020-12-17 19:18:10 +00:00
Emmanuele Bassi
a5365ec8cb
docs: Add missing GTK types
...
If we don't specify the get_type() function, gtk-doc will not collect
properties and signals, and will use a different URL for the page.
2020-12-17 18:30:19 +00:00
Emmanuele Bassi
ec94ec0286
Merge branch 'ebassi/password-entry-notify' into 'master'
...
Notify properties on deletion in PasswordEntryBuffer
Closes #3484
See merge request GNOME/gtk!2969
2020-12-17 15:51:04 +00:00
Emmanuele Bassi
af0973c847
a11y: Fix removing mnemonic widgets
...
We must not use the variadic arguments version with GList, as it expects
a pointer to a GtkAccessible.
2020-12-17 15:49:00 +00:00
Emmanuele Bassi
e71f6b0bc0
docs: Note the caveat on GtkEditable signals with delegates
...
We cannot bubble up ::insert-text and ::delete-text signals from the
delegate to the wrapper editable without causing an infinite recursion,
due to how the signals are designed; ideally, we would have decoupled
signal emission from virtual functions *before* releasing GTK4, but now
that we have, we can't break the contract.
2020-12-17 15:13:43 +00:00
Emmanuele Bassi
1738724e4a
Notify properties on deletion in PasswordEntryBuffer
...
The GtkEntryBufferClass.deleted_text() behaviour changed between GTK3
and GTK4, which means any subclass of GtkEntryBuffer is now responsible
for emitting the "notify" signal for the "text" and "length" properties.
Without this, the GtkText delegate widget used by GtkPasswordEntry would
not be able to communicate changes in the contents of its buffer.
Fixes : #3484
2020-12-17 15:01:35 +00:00
Emmanuele Bassi
e9e09be37e
Merge branch 'issue-3483' into 'master'
...
Fix URLs for the download.gnome.org locations
Closes #3483
See merge request GNOME/gtk!2968
2020-12-17 13:47:01 +00:00
Matthias Clasen
8a923e02a1
Merge branch 'wip/jimmac/flat-button-tweaks' into 'master'
...
Adwaita: flat button adjustments
See merge request GNOME/gtk!2967
2020-12-17 12:52:22 +00:00
Emmanuele Bassi
4f12e2f711
Fix URLs for the download.gnome.org locations
...
Use a trailing slash, otherwise we end up on an out of date mirror.
Fixes : #3483
2020-12-17 12:46:12 +00:00
Jakub Steiner
addcf57b4d
Adwaita: flat button adjustments
...
- normally lighter (on bg_color)
- darker for headerbar
- undecorated checked buttons were never style properly (even gtk3)
see page2 volume buttons
Finetunes https://gitlab.gnome.org/GNOME/gtk/-/issues/3427
2020-12-17 12:20:29 +01:00
Matthias Clasen
db08bccb11
Merge branch 'cursor-aspect-ratio' into 'master'
...
Cursor aspect ratio fixes for gtk 4
Closes #3441
See merge request GNOME/gtk!2966
2020-12-16 23:40:26 +00:00
Sebastian Keller
02f0681344
settings: Change gtk-cursor-aspect-ratio from float to double
...
Float properties can not be read from keyfiles. This was causing changes
to this property in settings.ini to be ignored. Fix this by changing it
to a double.
Technically this change could be considered an API break, but there are
no users of this property as float yet and it is early enough to expect
there to never be any.
Also document this change in the 3 to 4 migration guide since in gtk 3
this setting will be kept a float.
Fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/3441
2020-12-16 22:35:36 +01:00
Emmanuele Bassi
62dbadd536
Merge branch 'fix-macos-compilation' into 'master'
...
macos: fix typo that breaks compilation
See merge request GNOME/gtk!2962
2020-12-16 20:18:27 +00:00
Matthias Clasen
0588db8a69
Merge branch 'wip/carlosg/for-master' into 'master'
...
gdk/x11: Transform XI_Motion based scroll into discrete
Closes #3459
See merge request GNOME/gtk!2959
2020-12-16 19:56:16 +00:00
Emmanuele Bassi
58b1a13453
Merge branch 'ricotz/for-master' into 'master'
...
gdk: Use correct parameter name to fix g-ir-scanner warning
See merge request GNOME/gtk!2963
2020-12-16 19:46:51 +00:00
Rico Tzschichholz
df70dbbae4
gdk: Use correct parameter name to fix g-ir-scanner warning
...
../gdk/gdktoplevellayout.c:217: Warning: Gdk: gdk_toplevel_layout_get_maximized:
unknown parameter 'maximized' in documentation comment, should be 'maximize'
2020-12-16 20:19:05 +01:00
Tom Schoonjans
81c55b06d2
macos: fix typo that breaks compilation
2020-12-16 19:16:19 +00:00
Matthias Clasen
591c2f0595
4.0
2020-12-16 12:12:58 -05:00
Matthias Clasen
9c5a42be0d
Update expected test results
...
We have one test that expected 3.99 to show up in an error message.
2020-12-16 12:12:58 -05:00
Matthias Clasen
45b7fa15e5
Merge branch 'ebassi/docs-for-master' into 'master'
...
Ebassi/docs for master
See merge request GNOME/gtk!2960
2020-12-16 16:41:44 +00:00
Emmanuele Bassi
e3de92f1ea
docs: Fix annotation for GtkSearchEntry::activate
2020-12-16 16:29:01 +00:00
Emmanuele Bassi
2ffa2be64e
doc: Document missing GtkNotebook types
2020-12-16 16:29:01 +00:00
Emmanuele Bassi
387078b40c
docs: Document GtkNativeDialogClass
2020-12-16 16:29:01 +00:00
Emmanuele Bassi
5203bf0b83
docs: Document GtkTreeViewColumn::clicked
2020-12-16 16:29:01 +00:00
Emmanuele Bassi
fb93baeae4
docs: Add missing description for GtkWidget::move-focus
2020-12-16 16:29:01 +00:00
Emmanuele Bassi
9fa4c2f5b8
docs: Ignore gtkspinbuttonprivate.h
2020-12-16 16:29:01 +00:00
Emmanuele Bassi
cc9528eaec
docs: Add missing documentation to GtkStatusbar
2020-12-16 16:29:01 +00:00
Emmanuele Bassi
73dda96711
docs: Add missing stanzas for gtk_test_accessible API
2020-12-16 16:29:01 +00:00
Emmanuele Bassi
d711acc954
docs: Ignore gtksorterprivate.h
2020-12-16 16:29:01 +00:00
Emmanuele Bassi
ab59c47880
docs: Add missing documentation to GtkPopover
2020-12-16 16:29:01 +00:00
Emmanuele Bassi
e4b7847904
docs: Fix documentation of GtkGestureStylus
...
Document all the signals, and fix the syntax for boolean values.
2020-12-16 16:29:01 +00:00
Emmanuele Bassi
308115ebae
docs: Add gtk-doc stanza for GtkExpander::activate
2020-12-16 16:29:00 +00:00
Emmanuele Bassi
1cb72536ea
docs: Fix syntax of GtkEntry::activate signal
2020-12-16 16:29:00 +00:00
Emmanuele Bassi
f24429e84a
docs: Remove private symbols
2020-12-16 16:29:00 +00:00
Emmanuele Bassi
fc4402b456
docs: Ignore gtkpasswordentryprivate.h
2020-12-16 16:29:00 +00:00
Emmanuele Bassi
077aec5d32
docs: Add missing documentation for GtkTextCharPredicate
2020-12-16 16:29:00 +00:00
Emmanuele Bassi
548949214c
docs: Add missing documentation GtkNative
2020-12-16 16:29:00 +00:00
Emmanuele Bassi
2aec47f56f
docs: Add missing documentation for GtkCellRenderer
2020-12-16 16:29:00 +00:00
Emmanuele Bassi
344eb21bee
docs: Complete symbol coverage for GSK
...
100% symbol docs coverage.
241 symbols documented.
0 symbols incomplete.
0 not documented.
2020-12-16 16:29:00 +00:00
Emmanuele Bassi
4fb55b3270
docs: Complete symbol coverage for GDK
...
100% symbol docs coverage.
833 symbols documented.
0 symbols incomplete.
0 not documented.
What's left are just type system macros and windowing system opaque
structures.
2020-12-16 16:28:58 +00:00
Matthias Clasen
75764c284d
Merge branch 'wip/toplevel-layout-intent' into 'master'
...
Fix toplevel layout state communication
Closes #3466
See merge request GNOME/gtk!2958
2020-12-16 16:02:00 +00:00
Carlos Garnacho
c95a32def8
gdk/x11: Transform XI_Motion based scroll into discrete
...
Depending on the input driver, we will get XI_Motion based scroll
events for regular mouse wheels. These are intended to be handled
as discrete scroll, so detect smooth scroll events that move by
exactly 1.0 in either direction.
Fixes: https://gitlab.gnome.org/GNOME/gtk/-/issues/3459
2020-12-16 14:26:44 +01:00
Jonas Ådahl
142f7862ed
gdk/toplevellayout: Change API to be about intent, not full state
...
When being fullscreen, and wanting to unfullscreen but not caring about
whether to go unmaximized or maximized (as this information is lost), if
the GdkToplevelLayout represents the full intended state, we won't be
able to do the right thing.
To avoid this issue, make the GdkToplevelLayout API intend based, where
if one e.g. doesn't call gdk_toplevel_set_maximized() with anything, the
backend will not attempt to change the maximized state.
This means we can also remove the old 'initially_maximized' and
'initially_fullscreen' fields from the private GtkWindow struct, as we
only deal with intents now.
2020-12-16 14:16:08 +01:00
Jonas Ådahl
b6412adc32
gtk/window: Check widget mappdness and not surface mappedness
...
When deciding whether to call gdk_toplevel_present(), check the
mappedness of GtkWidget instead of the mapped-ness of GdkSurface, as the
latter is mapped asynchronously, while the former is direct state of the
GtkWindow itself.
This fixes an issue where calling e.g. gtk_window_maximize() shortly
after showing it didn't take effect, as hadn't been mapped yet. While
maximizing after showing is racy, and will likely glitch from time to
time, the correct thing to do is still to maximize and handle whatever
state the compositor configured the window to be in.
Closes: https://gitlab.gnome.org/GNOME/gtk/-/issues/3466
2020-12-16 11:56:41 +01:00
Timm Bäder
7eece7e769
gl renderer: Take a out graphene_rect in blur_node()
2020-12-16 09:13:12 +01:00
Timm Bäder
7f6608cbed
gl renderer: Render too big textures to the clipped area
2020-12-16 08:26:46 +01:00
Timm Bäder
f816a8fb82
gl renderer: Unify viewport setting in add_offscreen_ops()
...
We use the same rect here a few times.
2020-12-16 08:26:46 +01:00
Timm Bäder
3c2484142d
vulkancontext: Remove usage of VK_ERROR_INCOMPATIBLE_VERSION_KHR
...
According to
https://www.khronos.org/registry/vulkan/specs/1.0-wsi_extensions/html/chap46.html
this has been removed. It also breaks the build on my system
2020-12-16 08:26:46 +01:00
Matthias Clasen
2192bb3dde
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
See merge request GNOME/gtk!2957
2020-12-15 20:33:01 +00:00
Matthias Clasen
e1df9a043f
Add a doc comment for GskConicGradientNode
2020-12-15 14:18:26 -05:00
Matthias Clasen
338d3ffa13
Add a doc comment for gdk_surface_request_layout
2020-12-15 14:14:49 -05:00
Emmanuele Bassi
6039a36183
Merge branch 'ebassi/for-master' into 'master'
...
Clean up the build system
See merge request GNOME/gtk!2955
2020-12-15 16:54:59 +00:00
Matthias Clasen
c551f693c2
Merge branch 'matthiasc/for-master' into 'master'
...
Update the node format docs
See merge request GNOME/gtk!2956
2020-12-15 16:23:15 +00:00
Emmanuele Bassi
5d2278a5ca
docs: Add public symbols to the GTK reference
2020-12-15 16:21:20 +00:00
Emmanuele Bassi
ea5e186bb8
Hide GtkTextAttributes functions
...
The type is private, so making functions operating on it public is
pointless.
2020-12-15 16:20:21 +00:00
Emmanuele Bassi
69b181f263
Remove boxed type for GtkCrossingData
...
The GtkCrossingData type is completely private, so there's no point in
having a boxed type for it.
2020-12-15 15:55:15 +00:00
Emmanuele Bassi
3132b10bc0
docs: Add more private headers
2020-12-15 15:55:06 +00:00
Matthias Clasen
7335e166b7
Update the node format docs
...
Update this document to mention all the render nodes we
have, and the default values for their properties.
2020-12-15 10:30:18 -05:00
Emmanuele Bassi
91bba794a6
docs: Add missing symbols to the GTK reference
2020-12-15 14:30:32 +00:00
Emmanuele Bassi
a6bd0c7eed
Remove stray mentions of GdkConfigureEvent
...
The event was removed, but some traces of it linger.
2020-12-15 13:58:52 +00:00
Emmanuele Bassi
ff351721b2
docs: Add missing symbols to the GDK reference
2020-12-15 13:47:40 +00:00
Emmanuele Bassi
538aa6c200
Move private GdkX11 symbols out of a public header
...
This avoids private symbols showing up in the introspection data, as
well as in the undocumented symbols list when generating the GDK API
reference.
2020-12-15 13:46:50 +00:00
Emmanuele Bassi
f546e03d31
docs: Add missing symbols to the GSK reference
2020-12-15 13:35:19 +00:00
Emmanuele Bassi
bdbea0d037
docs: Add more ignored header for GSK
2020-12-15 13:31:02 +00:00
Emmanuele Bassi
474b4ac1af
build: Use Meson support for dylib versions
...
Do not hand-code it inside GTK's meson.build.
2020-12-15 12:47:05 +00:00
Emmanuele Bassi
99e0929d6c
build: Use a consistent style for Meson files
2020-12-15 12:46:59 +00:00
Emmanuele Bassi
e75e44bdcc
build: Remove duplicate definition
...
The `GTK_COMPILATION` symbol is defined in gir_args.
2020-12-15 11:47:32 +00:00
Emmanuele Bassi
7975bbfcaa
build: Remove linker flags from static libraries
...
We only need hardening linker flags on the libgtk shared library;
internal static libraries don't really need them.
2020-12-15 11:36:20 +00:00
Emmanuele Bassi
11bca98a29
build: Remove unused variable
...
We don't need a `gsk_source` variable after all.
2020-12-15 11:35:27 +00:00
Emmanuele Bassi
618186723a
build: Remove unused backend_immodules variable
...
We don't have input method modules any more.
2020-12-15 11:20:19 +00:00
Emmanuele Bassi
a5986f0dcd
build: Use get_supported_link_arguments()
...
Instead of hand-coding it ourselves, let Meson deal with linker
arguments discovery.
2020-12-15 11:19:39 +00:00
Daniel Mustieles
c162d7148f
Updated Spanish translation
2020-12-15 10:28:49 +01:00
Matthias Clasen
7e1a210ae0
Merge branch 'ebassi/for-master' into 'master'
...
docs: Add note for the removal of GtkFileChooserButton
See merge request GNOME/gtk!2954
2020-12-14 20:37:34 +00:00
Jordi Mas
bf5e3efd54
Update Catalan translation
2020-12-14 18:39:00 +01:00
Emmanuele Bassi
08d52bee14
docs: Add note for the removal of GtkFileChooserButton
...
Point developers in the direction of GtkButton and GtkFileChooserNative.
2020-12-14 16:55:15 +00:00
Emmanuele Bassi
a6e9a9b644
Merge branch 'pixbuf-from-surface-leak' into 'master'
...
gdkpixbuf-drawable: Free the pixbuf on Cairo error
See merge request GNOME/gtk!2951
2020-12-14 15:12:56 +00:00
Adrien Plazas
dc96542742
gdkpixbuf-drawable: Free the pixbuf on Cairo error
...
This avoids leaking the pixbuf.
2020-12-14 15:07:41 +01:00
Matthias Clasen
e2afb59a0b
Merge branch 'matthiasc/for-master' into 'master'
...
Avoid adding // to resource paths
Closes #3469
See merge request GNOME/gtk!2947
2020-12-14 13:14:32 +00:00
Jakub Steiner
daa5d5aead
Merge branch 'dropdown-searchbar' into 'master'
...
dropdown: Improve search bar styling
See merge request GNOME/gtk!2948
2020-12-14 09:39:38 +00:00
Jakub Steiner
fd0a03cf78
Merge branch 'emoji-searchbar' into 'master'
...
Adwaita: Improve emoji picker styling
See merge request GNOME/gtk!2949
2020-12-14 09:38:45 +00:00
nana-4
34d99ea1d0
Adwaita: Improve emoji picker styling
...
- Add borders around the main scrollable content, like most other
places.
- Set padding and spacing on .emoji-searchbar and .emoji-toolbar in a
more proper way.
- Remove unused button.emoji-section label styles.
2020-12-14 05:26:39 +09:00
nana-4
90355c0b27
emojichooser: Add .emoji-searchbar style class
...
Similar to .emoji-toolbar, it would be nice to have this for styling.
2020-12-14 05:26:13 +09:00
nana-4
538cf9e294
dropdown: Improve search bar styling
...
As per the mockup. See:
https://gitlab.gnome.org/Teams/Design/os-mockups/-/blob/master/dropdown-lists/dropdown-lists.png
2020-12-14 05:08:59 +09:00
Piotr Drąg
8e3f2b879e
Update Polish translation
2020-12-13 16:51:51 +01:00
Florentina Mușat
8fa6a25aa5
Update Romanian translation
2020-12-12 18:49:22 +00:00
Matthias Clasen
96a300b2de
Merge branch 'wip/jimmac/button-shed' into 'master'
...
headerbar window controls & clean up flat button extend
Closes #3427
See merge request GNOME/gtk!2942
2020-12-12 02:51:05 +00:00
Matthias Clasen
aeca9cb7ba
Avoid adding // to resource paths
...
The GResource machinery is not forgiving about this
sort of thing.
Fixes : #3469
2020-12-11 21:47:54 -05:00
Matthias Clasen
c2727e6e04
Merge branch 'wip/carlosg/for-master' into 'master'
...
Wip/carlosg/for master
Closes #3461 , #593 , #3083 , #3009 , #3463 , and #3426
See merge request GNOME/gtk!2945
2020-12-12 02:35:01 +00:00
Carlos Garnacho
8be0918d7e
gdk/surface: Trigger motion check for next frame after thaw
...
This is a more reliable calling point than ::resume-events, and a
good one to schedule things so they happen on a frame clock in no
special phase (Thus still fixing the original issue at 80d4a08e30 )
Fixes: https://gitlab.gnome.org/GNOME/gtk/-/issues/3461
2020-12-12 02:14:02 +01:00
Carlos Garnacho
612d3bca7d
gtk/window: Bring back L-shaped resize corners
...
These ended up square in the various refactors. Make them again L-shaped
by extending these along the edge being checked. This means we have to
check for corner positions in all edges, though.
2020-12-12 01:42:42 +01:00
Carlos Garnacho
e9fe270e94
gtk/scrolledwindow: Handle full scroll sequences only
...
In order to do this, leverage smooth scroll handling into the capture
phase scroll controller, controlled by ::scroll-begin in the propagation
phase controller.
There's 2 cases here:
- A child widget handles scroll. The scrolled window does not get
::scroll-begin, the child widget handles the full scroll sequence.
- No child handles scroll, the scrolled window gets ::scroll-begin,
and transfers control of scrolling to the capture phase controller.
As scrolling is performed, the pointer may fall into scrollable children,
but the scrolled window will be capturing the scroll events, so these
won't be seen by the child widgets.
Fixes: https://gitlab.gnome.org/GNOME/gtk/-/issues/593
2020-12-12 01:42:42 +01:00
Carlos Garnacho
8402665c55
gtk/eventscrollerscroll: Handle smooth events in discrete controllers
...
We let smooth scroll events that don't trigger a ::scroll signal through.
This is unintended, these are handled, even if just accumulated.
This fixes cases like GtkSpinButton inside GtkScrolledWindow, where both
would handle events, until the GtkSpinButton eventually shifts away from
underneath the pointer.
Brought up at https://gitlab.gnome.org/GNOME/gtk/-/issues/593
2020-12-12 01:42:42 +01:00
Carlos Garnacho
79090f1755
gtk/entrycompletion: Ensure to show first row when shown, not allocated
...
This code was here in gtk3 to cater for the completion window being
positioned. That was only to meant once as long as the completion window
was shown.
This doesn't work as well for gtk4, ::size-allocate gets propagated from
the toplevel, so happens much more often for the completion window, this
ends up with the completion position being reset to the first row
frequently.
Do this simply once when popping up the completion, instead.
Fixes: https://gitlab.gnome.org/GNOME/gtk/-/issues/3083
2020-12-12 01:42:42 +01:00
Carlos Garnacho
3d84a38867
gtk/treeview: Position editable widgets correctly wrt left border
...
The coordinates are already widget-local here, not transformed by the
adjustment positions. Using the adjustment value here ends up pushing
the entry far from the left border.
The correct minimum value here is 0, which matches the treeview left
border.
Fixes: https://gitlab.gnome.org/GNOME/gtk/-/issues/3009
2020-12-12 01:42:42 +01:00
Carlos Garnacho
5155fac94f
gtk/modelbutton: Handle unpaired releases
...
Let model buttons handle unpaired releases, these may happen indirectly
e.g. due to other child menus being opened at the time. Clicking would
dismiss the menu, but the menu item beneath the pointer would not get
activated.
We can handle that button release though via ::unpaired-release, so
there's no second click required.
Fixes: https://gitlab.gnome.org/GNOME/gtk/-/issues/3463
2020-12-12 01:42:42 +01:00
Carlos Garnacho
7a4d15dc67
gtk/range: Move button release handling to GtkGestureDrag
...
Tracking it through the GtkGestureClick becomes a bit cumbersome for
handling of simultaneously pressed buttons. We can track ::stopped,
but that also emits for a number of situations where we want drag to
continue.
However, the GtkGestureDrag is grouped with the click gesture, and
knows better when to finish the drag gesture (not just because of a
button release), so hook drag and zoom mode finalization there.
Fixes: https://gitlab.gnome.org/GNOME/gtk/-/issues/3426
2020-12-12 01:42:42 +01:00
Emmanuele Bassi
e4d8d50a8b
Merge branch 'ebassi/for-master' into 'master'
...
Ebassi/for master
See merge request GNOME/gtk!2944
2020-12-12 00:01:38 +00:00
Emmanuele Bassi
3c9a13e6cf
Update CODEOWNERS
...
Add me as the reference for the accessibility bits of the code base.
2020-12-11 23:42:25 +00:00
Emmanuele Bassi
2c97d44281
docs: Fix the Widget as Buildable example
...
The layout properties use an old name.
2020-12-11 23:41:51 +00:00
Kjartan Maraas
2d3a398678
Update Norwegian Bokmål translation
2020-12-11 11:40:55 +00:00
Florentina Mușat
d380ed2b3a
Update Romanian translation
2020-12-10 15:34:51 +00:00
Matthias Clasen
644a45714a
Merge branch 'matthiasc/for-master' into 'master'
...
docs: Update references to GtkWindow:fullscreened
See merge request GNOME/gtk!2943
2020-12-10 14:31:54 +00:00
Matthias Clasen
324683993e
docs: Update references to GtkWindow:fullscreened
...
The property got renamed from fullscreen to fullscreened.
Update all references.
2020-12-10 09:10:21 -05:00
Jakub Steiner
f6f6241627
Adwaita: special case flat headerbar buttons
...
- make sure the hovers and pushed states are legible on a tintend headerbar
Fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/3427
2020-12-10 14:24:29 +01:00
Jakub Steiner
6a33bed353
Adwaita: flat button :hover and :active
...
- special case undecorated button hovers
2020-12-10 14:16:25 +01:00
Jakub Steiner
f83ee0be23
Adwaita: headerbar_color > headerbar_bg_color
...
- semantic correction
2020-12-10 13:58:42 +01:00
Jakub Steiner
7442bdc383
Adwaita: duplicate selector
...
- awkward duplicate selector that should have no effect
(resulting in the same css)
2020-12-10 13:51:10 +01:00
Luna Jernberg
82950528ed
Update Swedish translation
2020-12-09 21:05:25 +00:00
Matthias Clasen
97eaef8308
Merge branch 'ebassi/popcount' into 'master'
...
Share the popcount() fallback for MSVC
See merge request GNOME/gtk!2940
2020-12-09 16:32:09 +00:00
Matthias Clasen
92189cf96a
Merge branch 'matthiasc/for-master' into 'master'
...
Remove NoDisplay from demo desktop files
Closes #2932
See merge request GNOME/gtk!2939
2020-12-09 16:10:04 +00:00
Emmanuele Bassi
b8a651df47
Share the popcount() fallback for MSVC
...
We use __builtin_popcount() in a couple of places, so it makes sense to
have it in one header.
2020-12-09 16:06:52 +00:00
Matthias Clasen
c0ed89be9a
widget-factory: Autoplay the video
...
The empty video on the frontpage is a bit of a letdown, since
the big arrow can't be clicked.
2020-12-09 10:52:55 -05:00
Matthias Clasen
ade4bcb125
Remove NoDisplay from demo desktop files
...
When these are installed (in particular, as flatpaks),
we should not hide them.
Fixes : #2932
2020-12-09 10:09:06 -05:00
Matthias Clasen
c5dd34344f
Merge branch 'wip/carlosg/for-master' into 'master'
...
Wip/carlosg/for master
Closes #3426 and #3264
See merge request GNOME/gtk!2933
2020-12-09 15:04:01 +00:00
Matthias Clasen
c90cc976a5
Merge branch 'wip/jimmac/row-transitions-and-spacing' into 'master'
...
Adwaita: row transitions and spacing
Closes #3434
See merge request GNOME/gtk!2937
2020-12-09 13:35:54 +00:00
Matthias Clasen
bd9bcd5905
Merge branch 'wip/baedert/for-master' into 'master'
...
Wip/baedert/for master
Closes #3431
See merge request GNOME/gtk!2938
2020-12-09 13:34:21 +00:00
Matthias Clasen
0ddcbb52e6
Merge branch 'ebassi/4-0-abi-bump' into 'master'
...
Ebassi/4 0 abi bump
Closes #3392
See merge request GNOME/gtk!2883
2020-12-09 13:20:20 +00:00
Emmanuele Bassi
2457f3d54c
build: Bump up the SONAME for GTK4
...
We released all the 3.9x development snapshots using:
libgtk-4.0.so.0.xxxx.y
which means that the 4.0.0 release of GTK will have a lower SONAME than
the snapshots. To avoid that, bump the SONAME to 1.xxxx.y.
Fixes : #3392
2020-12-09 12:19:50 +00:00
Emmanuele Bassi
1cc207af32
build: Tie interface age to the development cycle
...
We don't want to increase the interface age manually, because we're
going to end up forgetting about it.
Instead, we should tie it to the rest of the version:
- in stable (even minor) cycles, we don't add new API; the interface
age is the same as the micro version
- in unstable (odd minor) cycles, every new release might have new API,
or updates to newly added API; keep the interface age to 0
This removes one more manual thing to change during release, and keeps
us honest with our promise not to add symbols during stable cycles.
2020-12-09 12:19:50 +00:00
Emmanuele Bassi
f4a0d57c07
Prepare version macros for 4.0
...
Remove the 3.9x version macros, and ensure that we handle 4.0 as the
backstop for the minimum required version.
2020-12-09 12:19:50 +00:00
Jakub Steiner
a76ee61e97
Adwaita: row transitions and spacing
...
- no fading out of row hovers. Many feel like it's a slow
refresh rather than intentional effect.
- give some margin to navigation lists
Fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/3434
2020-12-09 12:16:15 +01:00
Yuri Chornoivan
fac367495b
Update Ukrainian translation
2020-12-09 07:08:51 +00:00
Matthias Clasen
76177b6065
Merge branch 'ebassi/prop-names' into 'master'
...
Ebassi/prop names
See merge request GNOME/gtk!2936
2020-12-09 05:51:00 +00:00
Matthias Clasen
433f305fa9
Merge branch 'sophie-h-master-patch-62064' into 'master'
...
gtk-demo: Remove potentially ableist metaphor
See merge request GNOME/gtk!2934
2020-12-09 00:53:10 +00:00
Matthias Clasen
fce824e78f
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
Closes #3451
See merge request GNOME/gtk!2935
2020-12-09 00:52:53 +00:00
Emmanuele Bassi
c4b768a4ec
Rename GtkWindow:fullscreen to :fullscreened
...
Having a property with the same name of a method makes some languages
which put properties and method names in the same flat namespace not
really happy about our choices. To avoid collisions, let's put the the
"fullscreen" property into the past, alongside the "maximized" property.
2020-12-09 00:11:49 +00:00
Emmanuele Bassi
6d1be832d9
Fix the documentation for GtkWindow state properties
...
Drop the "don't write code that crashes" folksy bit; don't start
sentences with conjunctions; remove copy-pasted references to
"iconified" states; point to the corresponding property notification in
a consistent manner.
2020-12-08 23:49:45 +00:00
Matthias Clasen
a828d4318e
Mark flaky tests as flaky
...
We can't mark these as xfail, since it sometimes succeed.
2020-12-08 18:10:02 -05:00
Sophie Herold
a36ccd7f42
gtk-demo: Remove potentially ableist metaphor
2020-12-08 23:02:03 +00:00
Matthias Clasen
b4a7fe8d8f
Add bug reporting address to pot files
...
Fixes : #3451
2020-12-08 17:51:38 -05:00
Carlos Garnacho
43e4848872
gtk/main: Keep implicit grab until all buttons are released
...
Currently, the implicit grab is broken on the first button release,
in the case of pressing multiple buttons simultaneously. This means
that we emit crossing events early, and the next button releases
are sent to the pointer focus widget instead.
Consider the implicit grab effective until all buttons are released,
and only unset the pointer implicit grab (and emit crossing events)
after there are no further buttons pressed. We do this by checking
event modifiers, given button release events do contain the modifiers
in effect at the time the event was generated, we have to look for
exactly one active button modifier.
Fixes weird pointer states after pressing multiple buttons on a
widget.
Fixes: https://gitlab.gnome.org/GNOME/gtk/-/issues/3426
2020-12-08 23:27:03 +01:00
Carlos Garnacho
80d4a08e30
gdk/surface: Delay gdk_surface_request_motion() requests internally
...
Those requests are received while dealing with the ::layout frame
clock phase, this has the unintended side effect of making the
frame clock "rewind" to handle ::flush-events again during this
frame, which delays everything and practically halves the frame
rate.
We do intend to make the motion events dispatches on the next frame,
so do this in an idle at a slightly lower priority than layout/draw,
so the ::flush-events phase is actually requested for the next frame.
Fixes: https://gitlab.gnome.org/GNOME/gtk/-/issues/3264
2020-12-08 23:27:03 +01:00
Carlos Garnacho
47d0b5ad0c
gkt/textview: Set an iter position for event-less menu activation
...
This went missing. Use the current insertion position as a reference.
Fixes invoking the menu via keyboard.
2020-12-08 23:27:03 +01:00
Matthias Clasen
c59b433395
Merge branch 'wip/chergert/gdk-macos-for-master' into 'master'
...
macos: fix macOS build breakage
See merge request GNOME/gtk!2931
2020-12-08 20:32:51 +00:00
Yuri Chornoivan
18d06a1cd5
Update Ukrainian translation
2020-12-08 20:25:26 +00:00
Florentina Mușat
f13041360a
Update Romanian translation
2020-12-08 19:52:12 +00:00
Christian Hergert
0236fe80c1
macos: fix macOS build breakage
...
Fixes breakages due to recent refactoring around sizing changes.
2020-12-08 11:29:31 -08:00
Matthias Clasen
2caf283323
Mark the window-show-contents-on-map.ui reftest as xfail
...
We know now what the test is trying to test, just lack
the right plumbing to do it properly. So, keep the test
around, marked as expected fail.
2020-12-08 12:04:47 -05:00
Matthias Clasen
6fb66e299a
Revert "reftests: Remove window-show-contents-on-map.ui test"
...
This reverts commit 074b933ae4 .
2020-12-08 11:45:52 -05:00
Matthias Clasen
398a74d871
3.99.5
2020-12-08 10:58:40 -05:00
Matthias Clasen
08ca8a361e
docs: Remove a mention of gtk_window_get_size
...
That function has been removed.
2020-12-08 10:44:33 -05:00
Matthias Clasen
1f141c1953
Merge branch 'wip/surface-state-rework' into 'master'
...
Rework surface state and geometry computation
See merge request GNOME/gtk!2885
2020-12-08 15:38:36 +00:00
Jakub Steiner
1e14a91cb9
Merge branch 'wip/jimmac/no-inner-shadow-sidebars' into 'master'
...
Adwaita: no 3d shadow for pressed sidebar
Closes #3413
See merge request GNOME/gtk!2928
2020-12-08 14:18:44 +00:00
Jonas Ådahl
074b933ae4
reftests: Remove window-show-contents-on-map.ui test
...
It tested that a widget shown after the window was mapped deals with
window resizing appropriately when doing the follow-up allocation. Now,
doing this only allocates both at the same time, as allocation happens
during the frame dispatch.
To do the equivalent now, one would have to write code that shows the
label after the first frame was drawn, and that's not possible via a
reftest, so lets remove it.
2020-12-08 14:22:59 +01:00
Jonas Ådahl
7b7f3342d8
reftests/textview-tags: Hide text view cursor
...
Otherwise it'd sometimes show up, causing test flakyness.
2020-12-08 12:03:18 +01:00
Matthias Clasen
adc4bcbd24
Merge branch 'wip/chergert/gdk-macos-for-master' into 'master'
...
macos: various GL context cleanups
See merge request GNOME/gtk!2929
2020-12-08 00:06:19 +00:00
Jonas Ådahl
130ff5f841
testsuite/notify: Don't fiddle with GtkWidget::visible
...
It may map toplevel windows with arbitrary modes, which will effect
other properties, such as GtkWindow::maximized and
GtkWindow::fullscreen.
2020-12-07 22:41:36 +01:00
Jonas Ådahl
fea1b151e6
testsuite/filtermodel: Remove calls to gtk_widget_realize()
...
They don't do what they used to do.
2020-12-07 22:29:51 +01:00
Christian Hergert
6e0fffa0f8
macos: use CGLSetParameter and CGLEnable
...
We don't need to go through the NSOpenGLContext for these.
We can just use the C API directly. It's also clearer what is using
CGLEnable() vs CGLSetParameter().
2020-12-07 11:47:51 -08:00
Jonas Ådahl
d2c95a1b13
gdk: Replace 'WITHDRAWN' state with async 'is-mapped' boolean
...
It was used by all surfaces to track 'is-mapped', but still part of the
GdkToplevelState, and is now replaced with a separate boolean in the
GdkSurface structure.
It also caused issues when a widget was unmapped, and due to that
unmapped a popover which hid its corresponding surface. When this
surface was hidden, it emitted a state change event, which would then go
back into GTK and queue a resize on popover widget, which would travel
back down to the widget that was originally unmapped, causing confusino
when doing future allocations.
To summarize, one should not hide widgets during allocation, and to
avoid this, make this new is-mapped boolean asynchronous when hiding a
surface, meaning the notification event for the changed mapped state
will be emitted in an idle callback. This avoids the above described
reentry issue.
2020-12-07 20:37:30 +01:00
Jonas Ådahl
8f8c5040db
gtk/headerbar: Remove unused 'state' field
2020-12-07 20:37:30 +01:00
Matthias Clasen
3b69facf0b
Mention window sizes in the migration guide
2020-12-07 20:37:30 +01:00
Matthias Clasen
a6bc4c95b1
docs: Add gtk_window_is_fullscreen
2020-12-07 20:37:30 +01:00
Matthias Clasen
59fd171515
popup: Documentation tweaks
...
Use proper syntax for referring to signals.
2020-12-07 20:37:30 +01:00
Matthias Clasen
3db0d06901
Properly remove gtk_window_get_size
...
It was still in the headers and the docs, but did
not have an implementation anymore.
2020-12-07 20:37:30 +01:00
Jonas Ådahl
d7d738d745
tests/animated-resizing: Use gtk_window_default_size() instead
...
This will actually make it resize on-demand, as the default size is the
size used when computing the window size when the size is not fixed.
2020-12-07 20:37:29 +01:00
Jonas Ådahl
ac17217c69
wayland/toplevel: Don't alwyas skip changing xdg_toplevel state
...
We only called xdg_toplevel.(un)set_maximize() if the toplevel layout
changed, but this misses the case when the compositor had changed the
maximized state. Change it to call the xdg_toplevel request if either
the local layout changed, or if the layout differs from the current
state.
This fixes an issue where one couldn't unmaximize a window by double
clicking the titlebar that, had previously been maximized e.g. using a
keyboard binding.
Do the same for fullscreen.
2020-12-07 20:37:29 +01:00
Jonas Ådahl
2e5eeb6b92
gtk/window: Add 'fullscreen' prop and gtk_window_is_fullscreen()
...
This makes it possible to set 'fullscreen' to 'true' in a .ui file to
start an application in fullscreen mode.
2020-12-07 20:37:29 +01:00
Jonas Ådahl
eb0eac0f03
gtk/window: Make R/O is-maximized R/W maximized prop
...
This makes it possible to set 'maximized' to true in .ui files, and the
window will show up maximized.
gtk_window_is_maximized() will return the intended maximized state until
actually mapped, it will then show the actual maximized state. The same
applies to reading the property.
2020-12-07 20:37:29 +01:00
Jonas Ådahl
27077d5be8
gtk/window: Make 'default-size' adapt to configured size
...
This commit changes the behavior of window size computation and the
default size properties to:
* The default-width and default-height properties are updated to the
current window size unless the size is fixed by e.g. being maxmized,
tiled etc.
* The compute-size semantics are to just pick the default size, or if
not adequate, use the measured size, and consequently update the
default size, unless unresizable.
* gtk_window_get_size() is removed, what's more likely relevant is the
gtk_window_get_default_size() which will now contain more sensible
values.
Various places that used gtk_window_get_size() were updated to use
gtk_window_get_default_size() to remember and restore previous sizes.
This also changes the default value of 'default-width' and
'default-height' from -1 to 0. The gtk builder simplify tool is taught
how to omit when the default size is set to both -1 and 0.
2020-12-07 20:37:29 +01:00
Jonas Ådahl
fd01723470
x11/surface: Avoid resizing if computed size didn't change
...
This fixes an issue where we'd resize to the previous window size during
interactive resize.
2020-12-07 20:37:29 +01:00
Jonas Ådahl
994aa41ccc
x11/surface: Move the scattered compute-size calls to helper
...
This simplifies things, and fixes issue where we'd resize the wrong
time, and miss resizing other times.
2020-12-07 20:37:29 +01:00
Jonas Ådahl
c791185c20
x11/surface: Remember the toplevel layout
2020-12-07 20:37:29 +01:00
Jonas Ådahl
e7ddaf5ed1
x11/surface: Compute size after update too
...
This will sometimes mean a frame is skipped if a resize was requested
during the update phase of the frame dispatch. Not doing so can cause
trying to allocate a window smaller than the minimum size of the widget.
2020-12-07 20:37:29 +01:00
Jonas Ådahl
2217cf8ea2
x11/surface: Remember when there is a pending ConfigureNotify
...
This will be used to decide whether to try to resize windows when .
2020-12-07 20:37:29 +01:00
Jonas Ådahl
3bbeb891c4
gdk/surface: Allow inhibit layout from backend
...
If compute_size() returns TRUE, the layout will not be propagated to
GTK. This will be used by the X11 backend to queue asynchronous resizes
that shouldn't yet allocate in GTK.
2020-12-07 20:37:29 +01:00
Jonas Ådahl
ff23a2a582
x11: Use resize counting for freezing updates too
...
It's already keep strack of when we're waiting for configure events, so
lets reuse it. This fixes an issue where reshown dialogs wouldn't
reappear.
2020-12-07 20:37:29 +01:00
Jonas Ådahl
8396bdb759
wayland/surface: Reset last sent min/max size when hiding
...
As with the window geometry, the last sent min/max values must be reset
so they are sent again next time the surface is shown.
2020-12-07 20:37:29 +01:00
Jonas Ådahl
351d88f7ae
wayland/surface: Clear shadow width when hiding
...
Not doing this means the next time the same surface is shown, if the
shadow size wasn't changed, it wouldn't be sent to the compositor, which
then would result in compositor deriving its own window geometry which
would include the shadow margin.
This fixes an issue where the file chooser dialog would grow each time
it opened.
2020-12-07 20:37:29 +01:00
Jonas Ådahl
dfb7ab3352
x11/surface: Compute toplevel size outside of frame dispatch
...
We can't compute and resize a toplevel size during dispatch, as resizing
on X11 is an asynhronous operation, requiring a configuration event.
2020-12-07 20:37:29 +01:00
Jonas Ådahl
8e3ee58e3f
tests/animated-resizing: Don't try to resize during frame dispatch
...
This will not work on X11 because it's too late to resize, due to
resizing being asynchronous i.e. it won't be complete before we need to
draw.
2020-12-07 20:37:29 +01:00
Jonas Ådahl
40a9baa2db
gtk/native: Remove gtk_native_check_resize()
...
This is now handle by the corresponding implemenatations using per
non-gobject-type API.
2020-12-07 20:37:29 +01:00
Jonas Ådahl
4b2aae9950
gtk/dragicon: Use private gtk_drag_icon_present() instead of GtkNative
...
It didn't even use GtkNative, just the vfunc it set to the interface
sturct.
2020-12-07 20:37:29 +01:00
Jonas Ådahl
9d3f497a21
gtk/tooltipwindow: Use gtk_tooltip_window_present() instead of GtkNative
2020-12-07 20:37:29 +01:00
Jonas Ådahl
517bc0db84
gtk/texthandle: Use gtk_text_handle_present() instead of GtkNative
2020-12-07 20:37:29 +01:00
Jonas Ådahl
369b03a3d8
gtk/window: Don't go via GtkNative when presenting
...
It'll only call directly back into GtkWindow's toplevel present handling
code.
2020-12-07 20:37:29 +01:00
Jonas Ådahl
2cddec7798
gtk/popover: Use gtk_popover_present() instead of going via GtkNative
...
This makes it more explicit that managers of popovers make it "present".
2020-12-07 20:37:29 +01:00
Jonas Ådahl
f7fceab40b
gtk/entry: Remove emoji chooser field
...
It wasn't ever set.
2020-12-07 20:37:29 +01:00
Jonas Ådahl
3b66f63523
gtk/popover: Request fake motion events for popovers too
...
As with GtkWindow, we need to request fake motion events if allocation
changes, to emulate motion events given the new layout.
2020-12-07 20:37:29 +01:00
Jonas Ådahl
96450ed9cc
gdk/surface: Emit layout event while frozen
...
The allocation of popups are part dependent of the allocation of the
root, which means the root must still be allocated when updates are
frozen, otherwise we'll try to allocate non-laid out popups.
2020-12-07 20:37:29 +01:00
Jonas Ådahl
5eee1dfcd1
gdk/popup: Remove the popup-layout-changed signal
...
It was replaced with GdkSurface::layout.
2020-12-07 20:37:29 +01:00
Jonas Ådahl
19d2a4ab94
gtk/window: Only fake motion events on windows with pending allocations
...
This fixes an issue where the focus of the window continuously received
fake motion events even when a popover was open, making input events end
up behind the popover.
It also adds a comment describing why motion events are requested. Note
that popovers won't work with this, and it's possible both in the past
and now that sporadic missplaced motion events will appear, e.g. when a
window changes allocation but a popover is open.
2020-12-07 20:37:29 +01:00
Jonas Ådahl
6ee7535af0
gdk/toplevelsize: Rename 'margin' to 'shadow' and 'shadow_width'
...
This makes it more consistent with everywhere else.
2020-12-07 20:37:29 +01:00
Jonas Ådahl
b738054344
gdk: Remove GdkSurface::size-changed
...
It's not emitted, and everyone should use the GdkSurface::layout signal
from now on.
2020-12-07 20:37:29 +01:00
Jonas Ådahl
b8fa892b70
gtk/window: Minor cleanup
2020-12-07 20:37:29 +01:00
Jonas Ådahl
ca65ee8d50
gtk/window: Remove out-dated comment
2020-12-07 20:37:29 +01:00
Jonas Ådahl
5eca548acc
gtk/window: Use default size if non-resizable if set
2020-12-07 20:37:29 +01:00
Jonas Ådahl
42679f2903
gdk: Replace all GDK_CONFIGURE usage with GdkSurface::layout
...
This removes the GDK_CONFIGURE event and all related functions and data
types; it includes untested changes to the MacOSX, Win32 and Broadway
backends.
2020-12-07 20:37:29 +01:00
Christian Hergert
b431e39d4e
macos: we only need 24-bit for color
2020-12-07 11:27:11 -08:00
Emmanuele Bassi
606cb51293
Merge branch 'ebassi/activate-signal' into 'master'
...
Add accessors for GtkWidgetClass.activate_signal
See merge request GNOME/gtk!2925
2020-12-07 15:23:55 +00:00
Jakub Steiner
62e0c0de59
Adwaita: no 3d shadow for pressed sidebar
...
Fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/3413
2020-12-07 14:19:24 +01:00
Jakub Steiner
30f789650f
Revert "Adwaita: avoid clipping menu shadows"
...
While the workaround hides majority of the issue there are still two big downsides:
- shadow does eat from the widget dimensions so alignment is broken
- situations like popover going upwards on screen edge break completely
The appropriate action is to revert these theme duct tape solutions to make room
for a proper fix.
This reverts commit b3dba1dca6 .
Issue https://gitlab.gnome.org/GNOME/gtk/-/issues/1987
2020-12-07 10:58:12 +01:00
Jonas Ådahl
3f96d4b6da
gdk: Always get shadow width via GdkToplevelSize
...
This removes the gdk_surface_set_shadow_width() function and related
vfuncs. The point here is that the shadow width and surface size can now
be communicated to GDK atomically, meaning it's possible to avoid
intermediate stages where the surface size includes the shadow, but
without the shadow width set, or the other way around.
2020-12-07 09:46:39 +01:00
Jonas Ådahl
0dcd4a5bdb
wayland: Stop emitting size-changed
...
It's dealt with by GdkSurface::layout now.
2020-12-07 09:46:39 +01:00
Jonas Ådahl
8a599b2582
gtk: Allocate everything from GtkNativeClass::layout
...
This changes allocation of the widget trees to happen as a side effect
to the GdkSurface::layout signal, which first passes the GtkNative
instance where it is then forwarded to the implementations of the
GtkNative interface.
The implementations of GtkNative are the ones doing the actual
gtk_widget_allocate(), and they do so in their GtkNativeClass::layout
function.
2020-12-07 09:46:39 +01:00
Jonas Ådahl
a798edc360
gtk/window: Only deal with shadow when (ex|in)cluding csd size
...
The size should correspond what gtk_widget_measure() does, and it
measures what's within the window excluding the shadow; so make this
helper function correspond to this.
2020-12-07 09:46:39 +01:00
Jonas Ådahl
e51c32b9c1
gdk/wayland: Always compute-size if GTK asked fer layout
2020-12-07 09:46:39 +01:00
Jonas Ådahl
048a0172a0
gdk/wayland: Always configured size when resizing
...
GTK4 doesn't support arbitrary constraints when resizing a window (e.g.
steps, or aspect ratio), so we don't need to care about the result from
compute-size when doing interactive resizing.
2020-12-07 09:46:39 +01:00
Jonas Ådahl
64f6118af4
gdk/toplevelsize: Don't complain if only shadow extends out of bounds
2020-12-07 09:46:39 +01:00
Jonas Ådahl
14b5a5a4c7
gtk/window: Remove gtk_window_resize()
...
Use gtk_window_set_default_size() or change the size of the widget
inside the window to get the same effect.
2020-12-07 09:46:39 +01:00
Jonas Ådahl
4083f7e47f
testsuite: Remove test for gtk_window_resize()
...
And use gtk_window_set_default_size() in the other place.
2020-12-07 09:46:39 +01:00
Jonas Ådahl
2854d0339c
tests/testgtk: Remove 'Resize' button
...
The gtk_window_resize() API is going away, so remove this test.
2020-12-07 09:46:39 +01:00
Jonas Ådahl
98fffe6f23
tests/animated-resizing: Resize widget instead of window
...
This means the window needs to be marked as non-resizable, otherwise it
won't shrink.
2020-12-07 09:46:39 +01:00
Jonas Ådahl
f083849ebb
tests: Use gtk_window_set_default_size() when appropriate
...
Replace the usage of gtk_window_resize() with
gtk_window_set_default_size() where possible.
2020-12-07 09:46:39 +01:00
Jonas Ådahl
deb58339b9
gtk/expander: Remove manual call to gtk_window_resize()
...
It happens implicitly for a non-resizeable window.
2020-12-07 09:46:39 +01:00
Jonas Ådahl
65ad9d6d96
gdk/x11: Flush layout changes to the frame clack dispatch
...
This follows the trail of the Wayland backend in that GdkSurface changes
happen during the layout phase, and that a GDK_CONFIGURE no longer being
used to communicate the size changes of a surface; this now also uses
the layout signal on the GdkSurface.
2020-12-07 09:46:39 +01:00
Jonas Ådahl
e0f13ecae7
gdk/surface: Try to reschedule pending phase until dispatched
...
If a surface scheduled a relayout, got frozen, and a layout phase
happened, then got unfrozen, it wouldn't see it's layout being
requested; avoid this race by remembering the pending phases until they
actually happened.
2020-12-07 09:46:39 +01:00
Jonas Ådahl
880ceebae4
gdk/surface: Make backends aware of when layout is requested
2020-12-07 09:46:39 +01:00
Jonas Ådahl
8c014e63af
x11: Remove handling of 'substructure' events
...
Reading the comment, it seems to be related being a window manager
decoration utility; this is not something GTK4 aims to handle, just drop
support for this.
2020-12-07 09:46:39 +01:00
Jonas Ådahl
ecd40fa265
wayland: Layout drag icon from GdkSurface::layout
2020-12-07 09:46:39 +01:00
Jonas Ådahl
3b140a05a4
gtk/dragicon: Don't show until child is set
...
Showing before the child would result in bogus
gdk_drag_surface_present() with an "empty" (1x1) size. This can easily
be avoided by postponing showing until there is anything to show.
2020-12-07 09:46:39 +01:00
Jonas Ådahl
d38f81999e
wayland: Communicate popup layout changes via GdkSurface::layout
...
By moving popup layout emission to the layout phase, the current
GdkPopup::poup-layout-changed signal has no value on its own as it'd be
ignored by GtkPopover.
Make the Wayland backend communicate the popup layout changes via the
common signal; but leave the rest intact until other backends catch up.
2020-12-07 09:46:39 +01:00
Jonas Ådahl
efcfd23652
wayland/surface: Restructure fields used for the next layout
...
Put them in a anonymous struct, and separate the toplevel specific ones
into another anonymous struct inside the first one. Later popup related
fields will be added.
2020-12-07 09:46:39 +01:00
Jonas Ådahl
70b83c9a70
gdk/surface: Remove left-over signal enum value
...
The popup-layout-change signal was moved to GdkPopup, but the enum was
never removed from GdkSurface.
2020-12-07 09:46:39 +01:00
Jonas Ådahl
4779e4e488
gdk/frame-clock: Remove the newly added 'compute-size' phase
...
What was previously done in the layout phase is now done in response to
a GdkSurface signal, which means size computation can happen on layout.
2020-12-07 09:46:39 +01:00
Jonas Ådahl
13931463bd
wayland/surface: Compute size on layout
...
Stop using the 'compute-size' phase of the frame clock, use the layout
phase instead, now that GTK isn't using the layout phase anymore.
2020-12-07 09:46:39 +01:00
Jonas Ådahl
ecc861bf06
Pass the layout signal via GdkSurface to GtkRoot
...
Don't have GtkRoot listen directly to the layout signal on the frame
clock, but let it pass through GdkSurface. This will allow GdkSurface to
be more involved in the layout phase.
2020-12-07 09:46:39 +01:00
Jonas Ådahl
475c07e935
gdk/surface: Make pending schedule a phase enum
...
Scheduling an update when frozen would reschedule when unfrozen; change
this to a generic pending phase enum, and use this for resrcheduling
paint and compute-size.
2020-12-07 09:46:39 +01:00
Jonas Ådahl
0c8d97e3f7
gtk/root: Validate css node after update
...
It should happen before layout, but after the animation tick, thus after
the update.
2020-12-07 09:46:39 +01:00
Jonas Ådahl
8d4f8f0cfc
wayland: Concentrate size computation to 'compute-size' phase
...
This includes computing the surface size, including shadow margin,
setting the surface size, during the 'compute-size' clock phase.
2020-12-07 09:46:39 +01:00
Jonas Ådahl
289b50785b
wayland/surface: Don't save uninitialized size
...
GdkSurface's are initialized to have the size 1x1, as otherwise we'd
receive an X11 error, would a corresponding X11 window be created.
This confuses the "saved size" mechanisms in the Wayland backend, as
treats 0 as uninitialized, and not 1.
Fix this simply not saving size that if it's smaller or equal than 1.
2020-12-07 09:46:39 +01:00
Jonas Ådahl
68c14242b2
gdk/surface: Add API to request 'compute-size' clock phase
2020-12-07 09:46:39 +01:00
Jonas Ådahl
4af54fb410
gdk/surface: Use helper to emit 'size-changed' signal
2020-12-07 09:46:39 +01:00
Jonas Ådahl
13b4a4b24c
gdk/toplevelsize: Add way to set margin
...
Will be used to communicate the shadow margin, instead of using
gdk_surface_set_shadow_width().
Also set these values in gtkwindow.c.
2020-12-07 09:46:39 +01:00
Jonas Ådahl
e07fde5c81
frame-clock: Add 'compute-size' phase
...
This will be handled between 'update' (which may trigger animation
ticks, CSS update, etc) and 'layout' which will allocate the widget
tree. It's meant to perform surface size computation, and is done
between these two phases in order to have an up to date state, and
letting the layout phase have an up to date size to layout in.
2020-12-07 09:46:39 +01:00
Jonas Ådahl
8f27b3fcf6
gtk/window: Let the backend handle toplevel freezing
2020-12-07 09:46:39 +01:00
Jonas Ådahl
251bd15597
wayland: Apply new surface state at the beginning of a frame
...
Concentrate state application to the start of a frame; this is to avoid
having GTK going back and forth between different state if so would
happen between two frames.
2020-12-07 09:46:39 +01:00
Jonas Ådahl
dd738d2787
surface: Only keep state 'withdrawn' after hiding
...
A hidden surface should start from a clean slate when showing again, so
clear any now out of date state.
2020-12-07 09:46:39 +01:00
Jonas Ådahl
18d92c3f16
wayland: Keep pending initial state separate
...
Queue it, and then wait for it to actually take effect, i.e. be
confirmed via a configure event from the compositor, before setting the
actual GdkSurface::state value.
2020-12-07 09:46:39 +01:00
Jonas Ådahl
f4c36fe1ce
gdk/surface: Add API to queue and apply state changes
...
This will be used to compress state changes and apply as part of a frame
clock dispatch.
2020-12-07 09:46:39 +01:00
Jonas Ådahl
23d7392eb9
gdk/surface: Removed unused struct field
...
The 'old_state' wasn't used anywhere, lets remove it.
2020-12-07 09:46:39 +01:00
Jonas Ådahl
996eeec16c
gtk/window: Don't gdk_toplevel_present() if not mapped
...
That would map the window too early.
2020-12-07 09:46:39 +01:00
Jonas Ådahl
641915974b
gdk/toplevel: Make gdk_toplevel_present() async
...
The plan is to concencrate size computations as part of the frame clock
dispatch, meaning we shouldn't do it synchronously in the present()
function.
Still, in Wayland, and maybe elsewhere, it is done in the present()
function, e.g. when no state change was made, but this will eventually
be changed.
2020-12-07 09:46:39 +01:00
Jonas Ådahl
528ec4dded
wayland: Only set mapped state when mapped
...
Mapping a surface under Wayland is an asynchronous process, where one
creates a surface and commits an initial state without having drawn
anything, then waiting for a configuration, which then is acknowledged
and content is painted and committed. Not until having received this
configuration is a surface actually mapped, so wait with setting the
mappedness until this.
2020-12-07 09:46:39 +01:00
Jonas Ådahl
366b946f5b
wayland/popup: Use maybe_notify_mapped() helper
2020-12-07 09:46:38 +01:00
Jonas Ådahl
9e6a55a086
wayland: Decouple mapped state from surface creation
2020-12-07 09:46:38 +01:00
Christian Hergert
285781724f
macos: set opengl view as opaque in opaque windows
...
We don't need the OpenGL view to be transparent if the window itself
is not transparent. This has the potential to speed up the compositing
of the GL view onto the NSWindow.
2020-12-06 20:14:52 -08:00
Emmanuele Bassi
2d103cf80c
Merge branch 'wayland-inhbit0' into 'master'
...
wayland: avoid referencing unallocated memory when uninhibiting
See merge request GNOME/gtk!2927
2020-12-07 00:26:50 +00:00
Michael Terry
c8d991e4de
wayland: avoid referencing unallocated memory when uninhibiting
2020-12-06 18:37:40 -05:00
Zander Brown
a165bb9f46
Update British English translation
2020-12-06 22:08:30 +00:00
Timm Bäder
33ed42d985
gl renderer: Remove RESET_OPACITY flag
...
We always need to do that (and always passed the flag to
add_offscreen_ops() anyway).
2020-12-06 20:03:35 +01:00
Timm Bäder
1ee4f6138b
gl renderer: Reset opacity when rendering blend node children
...
We render those on a texture, so we need to reset the opacity because
that will be applied when rendering the resulting texture.
2020-12-06 20:01:36 +01:00
Timm Bäder
7b61ef9e0f
gl renderer: Initialize rounded rect early
2020-12-06 19:57:48 +01:00
Timm Bäder
b46d077b3a
gl renderer: Fix rendering clipped blurred inset shadow nodes
2020-12-06 19:18:10 +01:00
Timm Bäder
e32331d002
gl renderer: Ignore crossfades between equal texture nodes
2020-12-06 19:18:10 +01:00
Timm Bäder
05928608ec
gl renderer: Use scale_x and scale_y everywhere
...
Try to handle two different values for scale in horizontal and vertical
direction better.
Fixes #3431
2020-12-06 19:18:05 +01:00
Emmanuele Bassi
d8c9a67d20
docs: Clarify gtk_widget_activate()
...
We need to tell people what signal will be emitted when calling
gtk_widget_activate(), and that the shortcuts API might be more
appropriate to what they are looking for.
2020-12-06 15:13:57 +00:00
Emmanuele Bassi
c352fe9ab0
Move activate_signal to the widget private class data
...
Instead of having it as a field in the class structure.
2020-12-06 15:06:18 +00:00
Emmanuele Bassi
e396874f3c
Merge branch 'ebassi/a11y-leak' into 'master'
...
a11y: Plug a leak in the AT-SPI context
Closes #3450
See merge request GNOME/gtk!2926
2020-12-05 20:52:04 +00:00
Emmanuele Bassi
f6c53ced0d
a11y: Plug a leak in the AT-SPI context
...
Fixes : #3450
2020-12-05 20:25:30 +00:00
Matthias Clasen
ee26e282cc
Update contribution guide
...
Make my feelings about bug reporting by screencast known.
2020-12-05 11:34:52 -05:00
Matthias Clasen
894f893223
Merge branch 'revert-round-windows' into 'master'
...
Revert "theme: Round all window corners"
See merge request GNOME/gtk!2921
2020-12-05 15:10:16 +00:00
Piotr Drąg
67d7e2007f
Update POTFILES.in
2020-12-05 15:05:48 +01:00
Emmanuele Bassi
3a9cca74fc
Use WidgetClass.activate_signal getter function
2020-12-05 01:04:18 +00:00
Emmanuele Bassi
fe9c0db603
Add getter for WidgetClass.activate_signal
...
Just like we have a setter.
2020-12-05 01:04:18 +00:00
Emmanuele Bassi
fde32c5219
Use private can_activate() method
...
Instead of checking the activate_signal field directly.
2020-12-05 01:04:18 +00:00
Emmanuele Bassi
213024a560
Use function setter for WidgetClass.activate_signal
2020-12-05 01:04:18 +00:00
Emmanuele Bassi
e5e18ddffb
Add private method to check activatability
...
We should have an actual method, instead of checking the
WidgetClass.activate_signal directly.
2020-12-05 01:04:18 +00:00
Emmanuele Bassi
b3e03fa6f0
Add wrappers for setting the WidgetClass.activate_signal field
...
Setting a field on a class structure is not always an easy task from
languages other than C. While bindings can provide access to the class
pointer, twiddling the fields in the class structure can be awkward.
Additionally, signal ids are not always readily available.
We can paper over the direct access to the class structure, as well as
the "signal name to id" mapping with a simple couple of setter
functions.
2020-12-05 01:04:18 +00:00
Emmanuele Bassi
c0586ca6e2
Merge branch 'wip/jfelder/customsorter-null' into 'master'
...
customsorter: Add missing nullable annotation
See merge request GNOME/gtk!2923
2020-12-04 23:39:48 +00:00
Jean Felder
4430314514
customsorter: Add missing nullable annotation
2020-12-05 00:04:36 +01:00
Emmanuele Bassi
4087055b18
Merge branch 'wip/chergert/gdk-macos-for-master' into 'master'
...
macos: fix GL renderer for macOS
Closes #3420
See merge request GNOME/gtk!2922
2020-12-04 22:37:00 +00:00
Christian Hergert
a47c0065fb
macos: enable GL renderer by default
...
Now that the attribute locations are fixed for the GL renderer, we can
enable it by default on macOS.
Fixes #3420
2020-12-04 13:41:31 -08:00
Christian Hergert
6883c2214b
gl: specify attribute locations for vUv and aPosition
...
These positions are not guaranteed to be in a specific order when linked
into the final GPU program. They need to be specified so that our code
in gskglrenderer.c can use known positions for them to match up with
our GskQuadVertex.
This fixes the GL renderer on macOS's OpenGL shader compiler.
Fixes #3420
2020-12-04 13:33:34 -08:00
Matthias Clasen
7f6fdd6e7b
Merge branch 'matthiasc/for-master' into 'master'
...
emoji chooser: Fix incremental loading
Closes #3438
See merge request GNOME/gtk!2920
2020-12-04 17:21:56 +00:00
Matthias Clasen
24124452d5
docs: Fix up GtkPicture docs
...
These were missing proper linking.
2020-12-04 11:47:43 -05:00
Matthias Clasen
0dff89d9fb
Revert "theme: Round all window corners"
...
This reverts commit e46522e4b5 .
2020-12-04 11:13:26 -05:00
Matthias Clasen
f0f64f42ee
emoji chooser: Fix incremental loading
...
This broke when we started using GDK_PROFILER_CURRENT_TIME for
timekeeping - that gets defined to 0 when we're building without
sysprof, so we can use it to make such determinations. Go back
to using g_get_monotonic_time().
Fixes : #3438
2020-12-04 11:09:43 -05:00
Matthias Clasen
d278afc85b
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
See merge request GNOME/gtk!2918
2020-12-04 04:12:41 +00:00
Matthias Clasen
423b8209a1
gtk-demo: Use a native filechooser in the words demo
2020-12-03 22:31:05 -05:00
Benjamin Otte
559f74e0c1
Merge branch 'picture-docs2' into 'master'
...
Add docs about sizing pictures
See merge request GNOME/gtk!2917
2020-12-04 02:04:19 +00:00
Benjamin Otte
66c3a43e96
Add docs about sizing pictures
...
Suggested by Christopher Davis.
2020-12-04 02:04:19 +00:00
Matthias Clasen
d83554121f
gtk-demo: Use a native file chooser in the svg demo
2020-12-03 19:44:45 -05:00
Matthias Clasen
2688b94133
gtk-demo: Use a native filechooser in the video demo
2020-12-03 19:44:34 -05:00
Matthias Clasen
e035baee8a
gtk-demo: Remove empty row in the pickers demo
...
The file chooser button is gone.
2020-12-03 19:25:04 -05:00
Emmanuele Bassi
f1ff8f9aad
Merge branch 'wip/chergert/macos-decelerate' into 'master'
...
macos: fix typo when creating scroll events
Closes #3418
See merge request GNOME/gtk!2916
2020-12-03 22:54:46 +00:00
Christian Hergert
115ea624d9
macos: fix typo when creating scroll events
...
This fixes an issue where we would ignore events with Y delta
and no X delta while scrolling due to a typo when checking for
any delta.
This fixes deceleration of kinetic scrolling on the macOS backend.
Fixes #3418
2020-12-03 13:46:47 -08:00
Matthias Clasen
6ecae6c5f8
Merge branch 'wip/chergert/gdk-macos-for-master' into 'master'
...
macos: fix motion event delivery after closing transient window
Closes #3419
See merge request GNOME/gtk!2910
2020-12-03 20:07:16 +00:00
Matthias Clasen
6d76b587cf
Merge branch 'wip/chergert/shadertoy-macos-fix' into 'master'
...
demos: make alienplanet demo work on macOS OpenGL
See merge request GNOME/gtk!2915
2020-12-03 19:00:39 +00:00
Christian Hergert
8e62ff50fe
demos: make alienplanet demo work on macOS OpenGL
...
On the macOS OpenGL implementation, the use of noise2 as a
function within the glsl shader collides with the builtin noise2 of a
different signature.
This changes the name to something similar (noize2) so that we
do not risk colliding names when linking.
With this commit, the shadertoy alienplanet demo works on mac
OpenGL (albeit still with the Cairo renderer).
2020-12-03 10:23:13 -08:00
Matthias Clasen
0daa905a27
Merge branch 'wip/otte/conic' into 'master'
...
Implement a GL shader for conic gradients
See merge request GNOME/gtk!2913
2020-12-03 17:14:01 +00:00
Emmanuele Bassi
d1a4ad3db6
Merge branch 'wip/tintou/gdk-backends-header' into 'master'
...
build: Use the correct path to the header of the wayland and x11 backends
See merge request GNOME/gtk!2914
2020-12-03 12:32:24 +00:00
Benjamin Otte
2c1bd399d2
glrenderer: Implement a shader for conic gradients
2020-12-03 13:07:17 +01:00
Benjamin Otte
fac5fba0dc
rendernode: Fix some wrong constants for conic gradients
...
copy/paste from other nodes left some wrong values in there and that
screwed things up quite a bit.
2020-12-03 13:07:17 +01:00
Benjamin Otte
c907ad83b0
glrenderer: Emit more useful error messages
...
Catch the error when it happens, so that we can emit a specific and more
helpful error message.
Also verify that all branches in the code now do indeed set a proper
GError when they fail, so that the final catch-all is no longer needed.
Instead, assert that the error is set so that we catch future code
additions early that do not set the GError.
2020-12-03 13:07:17 +01:00
Corentin Noël
585ba777c2
build: Use the correct path to the header of the wayland and x11 backends
2020-12-03 10:02:03 +01:00
Matthias Clasen
f8ee4cfea5
NEWS: Updates
2020-12-02 23:10:39 -05:00
Matthias Clasen
35d2cbefe6
Merge branch 'wip/otte/conic' into 'master'
...
Add support for conic gradients
See merge request GNOME/gtk!2911
2020-12-03 03:54:24 +00:00
Christian Hergert
004f0a6596
macos: plug leak of application windows
...
This ensures that we don't leak window references inside the action muxer.
Otherwise, we risk not disposing the windows upon gtk_window_destroy()
and blocking the main loop from quitting.
Fixes #3419
2020-12-02 19:44:02 -08:00
Christian Hergert
b68e0bb3fb
muxer: add helper to get group by name
...
This is useful when you need to read a group back out of the muxer.
2020-12-02 19:44:02 -08:00
Christian Hergert
92f0216605
macos: ensure element is part of queue
...
We don't want to risk decrementing length field unless this is actually
part of the queue.
2020-12-02 19:44:02 -08:00
Christian Hergert
e317b9be00
macos: maintain GList element consistency
...
We need to keep this consistent so that we can look things up
faster in other places. Therefore, just take the hit here and clear
the entire list ensuring prev/next poniters are cleared.
2020-12-02 19:44:01 -08:00
Christian Hergert
2e52386be5
macos: send focus-out event to windowing
2020-12-02 19:44:01 -08:00
Christian Hergert
9431c70a6a
macos: freeze updates until surface is mapped
...
This more closely matches the X11 backend in terms of freezing
updates on the surface initially until we get mapped.
2020-12-02 19:44:01 -08:00
Matthias Clasen
6e67d44aa3
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
Closes #3429
See merge request GNOME/gtk!2912
2020-12-03 03:43:19 +00:00
Benjamin Otte
e622013f7e
css: Add support for conic-gradient()
...
This comes complete with animation support. For a good time, try:
@keyframes conic {
100% { background-image: conic-gradient(from 1turn, red, lime, blue, yellow, red); }
}
window {
background-image: conic-gradient(red, lime, blue, yellow, red);
animation: conic infinite linear 5s;
}
2020-12-03 04:13:33 +01:00
Benjamin Otte
3886f0c530
Merge branch 'wip/otte/diediedie' into 'master'
...
Remove GtkFileChooserButton
See merge request GNOME/gtk!2909
2020-12-03 01:31:39 +00:00
Benjamin Otte
eb9c204535
gtk: Remove GtkFileChooserButton
...
... as discussed in the meeting.
2020-12-03 02:02:27 +01:00
Matthias Clasen
ab9e99218f
docs: Remove mentions of <accelerator>
...
That is no longer supported, keyboard shortcuts
are done with GtkShortcut now.
Fixes : #3429
2020-12-02 19:59:44 -05:00
Matthias Clasen
714c610d6b
gtk-demo: Add a search button
...
Easter eggs are great, but search shouldn't be one.
2020-12-02 19:53:55 -05:00
Benjamin Otte
8706d69e60
snapshot: Add gsk_snapshot_append_conic_gradient()
2020-12-03 01:15:53 +01:00
Benjamin Otte
55a242bd81
gsk: Add GskConicGradientNode
2020-12-03 00:47:54 +01:00
Matthias Clasen
61b40c47f9
Merge branch 'fix/keyboard-input' into 'master'
...
Gdk4/Win32: Correct calls to gdk_key_event_new()
See merge request GNOME/gtk!2903
2020-12-02 22:14:27 +00:00
Matthew Jakeman
710d0620a4
Gdk4/Win32: Correct call to gdk_key_event_new()
...
The keycode and modifier (state) parameters are in the wrong order
for gdk_key_event_new() in the gdk win32 backend, which causes
key up/down events to be populated incorrectly.
2020-12-02 22:14:27 +00:00
Benjamin Otte
71cb7c2063
rendernodeparser: Split out a function
2020-12-02 21:48:35 +01:00
Matthias Clasen
a482d870dd
Merge branch 'wip/chergert/gdk-macos-for-master' into 'master'
...
Revert "macos: specify a window level for surfaces"
See merge request GNOME/gtk!2908
2020-12-02 20:15:51 +00:00
Emmanuele Bassi
bc4992fef9
Merge branch 'ebassi/doc-fixes' into 'master'
...
Ebassi/doc fixes
Closes #3428
See merge request GNOME/gtk!2906
2020-12-02 20:08:05 +00:00
Christian Hergert
b38d0d7d9e
macos: resign main/key when hiding window
...
This isn't done automatically for us, so we need to synthesize it in
our hide helper.
With this commit, we properly re-focus the new main/key window after
we have closed a transient-for window.
2020-12-02 11:36:38 -08:00
Christian Hergert
853a9c7a8c
macos: disconnect frame clock when destroying surface
2020-12-02 11:35:02 -08:00
Christian Hergert
26b9254ac7
macos: track grab serial like other backends
...
This is what is done elsewhere, so copy that here too now that we actually
generate serials for events.
2020-12-02 11:34:31 -08:00
Benjamin Otte
a51f11999a
tests: Remove testsvg
...
That demo lives in gtk-demo now.
2020-12-02 20:17:28 +01:00
Christian Hergert
f11c23f407
Revert "macos: specify a window level for surfaces"
...
This reverts commit ca8b00e871 .
This isn't needed and causes issues with other applications getting
stacked beneath our windows.
2020-12-02 11:15:57 -08:00
Emmanuele Bassi
0c8de4e561
Fix transfer of GtkTreeExpander.get_item()
...
We return a full reference to the item.
Fixes : #3428
2020-12-02 19:10:13 +00:00
Emmanuele Bassi
13f9993007
docs: Add missing fields to GtkTextBufferClass
2020-12-02 19:05:41 +00:00
Emmanuele Bassi
b2b451d762
docs: Hide private files/directories in the GTK reference
2020-12-02 19:05:41 +00:00
Emmanuele Bassi
2e146a56f7
docs: Mark GtkModelButton's section as private
...
The widget is not public any more.
2020-12-02 19:05:41 +00:00
Emmanuele Bassi
34197d4f8a
docs: Add more symbols to the GDK reference
2020-12-02 19:05:41 +00:00
Emmanuele Bassi
39dbd91bb0
docs: Add yet another private header
2020-12-02 19:05:41 +00:00
Emmanuele Bassi
901d99d7c5
docs: More ignored files
2020-12-02 19:05:41 +00:00
Emmanuele Bassi
8f6e3848f6
docs: Remove duplicate symbol
2020-12-02 19:05:41 +00:00
Emmanuele Bassi
3548350dfa
docs: Add missing GdkDragSurfaceInterface gtk-doc annotation
2020-12-02 19:05:41 +00:00
Emmanuele Bassi
caae240bc7
docs: Ignore harder
...
First of all, we must list *all* ignored headers. Since we have public
headers in the x11 and wayland directories, we must explicitly declare
all headers that we consider private under those directories.
The "quartz" subdirectory was renamed "macos", with the new macOS
backend. The "mir" directory was removed, so there's no need to ignore
it.
We are also missing a bunch of ignored headers in the top-level gdk
directory.
Finally, pass the list of ignored files to gtkdoc-mkdb, so we won't get
missing declaration warnings.
2020-12-02 19:05:41 +00:00
Emmanuele Bassi
f5f6ceece5
docs: Remove private symbols from the API reference
2020-12-02 19:05:41 +00:00
Emmanuele Bassi
4caceb5dd4
Remove gtk-doc annotation from private symbols
...
Keep the documentation, just tweak it so that gtk-doc won't try to find
the declarations of these private symbols.
2020-12-02 19:05:41 +00:00
Matthias Clasen
3da41b6021
Merge branch 'wip/chergert/gdk-macos-for-master' into 'master'
...
macos: fix window stacking
See merge request GNOME/gtk!2907
2020-12-02 18:38:14 +00:00
Christian Hergert
9b9fb4d7a3
macos: place above transient-for when presenting
...
We need to re-attach to the transient-for window whenever we present or
we risk getting placed behind the window by the display server. Apparently
that setting does not persist across a hide of the NSWindow.
2020-12-02 10:21:16 -08:00
Christian Hergert
ca8b00e871
macos: specify a window level for surfaces
2020-12-02 10:15:43 -08:00
Matthias Clasen
4434889e41
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
See merge request GNOME/gtk!2905
2020-12-02 15:57:39 +00:00
Bilal Elmoussaoui
475352fbc0
StringList: add missing nullability annotations
2020-12-02 10:36:29 -05:00
Bilal Elmoussaoui
ad30ac3932
Shortcut: add missing nullability annotations
2020-12-02 10:29:16 -05:00
Bilal Elmoussaoui
9d52ca1887
StringFilter: get_search fix nullable annotation
2020-12-02 10:28:07 -05:00
Bilal Elmoussaoui
ec537d75e4
Text: add missing nullability annotations
2020-12-02 10:28:07 -05:00
Bilal Elmoussaoui
b47ea9421f
TextView: add missing nullability annotations
2020-12-02 10:28:07 -05:00
Bilal Elmoussaoui
845d2e5433
TreeModel: add missing nullability annotations
2020-12-02 10:28:07 -05:00
Bilal Elmoussaoui
50310f7b14
TreeView: add missing nullability annotations
2020-12-02 10:28:07 -05:00
Matthias Clasen
af944aa74c
widget: Add a missing nullability annotation
2020-12-02 10:08:58 -05:00
Matthias Clasen
b5077d02ed
Clarify the docs for gtk_widget_class_set_css_name
...
Reword, and mention the default css name.
2020-12-02 10:06:01 -05:00
Bilal Elmoussaoui
6a3bd1c4d1
window: default_icon_name can be null
2020-12-02 10:00:18 -05:00
Emmanuele Bassi
2fcd0e21bd
Merge branch 'ebassi/for-master' into 'master'
...
Various documentation fixes
See merge request GNOME/gtk!2900
2020-12-02 13:40:25 +00:00
Daniel Mustieles
5127726bbc
Updated Spanish translation
2020-12-02 13:54:32 +01:00
Daniel Mustieles
db456a70ee
Updated Spanish translation
2020-12-02 09:26:08 +01:00
Emmanuele Bassi
770e848953
Merge branch 'wip/chergert/gdk-macos-for-master' into 'master'
...
macos: various macos improvements for GTK 4
See merge request GNOME/gtk!2902
2020-12-02 01:14:30 +00:00
Christian Hergert
9e1dd15e31
macos: use Cairo renderer by default
...
Until the GL renderer is working on macOS OpenGL, we need to default
to the Cairo renderer.
2020-12-01 16:24:15 -08:00
Christian Hergert
27b9a9e7ef
macos: glFlush() when switching GL contexts
...
The Mac OpenGL programming guide suggests that you glFlush() before changing
contexts to ensure that the commands have been submitted.
2020-12-01 16:19:04 -08:00
Christian Hergert
a020c901ba
macos: treat some toplevel NSWindow like document windows
...
This makes the window animate in by the window manager like other
application windows on macOS. Currently ignored for transient windows.
2020-12-01 16:19:04 -08:00
Emmanuele Bassi
cdad68e858
docs: Ignore generated Wayland protocol file
2020-12-01 18:03:31 +00:00
Emmanuele Bassi
ef36028526
docs: Ignore more private files
2020-12-01 18:01:33 +00:00
Emmanuele Bassi
69b1b19315
docs: Annotate missing symbols
2020-12-01 17:28:16 +00:00
Emmanuele Bassi
516f71bbdc
Use the appropriate prefix for GtkBuilderClosureFlags
...
Facilitate the job of glib-mkenums, and ensure that the enumeration
nicknames are computed reliably.
2020-12-01 17:26:34 +00:00
Emmanuele Bassi
d820fea7a4
docs: Annotate GtkBuildableParser
2020-12-01 17:21:45 +00:00
Emmanuele Bassi
3e8d157118
docs: Hide GtkBitsetIter fields
2020-12-01 17:18:38 +00:00
Emmanuele Bassi
67f45940ce
docs: Annotate GtkAssistant::escape action signal
2020-12-01 17:18:23 +00:00
Emmanuele Bassi
95400e6451
docs: Annotate GtkAppChooserButton::changed
2020-12-01 17:16:05 +00:00
Emmanuele Bassi
d46fe31f54
docs: Ignore more files
2020-12-01 15:51:52 +00:00
Emmanuele Bassi
4f67be1c8e
docs: Add missing annotations for GtkTextTagTable
2020-12-01 15:51:52 +00:00
Emmanuele Bassi
c13e164f25
Make GtkCenterLayout accessors more idiomatic
...
Add argument validation, and emit a layout-changed signal whenever the
start, center, and end widgets change.
2020-12-01 15:51:52 +00:00
Emmanuele Bassi
eba8f36d4f
docs: Fix annotations in GtkCenterLayout
...
Missing ':' separator.
2020-12-01 15:51:52 +00:00
Emmanuele Bassi
37f11ab77d
docs: Annotate GskRenderer
2020-12-01 15:51:52 +00:00
Emmanuele Bassi
8b898818c2
docs: Annotate the GL shader objects
2020-12-01 15:51:52 +00:00
Emmanuele Bassi
0f62ab6c42
docs: Annotate all render node types
2020-12-01 15:51:52 +00:00
Emmanuele Bassi
c524b72d13
docs: Annotate structure types used by GskRenderNodes
2020-12-01 15:51:52 +00:00
Emmanuele Bassi
b5313dbd4d
docs: Annotate GdkDeviceTool
2020-12-01 15:51:52 +00:00
Emmanuele Bassi
b9a1827da7
docs: Annotate GdkGLTexture
2020-12-01 13:48:07 +00:00
Emmanuele Bassi
1057189ea2
docs: Annotate GdkMemoryTexture
2020-12-01 13:47:56 +00:00
Emmanuele Bassi
879b2845ad
docs: Annotate GdkPaintable
...
The dummy typedef needs a gtk-doc stanza, and the interface
documentation needs to be slightly clarified.
2020-12-01 13:44:51 +00:00
Emmanuele Bassi
ecce3756d4
docs: Annotate GdkPopup
2020-12-01 13:42:07 +00:00
Emmanuele Bassi
6e4dd5811d
docs: Annotate GdkSnapshot
2020-12-01 13:41:28 +00:00
Emmanuele Bassi
598e1304f6
docs: Annotate the GdkToplevel interface
2020-12-01 13:39:48 +00:00
Emmanuele Bassi
e3fbc0ee9c
docs: Fix typo in the GdkTolevelLayout annotation
2020-12-01 13:38:33 +00:00
Emmanuele Bassi
4021734047
docs: Annotate the GdkContentProviderClass structure
2020-12-01 13:38:12 +00:00
Emmanuele Bassi
5a307fa7f3
docs: Ignore more private headers
2020-12-01 13:37:59 +00:00
Matthias Clasen
617d12fd77
Merge branch 'sophie-h/gtk-nullables-2'
...
Merge Sophie's nullable annotations, with some documentation
fixups on top.
2020-11-30 23:43:44 -05:00
Matthias Clasen
837f398a9b
columnviewcolumn: Improve docs
...
Mention what setting sorter to NULL means.
2020-11-30 23:40:03 -05:00
Matthias Clasen
e18211deca
centerlayout: Improve docs
...
Explain what passing NULL does.
2020-11-30 23:36:23 -05:00
Jordi Mas
32a547cc3e
Update Catalan translation
2020-11-30 22:35:47 +01:00
Matthias Clasen
365afa381a
Merge branch 'arnaudb/annotate-set-title' into 'master'
...
Add "nullable" annotation.
See merge request GNOME/gtk!2895
2020-11-30 21:14:28 +00:00
Matthias Clasen
b7d3c073f8
NEWS: Updates
2020-11-30 14:00:26 -05:00
Matthias Clasen
56b0095622
Merge branch 'master' into 'master'
...
broadway: make header name parsing case-insensitve
Closes #3406
See merge request GNOME/gtk!2894
2020-11-30 17:55:27 +00:00
Matthias Clasen
39f0c48eb2
Apply 1 suggestion(s) to 1 file(s)
2020-11-30 17:44:30 +00:00
Matthias Clasen
7d24e1405e
Apply 1 suggestion(s) to 1 file(s)
2020-11-30 17:42:39 +00:00
Matthias Clasen
3680ae220a
Merge branch 'matthiasc/for-master' into 'master'
...
build: Use link_whole for linking our convenience libs
See merge request GNOME/gtk!2899
2020-11-30 15:49:25 +00:00
Matthias Clasen
f309fa21c9
build: Use link_whole for linking our convenience libs
...
Without this, we lose exported symbols from e.g. libgsk
that are not used elsewhere in the code.
2020-11-30 09:56:55 -05:00
Matthias Clasen
61e7326f22
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
Closes #3364
See merge request GNOME/gtk!2898
2020-11-30 14:44:15 +00:00
Timm Bäder
dc13ff97e2
modelbutton: Reset active menu item on pointer leave
...
We don't want to leave an active menu item behind if the pointer doesn't
enter another menu item.
This matches the old GtkMenu behavior
2020-11-30 09:23:03 -05:00
Timm Bäder
af28237569
popovermenu: Connect to right controller signal
...
leave is emitted before the new contains-pointer value is set, so the
signal handler wasn't working right.
2020-11-30 09:22:57 -05:00
Timm Bäder
ff8de0a93f
eventcontrollermotion: Notify by pspec
2020-11-30 09:22:49 -05:00
Timm Bäder
aefabcc056
popovermenu: Pull variable declaration in closest scope
2020-11-30 09:22:41 -05:00
Timm Bäder
1d6c6fc3b8
shortcutcontroller: Separate trigger/action early returns
...
We take this early return in update_accel over 36k times when starting
the widget factory and always because the action is not a named action.
2020-11-30 09:22:34 -05:00
Timm Bäder
8645773fc6
shortcutcontroller: Pass the muxer to update_accel()
...
We only needed the widget to get its action muxer. And this way we don't
have to call gtk_widget_get_action_muxer() dozens of times, just once in
set_widget().
2020-11-30 09:22:29 -05:00
Timm Bäder
d663909159
shortcutcontroller: Use priv->shortcuts directly in set_widget()
...
Instead of treating the shortcut controller itself as a GListModel,
which just passes everything along from priv->shortcuts.
2020-11-30 09:22:21 -05:00
Timm Bäder
e3ff92bc87
shortcutcontroller: Save signal handler ID
...
gtk_shortcut_controller_finalize() used to take ~13.8% when closing the
complex listbox demo in gtk4-demo. Now it takes nothing.
2020-11-30 09:21:57 -05:00
Timm Bäder
2d43ecf8ca
widget: root child before emitting child observer signals
...
Try to avoid the childen_observer signal handlers screwing up internal
state.
Fixes #3364
2020-11-30 09:21:52 -05:00
Timm Bäder
5f4beb711f
widgetprivate: Remove unused function
2020-11-30 09:21:42 -05:00
Timm Bäder
da514187f5
gl renderer: Make minimal rounded rects more minimal
2020-11-30 09:21:34 -05:00
Matthias Clasen
6bd9ce7b55
docs: Ignore more generated Wayland protocol headers
...
These inject mysterious words like Airbrush, Lense and
Mouse into the list of undocumented apis. No need for that.
2020-11-30 09:21:24 -05:00
Matthias Clasen
ec21d354b9
gsk: doc fixups
2020-11-30 09:21:24 -05:00
Matthias Clasen
8cf4ce5d9e
Merge branch 'ebassi/cell-renderer-get-size' into 'master'
...
Remove GtkCellRendererClass.get_size()
See merge request GNOME/gtk!2896
2020-11-30 14:09:03 +00:00
Emmanuele Bassi
09b6c37e1d
Merge branch 'ebassi/for-master' into 'master'
...
Blend nodes might have NULL top/bottom nodes
See merge request GNOME/gtk!2891
2020-11-30 13:10:25 +00:00
Piotr Drąg
3161dbfff2
Update Polish translation
2020-11-29 12:11:26 +01:00
Yuri Chornoivan
8412928a14
Update Ukrainian translation
2020-11-29 07:53:56 +00:00
Emmanuele Bassi
60a7830ba5
Remove GtkCellRendererClass.get_size()
...
The get_size() vfuncs is deprecated in GTK3, and only used as a
fallback path for cell renderers that do not implement preferred
size virtual functions.
2020-11-28 19:21:24 +00:00
Emmanuele Bassi
ac473282a2
Port CellRendererGraph to preferred size vfuncs
...
Drop use of GtkCellRendererClass.get_size()
2020-11-28 19:21:24 +00:00
Emmanuele Bassi
20f9e0f144
Port GtkCellRendererProgress to preferred size vfuncs
...
Drop the use of GtkCellRendererClass.get_size()
2020-11-28 19:21:24 +00:00
Emmanuele Bassi
71a9e5d8c2
Port GtkCellRendererToggle to preferred size vfuncs
...
Drop the use of GtkCellRendererClass.get_size()
2020-11-28 19:21:24 +00:00
Emmanuele Bassi
a605fcc2bd
Port GtkCellRendererSpinner to preferred size vfuncs
...
Drop the use of GtkCellRendererClass.get_size()
2020-11-28 19:21:23 +00:00
Emmanuele Bassi
3eaebf1e0b
Port GtkCellRendererPixbuf to preferred size vfuncs
...
Drop the GtkCellRendererClass.get_size() override.
2020-11-28 19:21:23 +00:00
Аляксей
e540ccbd34
Update Belarusian translation
2020-11-28 14:30:43 +00:00
Arnaud Bonatti
55ce61d1a8
Add "nullable" annotation.
2020-11-28 12:15:38 +01:00
Jakub Steiner
8e14f43398
Merge branch 'wip/jimmac/dark-prelights' into 'master'
...
wip/jimmac/dark prelights
Closes #3380
See merge request GNOME/gtk!2892
2020-11-27 18:14:09 +00:00
Jakub Steiner
bbbcc72460
Adwaita,HC: use dark prelights
...
- increase :hover visibility by going darker rather than lighter
puppies died.
Fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/3380
2020-11-27 18:17:12 +01:00
Anders Jonsson
c2b1b00e52
Update Swedish translation
2020-11-27 13:35:03 +00:00
Anders Jonsson
05c2e35c5d
Update Swedish translation
2020-11-27 13:31:30 +00:00
Benjamin Beichler
8efde9c48c
broadway: make header name parsing case-insensitve
...
since http RFC state that the header names should be processed case in-sensitive, broadway should not rely on the actual case. E.g. the go-language libraries tend to rewrite the header, which cause problems with e.g. Caddy
Fixes #3406
2020-11-27 12:05:51 +01:00
Emmanuele Bassi
247fc2e471
Blend nodes might have NULL top/bottom nodes
...
We have code in place to handle a NULL node in the state when dealing
with blend nodes, but we don't always check for NULL, which leads to
warnings in the CSS Blend modes demo.
2020-11-26 00:21:11 +00:00
Matthias Clasen
9d2ca90b4c
popover: Fix a typo
...
s/Wether/Whether/
Fixes #3393
2020-11-25 13:59:16 -05:00
Emmanuele Bassi
3a5f8b6192
Merge branch 'ebassi/for-master' into 'master'
...
Ebassi/for master
Closes #3404 and #3403
See merge request GNOME/gtk!2890
2020-11-25 18:43:53 +00:00
Emmanuele Bassi
16b5a88097
a11y: Check before disconnecting Text signals
...
Use the same initial check for the accessible object type that we use
when connecting the signal, in case we try to disconnect signals on
different widgets. Additionally, check before accessing data that might
have already been removed.
Fixes : #3403
2020-11-25 18:15:04 +00:00
Emmanuele Bassi
fdf2e046c3
a11y: Check before disconnecting selection signals
...
If the selection data has already been cleared we should just bail out.
Fixes : #3404
2020-11-25 18:13:54 +00:00
Jakub Steiner
531d57f30c
Merge branch 'wip/jimmac/menus-darker' into 'master'
...
Adwaita: darker selected menuitem + sidebars
Closes #3390
See merge request GNOME/gtk!2881
2020-11-25 13:42:55 +00:00
Jordi Mas i Hernandez
841bf67bb9
Update Catalan translation
2020-11-25 13:42:11 +00:00
Jakub Steiner
399b457f54
Adwaita: darker selected menuitem + sidebars
...
- without sacrificing the fg/bg contrast too much, increase
selected item visibility
Fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/3390
2020-11-25 14:28:19 +01:00
Sophie Herold
fed734edfc
Fix some nullable return annotations 2
2020-11-24 19:27:33 +01:00
Matthias Clasen
c84c014536
Merge branch 'wip/chergert/for-master' into 'master'
...
textview: fix precondition assertions
Closes #3386
See merge request GNOME/gtk!2886
2020-11-24 17:14:53 +00:00
Christian Hergert
1e994419ee
textview: fix precondition assertions
...
It is a programmer error to call this with a child widget that has not
been placed within the GtkTextView.
Fixes #3386
2020-11-24 08:29:52 -08:00
Matthias Clasen
7b22c44b39
Merge branch 'fix-integer-overflow' into 'master'
...
gdk/win32: fix integer overflow in monitor refresh rate calculation
Closes #3394
See merge request GNOME/gtk!2884
2020-11-24 16:22:49 +00:00
Anders Jonsson
2e744260e0
Update Swedish translation
2020-11-23 22:09:28 +00:00
Volker Rümelin
7190a31b5f
gdk/win32: fix integer overflow in monitor refresh rate calculation
...
In gdk/win32/gdkmonitor-win32.c in function
populate_monitor_devices_from_display_config() refresh->Numerator * 1000
overflows for refresh->Numerator > 4294976.
Cast the factor 1000 to UINT64 to prevent the overflow.
Fixes #3394
2020-11-23 21:42:58 +01:00
Matthias Clasen
729f007379
Merge branch 'no-more-devel-headers' into 'master'
...
Drop devel styling from our windows
See merge request GNOME/gtk!2882
2020-11-23 19:01:44 +00:00
Matthias Clasen
b75b359f19
Drop devel styling from our windows
...
We are about to do a stable release. Time to get used
again to plain old, boring header bars.
2020-11-23 12:10:01 -05:00
Emmanuele Bassi
d7de720275
Merge branch 'ebassi/for-master' into 'master'
...
Ebassi/for master
See merge request GNOME/gtk!2876
2020-11-23 15:41:03 +00:00
Emmanuele Bassi
ef86e46238
a11y: Cache the accessibility bus address
...
Just check for it once; doing it every time we failed to create an
ATContext is just going to fill up the logs.
2020-11-23 14:34:46 +00:00
Emmanuele Bassi
0a46baeb56
a11y: Turn critical warnings into debug messages
...
The accessibility bus might not be available, and if it isn't the case,
it means something has failed at a level where the user can't do much
about it. There's no need to emit a critical warning.
2020-11-23 14:34:46 +00:00
Emmanuele Bassi
fd3a6299ce
Merge branch 'ebassi/glib-min-version' into 'master'
...
Ebassi/glib min version
See merge request GNOME/gtk!2880
2020-11-23 14:33:20 +00:00
Emmanuele Bassi
803b147483
Disable deprecation warnings from GLib
...
We don't want to test the latest changes in GLib in our own build.
2020-11-23 13:04:11 +00:00
Emmanuele Bassi
1f44319588
Drop redundant dependencies
...
PangoCairo already depends on Pango; Cairo-gobject already depends on
Cairo.
2020-11-23 13:04:11 +00:00
Emmanuele Bassi
505478bc59
Drop GLib dependency from GTK's declared dependencies
...
We depend on GObject, which already depends on GLib; on older versions
of Meson, this ends up trying to depend on the system copy of GLib,
instead of the sub-project copy, in case the version of GLib we have
installed is too old.
2020-11-23 12:29:32 +00:00
Emmanuele Bassi
de7833b6a0
Use the right GLib macros for version checking
...
There's a typo in the name, and we never noticed.
2020-11-23 12:06:22 +00:00
Emmanuele Bassi
3a1b2083d6
Do not depend on GLib API introduced after 2.66
...
To avoid bleeding edge deprecations we use GLIB_VERSION_MIN_REQUIRED and
GLIB_VERSION_MAX_ALLOWED. Since we depend on GLib 2.66, we cannot use
API introduced in 2.67, even when conditionally compiled.
2020-11-23 12:06:22 +00:00
nana-4
3e996f61ae
icon-browser: Add .sidebar style class in the main window
...
So the sidebar can get the proper background and border colors.
2020-11-23 10:51:58 +01:00
nana-4
56eac4f846
gtk-demo: Add .sidebar style class in the main window
...
So the sidebar can get the proper background and border colors.
2020-11-23 10:51:58 +01:00
nana-4
61dcb685b2
Adwaita: Unify sidebar background-color
...
The sidebar item style is already unified. The sidebar background-color
should be unified as well.
See https://gitlab.gnome.org/GNOME/gtk/-/issues/3382
2020-11-23 10:51:58 +01:00
nana-4
bd0d75e237
Adwaita: Make sidebar row styling better
...
- Reorder declaration blocks for code legibility.
- Don't lighten text color on :hover and :selected for better contrast.
- Add missing :focus-visible:focus-within styling to non-:selected row.
2020-11-23 10:51:58 +01:00
nana-4
179fc68355
Adwaita: Fix some sidebar sizing
...
- Don't set the sidebar padding twice.
- Add padding to the assistant sidebar directly, as it doesn't have
.navigation-sidebar internally.
- Set missing margin to the sidebar separator.
See https://gitlab.gnome.org/GNOME/gtk/-/issues/3382
2020-11-23 10:51:58 +01:00
nana-4
9828756e05
Adwaita: Move placessidebar-specific sizing from .navigation-sidebar
...
The common .navigation-sidebar styling should be more generic.
2020-11-23 10:51:58 +01:00
nana-4
40f2b49c0d
Adwaita: Make treeexpander styling generic
...
The widget can be used outside .navigation-sidebar.
This also fixes the label misalignment in the widget.
2020-11-23 10:51:58 +01:00
nana-4
8e81cbef2c
stacksidebar: Add missing .navigation-sidebar to the inner list
...
Also don't set :show-separators, which is not applied in other sidebars.
See https://gitlab.gnome.org/GNOME/gtk/-/issues/3382
2020-11-23 10:51:58 +01:00
Timm Bäder
47d572834b
Merge branch 'scalebutton' into 'master'
...
properly set ScaleButton's parent_class
Closes #3381
See merge request GNOME/gtk!2877
2020-11-23 07:38:17 +00:00
Bilal Elmoussaoui
46601325f1
properly set ScaleButton's parent_class
...
GtkScaleButton doesn't subclass GtkButton anymore
Fixes #3381
2020-11-23 02:47:12 +01:00
Emmanuele Bassi
0abc7a3361
Merge branch 'nullables-1' into 'master'
...
Fix some nullable return annotations
See merge request GNOME/gtk!2873
2020-11-21 16:11:34 +00:00
Sophie Herold
1e01b9079d
Fix some nullable return annotations
2020-11-21 16:33:40 +01:00
Piotr Drąg
be688c46f2
Update POTFILES.skip
2020-11-21 14:39:17 +01:00
Jakub Steiner
ab163f168d
Merge branch 'wip/jimmac/clipped-menu-shadows' into 'master'
...
Adwaita: avoid clipping menu shadows
Closes #1987
See merge request GNOME/gtk!2872
2020-11-20 12:37:49 +00:00
Jakub Steiner
e937f7eac8
Revert "Adwaita: unified sidebar styles"
...
Doing the same mistake twice :( Even margin is eating from the container,
not expanding outside of it.
This reverts commit 6be575992f .
2020-11-20 13:24:23 +01:00
Jakub Steiner
b84945e43f
Merge branch 'wip/jimmac/sidebar-backdrop' into 'master'
...
Adwaita: don't backdrop labels
Closes #3377
See merge request GNOME/gtk!2868
2020-11-20 12:08:59 +00:00
Jakub Steiner
b3dba1dca6
Adwaita: avoid clipping menu shadows
...
Fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/1987
2020-11-20 13:04:04 +01:00
Jakub Steiner
060cfc713f
Merge branch 'wip/jimmac/unified-sidebar-styles' into 'master'
...
Adwaita: unified sidebar styles
Closes #3382
See merge request GNOME/gtk!2871
2020-11-20 11:40:30 +00:00
Jakub Steiner
6be575992f
Adwaita: unified sidebar styles
...
- stacksidebar focus, separation and color as everything else
- eliminate placessidebar double padding
Fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/3382
2020-11-20 12:24:40 +01:00
Jakub Steiner
4bec75c66b
Adwaita: don't backdrop labels
...
- instead of overriding :backdrop for sidebars, continue pursuing
not to backdrop anything but headerbar items and buttons.
Fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/3377
2020-11-20 09:34:23 +01:00
Matthias Clasen
8e4cc59a7a
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
See merge request GNOME/gtk!2870
2020-11-20 02:02:10 +00:00
Matthias Clasen
c17227966d
Merge branch 'wip/carlosg/for-master' into 'master'
...
gtk/main: Do not unset active state on button release w/o implicit grab
See merge request GNOME/gtk!2869
2020-11-20 01:46:03 +00:00
Matthias Clasen
a2ce6268b2
gtk-demo: Make a more interesting constraints demo
...
Show various ways to influence spacing. This is more or
less modeled on the way Androids constraint layout lets
you set up 'chains'.
2020-11-19 20:35:15 -05:00
Carlos Garnacho
5ab14ff7f6
gtk/main: Do not unset active state on button release w/o implicit grab
...
If an active grab gets undone on button press (e.g. closing a menu), we
will receive a button release on the new target even though it didn't handle
the button press, and disable ::active state.
This causes warnings when handling the button release, as it tries to undo
::active state that is not really there.
In order to fix this, check that the pointer focus actually had an implicit
grab at the time of receiving the button release, before trying to unset
the ::active state.
2020-11-19 22:58:14 +01:00
Emmanuele Bassi
8482b956d6
Merge branch 'ebassi/for-master' into 'master'
...
Ebassi/for master
See merge request GNOME/gtk!2867
2020-11-19 16:37:58 +00:00
Matthias Clasen
562c7b1ff3
Merge branch 'wip/chergert/gdk-macos-for-master' into 'master'
...
GTK4: various fixes
See merge request GNOME/gtk!2864
2020-11-19 16:05:47 +00:00
Jakub Steiner
8099de22f9
Merge branch 'wip/jimmac/industrial-style-menuitems' into 'master'
...
Adwaita: revert edge-to-edge menuitems
Closes #3366
See merge request GNOME/gtk!2866
2020-11-19 15:52:25 +00:00
Emmanuele Bassi
a4c3bee4a1
a11y: Hide children of GtkFishBowl
...
The fishbowl widget is purely presentational, and its children should
not be visible in the accessibility tree.
2020-11-19 15:20:56 +00:00
Emmanuele Bassi
5afa985e85
demo: Make GtkFishBowl a presentation widget
...
It has no accessible content, even if it displays widgets.
2020-11-19 15:20:56 +00:00
Emmanuele Bassi
e600a07237
a11y: Skip atspi.Cache signals for hidden elements
...
If the accessible object is hidden, we can skip the emission of the
AddAccessible and RemoveAccessible signals on the cache, as those
objects won't be visible in the accessibility tree.
2020-11-19 15:20:56 +00:00
Emmanuele Bassi
8fa58c2e17
a11y: Get the accessible role once
...
Simplify getting the accessible role when checking if an accessible
implementation should present itself; this avoids going through
GtkAccessible twice to get the same data.
2020-11-19 15:20:56 +00:00
Emmanuele Bassi
d436c2e839
a11y: Remove weak ref from atspi.Cache
...
The GtkAtSpiContext is responsible for removing itself from the root,
which will remove itself from the cache. Any code path that leads to the
GtkAtSpiContext instance being collected passes through the
unrealization phase, which will also unregister the context from the
accessibility bus and from the cache.
2020-11-19 15:20:56 +00:00
Emmanuele Bassi
b37634dcd5
a11y: Add a fallback for the root base path
...
In case g_get_prgname() returns NULL, which seems to be the case for the
GTK tests.
2020-11-19 15:20:56 +00:00
Emmanuele Bassi
2d636fdda0
a11y: Reuse the generated AT-SPI interface name
...
We already have the name available.
2020-11-19 15:20:56 +00:00
Emmanuele Bassi
28095641c5
a11y: Use the appropriate GVariant for cache signals
...
We need to wrap the argument for AddAccessible and RemoveAccessible into
a tuple, as that's what GDBus expects.
2020-11-19 12:14:55 +00:00
Jakub Steiner
d58b06ceeb
Adwaita: revert edge-to-edge menuitems
...
- use the old Industrial style menuitems to make the design feel purposeful
- adjust corners to have compatible border-radii of child elements
- include sidebars and navigation sidebars to look consistent
(plus the assistant sidebar)
Implements https://gitlab.gnome.org/GNOME/gtk/-/issues/3366
2020-11-19 11:16:28 +01:00
Christian Hergert
0d2ea14ac1
types: fix various use of volatile in type registration
...
The use of volatile was incorrect in GLib and has been that way for
a long time. Recently however that has changed, and this makes GTK
follow suit to avoid using volatile in the type registration.
See also: https://gitlab.gnome.org/GNOME/glib/-/merge_requests/1719
Combined with the above merge request for GLib, this fixes a large
number of compilation warnings when using Clang.
2020-11-18 20:21:33 -08:00
Christian Hergert
82b4c34eca
gl: add some debugging information to DEBUG_OPS
2020-11-18 20:16:40 -08:00
Christian Hergert
ee47ddf5fd
lpr: fix cast warning
2020-11-18 20:16:40 -08:00
Christian Hergert
f32ae2964a
macos: fix various compiler warnings
2020-11-18 20:16:37 -08:00
Christian Hergert
eae5eaeb21
gl: use glFramebufferTexture2D to set framebuffer texture
...
When mapping a texture to the framebuffer, we can use the 2D
form instead of the cube mapping form.
2020-11-18 20:09:01 -08:00
Matthias Clasen
09fd2d61c4
gtk-demo: Rename some demos
...
This is just to make it easier for myself to
find the right sources.
2020-11-18 18:58:45 -05:00
Matthias Clasen
86d7ab7c50
docs: Update GtkSensitivityType docs
...
Don't talk about steppers here, since we are only using
this type for combobox buttons nowadays.
2020-11-18 18:18:31 -05:00
Matthias Clasen
88be92ceee
scrollbar: Don't talk about steppers
...
There steppers were lost on the way from GtkRange
to GtkScrollbar, so don't talk about them in the docs.
2020-11-18 17:27:13 -05:00
Matthias Clasen
04c4b387a0
gtk-demo: Add more keywords
...
Add GtkShortcutController as a keyword to some demos that
show its use.
2020-11-18 10:48:57 -05:00
Matthias Clasen
7551f85d4c
Merge branch 'wayland-minimize' into 'master'
...
wayland: Implement minimization
Closes #2688
See merge request GNOME/gtk!2861
2020-11-18 14:23:56 +00:00
Matthias Clasen
184886f893
Merge branch 'constraint-editor-work' into 'master'
...
Constraint editor work
See merge request GNOME/gtk!2863
2020-11-18 12:19:07 +00:00
Matthias Clasen
36ef94b002
constraint-editor: Fix creating constant constraints
...
We were not making the button sensitive in the case
of a constant constraint, and we were not properly
creating constant constraints either.
2020-11-17 23:16:57 -05:00
Matthias Clasen
831ebe3ef2
constraint-editor: Fix saving of constraints
...
g_file_replace_contents take a gsize, so passing -1
for string length does not work here.
2020-11-17 23:14:29 -05:00
Matthias Clasen
76b8676955
constraintlayout: Fix parsing of constant constraints
...
We were inadvertently turning constant constraints into
constraints against super, due to confusion between target
and source attribute.
2020-11-17 23:11:16 -05:00
Matthias Clasen
b3243132a0
Merge branch 'wip/chergert/gdk-macos-for-master' into 'master'
...
macos: fix rendering artifacts with hover transitions
See merge request GNOME/gtk!2862
2020-11-18 03:04:01 +00:00
Matthias Clasen
de461712a1
constraint-editor: Improve display of constraints
...
No need to go for ALGOL60 style operators when we
have Unicode.
2020-11-17 21:52:15 -05:00
Christian Hergert
dd7f52c59a
macos: fix rendering artifacts with hover transitions
...
Using an image surface seems to fix some rendering artifacts when
performing cross-fade CSS transitions.
2020-11-17 18:20:55 -08:00
Matthias Clasen
3f1bc740e4
wayland: Implement minimization
...
Use the set_minimized method of the xdg_toplevel
interface to implement minimization as well as possible.
It is not possible, since there is no corresponding
state that we could use to update our surface state,
but in practice, it works well enough.
Fixes : #2688
2020-11-17 19:57:56 -05:00
Matthias Clasen
9128ad105b
Merge branch 'wip/carlosg/for-master' into 'master'
...
gdk/wayland: Update to gtk_shell1 version 3
See merge request GNOME/gtk!2860
2020-11-18 00:13:17 +00:00
Carlos Garnacho
745cbc6c91
gdk/wayland: Update to gtk_shell1 version 3
...
Bring in line with gtk3, in terms of startup notification and
activation support.
2020-11-18 00:41:46 +01:00
Matthias Clasen
b635736ac2
Merge branch 'wip/chergert/gdk-macos-for-master' into 'master'
...
node-editor: fix length of text during save
See merge request GNOME/gtk!2859
2020-11-17 22:49:05 +00:00
Matthias Clasen
ba081bf119
Merge branch 'fix-doc-packtype' into 'master'
...
doc: Adapt GtkPackType documentation to GTK4 changes
See merge request GNOME/gtk!2858
2020-11-17 22:46:43 +00:00
Christian Hergert
3003f37e9d
node-editor: fix length of text during save
...
The length parameter for g_file_replace_contents() is a gsize, so -1 is
unsuitable here. Just use strlen() directly.
2020-11-17 14:34:11 -08:00
Matthias Clasen
c1e05e7c52
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
Closes #3278
See merge request GNOME/gtk!2856
2020-11-17 19:25:05 +00:00
Matthias Clasen
6b475aacd2
Merge branch 'wip/chergert/gdk-macos-for-master' into 'master'
...
inspector: handle differences in DPI between backends
See merge request GNOME/gtk!2857
2020-11-17 19:24:47 +00:00
vanadiae
bc4969ec42
doc: Adapt GtkPackType documentation to GTK4 changes
...
Since GTK4, the functions that used the GtkPackType enumeration,
`gtk_box_pack_{start,end}`, were replaced by `gtk_box_{append,prepend}`,
hence this enumeration isn't used anymore by any function within the
GtkBox type, and the child packing properties were also removed for GTK4.
So this commit adapts the documentation accordingly.
2020-11-17 20:19:16 +01:00
Benjamin Otte
1c7daece7a
Merge branch 'wip/otte/for-master' into 'master'
...
Wip/otte/for master
See merge request GNOME/gtk!2855
2020-11-17 19:08:01 +00:00
Christian Hergert
37a8c138f9
inspector: handle differences in DPI between backends
...
This fixes an issue on macOS where the text gets much larger once opening
the inspector.
2020-11-17 10:45:25 -08:00
Matthias Clasen
34d547a2aa
inspector: Limit the width of readonly properties
...
For readonly properties, we show the serialized value
in a label. If we don't take precautions, this can cause
our window to grow extremely wide, and break things.
So, ellipsize things at a reasonable size.
Fixes : #3278
2020-11-17 13:36:57 -05:00
Benjamin Otte
163c04c101
snapshot: Add cleanup function to snapshot state
...
Otherwise we're leaking data in error cases.
2020-11-17 19:04:39 +01:00
Benjamin Otte
f2284ff40f
rendernode: Rename all gsk_render_node_peek_*() functions
...
Those are getters, they should be gsk_render_node_get_*() functions.
2020-11-17 19:04:39 +01:00
Benjamin Otte
eded9459df
tests: Fix for new tranfer behavior of constructors
...
We were still unreffing a listmodel where the reference wasn't ours
anymore.
2020-11-17 19:04:39 +01:00
Benjamin Otte
8fd1530848
testsuite: Make defaultvalue test always get the property
...
Make the test not skip properties completely, just skip checking the
property.
This caught the last 2 commits.
2020-11-17 19:04:39 +01:00
Benjamin Otte
77f9efa747
textbuffer: Remove unused properties
...
The getters and setters were removed in
f53848c360 but the pspecs were forgotten.
2020-11-17 19:04:39 +01:00
Benjamin Otte
109ec523cb
shortcut: Actions are objects
2020-11-17 19:04:39 +01:00
Emmanuele Bassi
5cc5022a8f
Merge branch 'wip/chergert/gdk-macos-for-master' into 'master'
...
macos: bring forward quartz search engine updates
See merge request GNOME/gtk!2854
2020-11-17 17:58:14 +00:00
Emmanuele Bassi
3c769bb11d
Merge branch 'ebassi/inout-args' into 'master'
...
Remove pointless inout arguments
See merge request GNOME/gtk!2853
2020-11-17 17:40:13 +00:00
Christian Hergert
33b07e4825
macos: bring forward quartz search engine updates
...
These were not cherry picked after GTK branched for 4 development.
2020-11-17 09:37:13 -08:00
Matthias Clasen
714e5c72f6
docs: Add details about plain builds
...
Mention that build type 'plain' puts the responsibility
for debug features into the hands of the builder.
Related: !2831
2020-11-17 12:21:29 -05:00
Emmanuele Bassi
153c6424d3
Remove pointless inout arguments
...
GtkTreeView.get_tooltip_context() takes an inout X and Y coordinates,
but the "out" side is a side effect: the conversion from widget-relative
to bin window-relative coordinates is not documented, and can be done
using public API, if needed.
GtkIconView.get_tooltip_context() follows the same pattern, and takes
two inout arguments for the coordinates, but it does not change them any
more, after GtkIconView's bin window was dropped in commit 8dc5e13e .
There's really no point in having these `inout` arguments, and while
GtkTreeView and GtkIconView are certainly de-emphasised in GTK4, and we
nudge developers to move to the new list views, we should take advantage
of the API break to remove warts.
2020-11-17 16:38:12 +00:00
Emmanuele Bassi
b76e514322
Merge branch 'ebassi/for-master' into 'master'
...
Introspection fixes
Closes #3281
See merge request GNOME/gtk!2852
2020-11-17 16:04:03 +00:00
Jakub Steiner
1501aa0603
Revert "Adwaita: avoid clipping menu/popover shadow"
...
There are big side effects to adding padding around all menus and popovers.
https://gitlab.gnome.org/GNOME/gtk/-/issues/1987#note_963889
This reverts commit d266bd62de .
2020-11-17 16:53:32 +01:00
Emmanuele Bassi
cf5a173a4f
Add type annotations for GtkShortcutAction types
...
The constructors and singleton getters need proper annotations for their
return type, given that we return a base type.
2020-11-17 14:17:26 +00:00
Matthias Clasen
2b8c3731c1
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
See merge request GNOME/gtk!2851
2020-11-17 14:12:23 +00:00
Emmanuele Bassi
ade2f1030a
Annotate GdkTimeCoord's array field
...
We need to resolve the array length manually, because g-ir-scanner
cannot turn an enumeration member into a constant size.
2020-11-17 14:07:11 +00:00
Emmanuele Bassi
4f12df5f1c
Annotate the return type for GtkTreeExpander.get_item()
...
We use gpointer for C convenience, but the returned value is really a
GObject.
2020-11-17 13:54:22 +00:00
Emmanuele Bassi
9941799449
Annotate out argument for gdk_popup_layout_get_offset()
2020-11-17 13:52:15 +00:00
Emmanuele Bassi
5a938ad83d
Annotate the gsk_border_node_peek_widths() return value
...
We return a fixed sized C array of floats.
2020-11-17 13:48:07 +00:00
Matthias Clasen
835c807d7a
widget-factory: Remove an unused size group
...
This was left behind when 361407201b removed
the unused popover that this size group applied to.
2020-11-17 07:34:53 -05:00
Matthias Clasen
2ef72442ec
docs: Fix the links for keybinding signals
...
GtkBindingSignal does not exist anymore, so link to
GtkSignalAction for an explanation of keybinding signals.
2020-11-17 07:34:52 -05:00
Matthias Clasen
3bc2bf40a8
popover: Document signals
2020-11-17 07:34:52 -05:00
Matthias Clasen
cd4c0b6127
menubutton: Fix a gtk-doc complaint
2020-11-17 07:34:52 -05:00
Matthias Clasen
fa79e8651e
gtk: Fix a doc oversight
2020-11-17 07:34:52 -05:00
Matthias Clasen
9a29487e25
gsk: Fix a doc oversight
2020-11-17 07:34:52 -05:00
Matthias Clasen
fceff93994
Merge branch 'fix-gi-warning' into 'master'
...
Fix a warning caused by difference between prototype and definition
See merge request GNOME/gtk!2849
2020-11-17 12:31:36 +00:00
Matthias Clasen
acd8b08d35
Merge branch 'wip/exalm/caption' into 'master'
...
widget-factory: Fix caption style class name
See merge request GNOME/gtk!2850
2020-11-17 12:22:29 +00:00
Alexander Mikhaylenko
2abee57421
widget-factory: Fix caption style class name
...
It's lowercase.
2020-11-17 13:16:47 +05:00
Qiu Wenbo
437f902c9d
Fix a warning caused by difference between prototype and definition
...
This commit fix the warning:
../gdk/wayland/gdkdisplay-wayland.c:1079: Warning: GdkWayland: gdk_wayland_display_set_cursor_theme: unknown parameter 'name' in documentation comment, should be 'theme'
2020-11-17 14:59:14 +08:00
Matthias Clasen
a7befc647e
Merge branch 'gsk-binding-api' into 'master'
...
gsk: Avoid using gtk css types in public api
Closes #2454
See merge request GNOME/gtk!2848
2020-11-17 05:36:15 +00:00
Matthias Clasen
121e61cf01
gsk: Avoid using gtk css types in public api
...
Using GtkCssSection in public headers here may be
ok from the C perspective, since it all ends up in
the same library anyway. But it causes circular
dependency problems for our gir files that are still
split by namespace.
To avoid this problem, copy the GtkCssLocation struct
struct as GskParseLocation, and pass take two of them
instead of a GtkCssSection in the error callback.
Update all users.
Fixes : #2454
2020-11-16 23:27:44 -05:00
Matthias Clasen
f7ac13b78f
Merge branch 'matthiasc/for-master' into 'master'
...
popover: Fix submenu navigation
Closes #3301
See merge request GNOME/gtk!2847
2020-11-17 03:11:13 +00:00
Matthias Clasen
c2ae73f247
popover: Fix submenu navigation
...
In commit 024d832d94 , we introduced a
cascade-popdown property that makes closing a submenu
propagate up and close its parent menus. This is the
behavior we want when a menuitem in the submen is
activated.
What we overlooked is that we still need to be able to
close a submenu during navigation, before opening another
one. And in this case, propagating the closing is breaking
things. Fix this by adding a private close_submenu api
to GtkPopoverMenu that avoids the propagation.
Fixes : #3301
2020-11-16 21:34:33 -05:00
Benjamin Otte
4b0b6100d6
build: Include GSK types in gtk_test_register_all_type()
2020-11-17 03:13:31 +01:00
Matthias Clasen
2c9bf55eea
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
See merge request GNOME/gtk!2846
2020-11-17 01:07:34 +00:00
Emmanuele Bassi
1d11d42aa0
Merge branch 'ebassi/for-master' into 'master'
...
Ebassi/for master
See merge request GNOME/gtk!2840
2020-11-16 23:06:55 +00:00
Matthias Clasen
361407201b
widget-factory: Remove an unused popover
...
We are no longer using the hand-rolled variant of that
popover on page 3, so drop it from the ui file.
2020-11-16 15:22:12 -05:00
Matthias Clasen
50c29398e6
Merge branch 'wip/exalm/button' into 'master'
...
Allow pressing multiple buttons at once on touch
See merge request GNOME/gtk!2813
2020-11-16 20:16:10 +00:00
Jakub Steiner
dff8a9eb46
Merge branch 'wip/jimmac/popover-menu-submenus' into 'master'
...
Adwaita: fix up submenus again
See merge request GNOME/gtk!2845
2020-11-16 19:50:08 +00:00
Matthias Clasen
1bb4e660fd
Merge branch 'wip/chergert/for-master' into 'master'
...
gsk: use glFrameBufferTexture2D and release texture
See merge request GNOME/gtk!2842
2020-11-16 19:20:19 +00:00
Jakub Steiner
ded6ec6424
Merge branch 'wip/jimmac/circular-button-focus' into 'master'
...
Adwaita: circular button focus
Closes #3368
See merge request GNOME/gtk!2844
2020-11-16 18:55:30 +00:00
Jakub Steiner
47e49acc7d
Adwaita: fix up submenus again
...
- move menubar section under more generic popover.menu
rather than resort to specificity dir(ltr) hacks
2020-11-16 19:48:11 +01:00
Jakub Steiner
0996b178dc
Adwaita: circular button focus
...
- have the same focus look like the other items
Fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/3368
2020-11-16 19:11:52 +01:00
Matthias Clasen
4befd13744
Merge branch 'wip/jimmac/spinbutton-spacing' into 'master'
...
Adwaita: spinbutton spacing
Closes #3370
See merge request GNOME/gtk!2841
2020-11-16 17:50:56 +00:00
Emmanuele Bassi
bb1463871c
a11y: Ensure valid object paths in the fallback code
...
When falling back to using the program name to create a unique base path
for the objects on the accessibility bus we need to ensure that the name
is a valid DBus object path.
2020-11-16 17:47:15 +00:00
Christian Hergert
12a9164414
gsk: use glFrameBufferTexture2D and release texture
...
glFrameBufferTexture maps to all faces of a cube and that is not needed
here. Additionally, texture_id is not deleted after we use the additional
flipped texture, but should be.
2020-11-16 09:26:07 -08:00
Jakub Steiner
108fe033aa
Adwaita: spinbutton spacing
...
Fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/3370
2020-11-16 18:22:17 +01:00
Emmanuele Bassi
9de2b4b0e1
a11y: Implement atspi.Cache
...
The AT-SPI cache interface is used to quickly populate the accessible
objects tree.
The tricky bit is ensuring that we emit change notifications on the
cache only when the cache is available, which means waiting until the
root is asynchronously registered.
2020-11-16 16:44:56 +00:00
Emmanuele Bassi
ee056fd8bd
a11y: Update the Cache interface introspection
...
The type for cached items is, unsurprisingly, wrong when compared to the
implementation inside atk-spi2-atk.
2020-11-16 16:44:56 +00:00
Emmanuele Bassi
bc4f71a107
a11y: Add getters for GtkAtSpiContext
...
We are going to use them in order to implement atspi.Cache.
2020-11-16 16:44:56 +00:00
Emmanuele Bassi
125442297f
a11y: Use the tab widget to label the notebook stack page
2020-11-16 16:44:56 +00:00
Emmanuele Bassi
eec92b40ea
a11y: Compute the base path in the root object
...
The root path is shared by all AtSpiContext instances, so we should
compute it once, instead of every time we instantiate a new context.
This allows us to defer the path creation at realization time and ensure
that we have a registered application.
2020-11-16 16:44:56 +00:00
Emmanuele Bassi
d392f6f2a4
a11y: Resync the AT-SPI XML
...
Mostly just changes in the annotations coming from at-spi2-core, but
it's good to try and keep the XML in sync.
2020-11-16 16:44:56 +00:00
Jakub Steiner
41a9c46ec8
Merge branch 'wip/jimmac/circular-button-padding' into 'master'
...
Adwaita: circular buttons
See merge request GNOME/gtk!2838
2020-11-16 14:50:16 +00:00
Matthias Clasen
0530aeec17
docs: Mention cairo-gobject as build requires
...
Using cairo from a system dependency and cairo-gobject
as subproject is problematic and left me stuck on a
hard-to-understand build error.
2020-11-16 09:31:23 -05:00
Jakub Steiner
22741a74ff
Adwaita: circular buttons
...
- the vertical padding was thown off with the chin/forehead of menus removed
2020-11-16 15:21:46 +01:00
Jakub Steiner
23331c1919
Merge branch 'wip/jimmac/menu-clipped-shadow' into 'master'
...
Wip/jimmac/menu clipped shadow
Closes #1987
See merge request GNOME/gtk!2837
2020-11-16 14:10:21 +00:00
Jakub Steiner
d266bd62de
Adwaita: avoid clipping menu/popover shadow
...
Fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/1987
2020-11-16 14:20:24 +01:00
Matthias Clasen
57c95937b1
gsk: Fix some docs oversights
...
These apis have been renamed a few times, and the docs
haven't kept up.
2020-11-16 07:44:41 -05:00
Matthias Clasen
1d86086434
gdk: Docs cosmetics
...
Add a few missing parameters in doc comments.
2020-11-16 07:44:17 -05:00
Matthias Clasen
e2f26b0d9a
docs: Fix a typo
2020-11-16 07:37:33 -05:00
Matthias Clasen
7816fc2b83
docs: Remove gtk_render_insertion_cursor
...
This function was removed in 2bcef7f030 .
2020-11-16 07:35:41 -05:00
Jakub Steiner
04d802f7f4
Adwaita: remove chin on menus
...
- clipping a rounded corner seems to be working fine for first and last item.
Addresses https://gitlab.gnome.org/GNOME/gtk/-/issues/3366
2020-11-16 13:31:27 +01:00
Jakub Steiner
994cc32d7b
Merge branch 'wip/jimmac/subtle-sidebar' into 'master'
...
Adwaita: navigation sidebar color changes
Closes #3362
See merge request GNOME/gtk!2836
2020-11-16 09:34:36 +00:00
Jakub Steiner
f14ca28c4e
Adwaita: navigation sidebar color changes
...
- use more subtle selected state grey
Fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/3362
2020-11-16 10:17:57 +01:00
Matthias Clasen
da9d32e472
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
See merge request GNOME/gtk!2835
2020-11-16 04:29:10 +00:00
Matthias Clasen
08d6db4ab6
gtk-demo: Plug a memory leak
...
The Characters demo was leaking its columns.
2020-11-15 23:03:30 -05:00
Matthias Clasen
6891f40110
modelbutton: Fix keynav for check and radio
...
The expected behavior when activating check or radio
menuitems via keynav is that Space toggles the item
but keeps the menu open, while Return toggles the
item and closes the menu.
2020-11-15 21:52:07 -05:00
Matthias Clasen
cdbf24c3af
Merge branch 'fix-tooltip-trigger' into 'master'
...
Fix tooltip triggering
See merge request GNOME/gtk!2833
2020-11-15 17:37:47 +00:00
Matthias Clasen
b30715da6a
Fix tooltip triggering
...
Ever since 5b5d2665d3 , tooltips don't work properly,
since we get more motion events now, and those keep the
tooltips from appearing. This can be seen e.g. on the icon
in the password entry in widget-factory, or on the section
switcher buttons in the Emoji chooser.
Ignore synthetic motion events for the purposes of
determining whether the user moved the mouse.
2020-11-15 10:54:36 -05:00
Emmanuele Bassi
5e9883453d
Merge branch 'widget-no-a11y-crash' into 'master'
...
gtkwidget: fix crashes with GTK_A11Y=none
Closes #3333
See merge request GNOME/gtk!2834
2020-11-15 15:23:42 +00:00
Christoph Reiter
b97b95b0c7
gtkwidget: fix crashes with GTK_A11Y=none
...
at_context can be NULL in that case, so guard against it.
Fixes #3333
2020-11-15 15:59:31 +01:00
Matthias Clasen
dd0a854bbb
Merge branch 'button-fill-var-removal' into 'master'
...
Adwaita: Stop using $button_fill
Closes #3354
See merge request GNOME/gtk!2828
2020-11-15 13:45:42 +00:00
Matthias Clasen
b8d0ad8643
Merge branch 'parse-debug-env-vars-always' into 'master'
...
Always parse GTK/GDK/GSK_DEBUG env vars and make some entries available in non-debug mode
See merge request GNOME/gtk!2830
2020-11-15 13:37:44 +00:00
Christoph Reiter
65d57877a8
Revert "Update comment annotations of gtk_tree_model_iter_previous and gtk_tree_model_iter_next to state that the ITER parameter is modified."
...
This reverts commit 1340ff2bc2 .
Same as with 53cd499621
2020-11-15 13:36:42 +01:00
Christoph Reiter
afc73c38ce
Always parse GTK/GDK/GSK_DEBUG env vars and make some entries available in non-debug mode
...
Currently GTK can be built with G_ENABLE_DEBUG which enables various debug code and parsing
of those env vars, or without, which instead of parsing them prints a warning if they are set.
While building with G_ENABLE_DEBUG isn't strictly needed it's the only way to make GTK_DEBUG=interactive work,
which is a nice thing to have always.
This enables parsing of those env vars in any case and allows specific values being marked as also
available when not built with G_ENABLE_DEBUG (interactive for example). If not built with G_ENABLE_DEBUG
then all unavailable values will be marked as such in the help output and a note is added that
GTK needs to be built with G_ENABLE_DEBUG to use them, which should help discoverability.
2020-11-15 11:34:54 +01:00
Yuri Chornoivan
f4e1c271ea
Update Ukrainian translation
2020-11-15 08:01:26 +00:00
Matthias Clasen
8e42239439
Merge branch 'wip/carlosg/for-master' into 'master'
...
gtk/main: Reset active state on grab broken only if implicit
See merge request GNOME/gtk!2832
2020-11-14 14:41:01 +00:00
Carlos Garnacho
5b4ac5456e
gtk/main: Reset active state on grab broken only if implicit
...
An implicit grab means some button is down, reset the active state
only in that case when we get a grab broken event.
Avoids active state accounting warnings when we do get active grabs
broken (e.g. after selecting a menu option).
2020-11-14 10:52:34 +01:00
nana-4
f1db73379e
Adwaita: Stop using $button_fill
...
Since the $button_fill variables are no longer used outside of the
button() mixin (and it was for an ugly hack), there is no need to keep
that anymore.
Fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/3354
2020-11-14 10:13:05 +09:00
Matthias Clasen
20918dbe8e
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
Closes #3359 and #3353
See merge request GNOME/gtk!2827
2020-11-14 00:15:34 +00:00
Matthias Clasen
b5ec20db88
Adwaita: Fix list separators
...
Commit bfe5b0d1b7 ran into some specificity
trouble.
Fixes : #3353
2020-11-13 17:18:05 -05:00
Matthias Clasen
d347df431d
label: Avoid short-circuiting
...
Commit 0db504edde made a mistake described here:
https://en.wikipedia.org/wiki/Short-circuit_evaluation#Possible_problems
Fixes : #3359
2020-11-13 15:35:51 -05:00
Matthias Clasen
25e6988d95
Merge branch 'alatiera/nightly-demos' into 'master'
...
ci: publish demo apps to the Nightly repository
See merge request GNOME/gtk!2825
2020-11-13 19:28:44 +00:00
Matthias Clasen
a7f05b8d91
Merge branch 'wip/jimmac/tooltips' into 'master'
...
Adwaita: tooltip styling
Closes #3352
See merge request GNOME/gtk!2826
2020-11-13 19:23:58 +00:00
Jordan Petridis
fe690265eb
ci: publish demo apps to the Nightly repository
2020-11-13 20:38:09 +02:00
Jakub Steiner
f45ea3fa90
Adwaita: tooltip styling
...
- balance padding
- increase border radius, yuck
- get rid of text shadow
Fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/3352
2020-11-13 19:36:26 +01:00
Jakub Steiner
bdc28cd870
Merge branch 'wip/jimmac/submenus' into 'master'
...
Wip/jimmac/submenus
See merge request GNOME/gtk!2824
2020-11-13 17:05:00 +00:00
Jakub Steiner
c648c1f235
Merge branch 'wip/jimmac/declare-buttonfill-once' into 'master'
...
Adwaita: double declated $button_fill
See merge request GNOME/gtk!2823
2020-11-13 16:57:18 +00:00
Jakub Steiner
8a92ee03ea
Adwaita: rounded submenus
...
- all corners have rounded corners
See https://gitlab.gnome.org/GNOME/gtk/-/issues/2745
2020-11-13 17:27:40 +01:00
Jakub Steiner
e3c72f8f09
Adwaita: double declared $button_fill
...
- this was already in place in _common, no need to have it in _colors
2020-11-13 17:24:13 +01:00
Jakub Steiner
1f472104ad
Adwaita: double declated $button_fill
...
- this was already in place in _common, no need to have it in _colors
2020-11-13 17:21:03 +01:00
Jakub Steiner
4b41580041
Merge branch 'wip/exalm/window' into 'master'
...
Round window corners
See merge request GNOME/gtk!1952
2020-11-13 15:33:15 +00:00
Matthias Clasen
c136f84584
Merge branch 'wip/carlosg/for-master' into 'master'
...
Improve handling of ::active with touch and multiple foci
Closes #3348
See merge request GNOME/gtk!2821
2020-11-13 04:13:34 +00:00
Carlos Garnacho
80de00a248
gtk/main: Stack ::active calls
...
We may have the situation of multiple touchpoints in the same
widget, or combinations with other devices. Stack those ::active
states are preserved on widgets on all but the last pointer/touch
going away.
2020-11-13 00:39:23 +01:00
Carlos Garnacho
50a7e59623
gtk/main: Toggle active flag with touch events
...
This went missing at some point, add the missing toggling of active
state with GDK_TOUCH_BEGIN/END/CANCEL events.
Fixes: https://gitlab.gnome.org/GNOME/gtk/-/issues/3348
2020-11-13 00:39:23 +01:00
Emmanuele Bassi
92ca3a3419
Merge branch 'ebassi/for-master' into 'master'
...
Ebassi/for master
See merge request GNOME/gtk!2819
2020-11-12 22:22:20 +00:00
Emmanuele Bassi
8203d9cc40
a11y: Use GROUP role for ShortcutsShortcut
...
And hide the image from the accessible tree.
2020-11-12 21:46:06 +00:00
Emmanuele Bassi
abc9b403f8
a11y: Implement atspi.Text.ScrollSubstringTo for GtkTextView
...
We reuse the existing implementation in GTK3.
2020-11-12 21:46:06 +00:00
Emmanuele Bassi
b9ad3172a4
a11y: Document GtkRevealer's accessible state
...
Use the GROUP role, and make sure to note that the child is always
revealed. Unlike GtkExpander, GtkRevealer can only be programmatically
toggled, so we cannot turn it into a "button" object.
2020-11-12 21:46:06 +00:00
Emmanuele Bassi
0d7fcdda28
a11y: Add more accessible data to GtkTreeExpander
...
Document the role of the GtkTreeExpander, and the behaviour of the
expander button.
Additionally, improve the label of the expander button, by adding a
fixed "Expand" label, and setting the "labelled-by" relation to the
child of the GtkTreeExpander.
2020-11-12 21:46:06 +00:00
Emmanuele Bassi
75f9b83b1e
Establish a control relation between demo search and list
...
The search entry changes the content of the list view, so we should
mention that relation to assistive technologies.
2020-11-12 21:46:06 +00:00
Emmanuele Bassi
61e980bfb6
a11y: Add accessible actions to GtkSearchEntry
...
Just like GtkPasswordEntry, GtkSearchEntry should have its set of
accessible actions.
2020-11-12 21:46:06 +00:00
Emmanuele Bassi
ebda736a09
a11y: Mark SearchEntry icons as presentational
...
While the "clear the search entry" icon behaves like a button, we don't
have any actual action that can trigger it, so let's ignore it.
2020-11-12 21:46:06 +00:00
Emmanuele Bassi
d4ddfdc265
a11y: Set the role on GtkSearchBar
...
The search bar widget has a "SEARCH" landmark role, which is described
as:
A landmark region that contains a collection of items and
objects that, as a whole, combine to create a search facility.
2020-11-12 21:46:06 +00:00
Emmanuele Bassi
f8bb206034
a11y: Icons in buttons are presentational
...
Buttons are described by text, and the icon child can be safely ignored.
2020-11-12 21:46:06 +00:00
Emmanuele Bassi
87f92a93d3
a11y: Add more accessibility labels to GtkNotebook
...
Label the various components:
- the tab list
- the tab widget
- the arrow widgets
2020-11-12 21:46:06 +00:00
Emmanuele Bassi
e49e084f4c
a11y: Use the stack page title as its accessible label
2020-11-12 21:46:06 +00:00
Emmanuele Bassi
995daa1e29
a11y: GtkStack is a group of stack pages
2020-11-12 21:46:06 +00:00
Emmanuele Bassi
d34936c1ea
Handle empty stack pages when creating an ATContext
...
If we don't have a widget inside GtkStackPage, we should use the default
GdkDisplay.
2020-11-12 21:46:06 +00:00
Emmanuele Bassi
a59889a274
Unrealize the ATContext in StackPage on dispose
...
Otherwise we're going to try to unrealize it during the GtkStack
destruction, which will emit warnings.
2020-11-12 21:46:05 +00:00
Emmanuele Bassi
bfb054a023
a11y: Icons in WindowControls are presentational only
...
They don't contribute anything to the accessible description.
2020-11-12 21:46:05 +00:00
Emmanuele Bassi
e940704018
a11y: Ignore more structural roles when computing labels
...
These roles should not have a fallback name when explicitly unlabelled.
2020-11-12 21:46:05 +00:00
Emmanuele Bassi
429c7fc039
a11y: Add role exception for GtkScrolledWindow
...
ARIA does not have a "scroll pane" role, but AT-SPI does.
2020-11-12 21:46:05 +00:00
Emmanuele Bassi
0d6e4f7a6e
demo: Add more accessibility labels to the UI
2020-11-12 21:46:05 +00:00
Matthias Clasen
1f9eb5c64c
Merge branch 'clear-search-entry' into 'master'
...
searchbar: Fix clearing search entry on hide
See merge request GNOME/gtk!2820
2020-11-12 19:25:57 +00:00
Florian Müllner
056a073061
searchbar: Fix clearing search entry on hide
...
Commit fa3d1940bf added separate grab handling for GtkSearchEntry, but
didn't consider whether the bar was revealed or concealed. The expected
behavior for the latter is that the entry is cleared rather than focused,
fix the condition accordingly.
2020-11-12 19:59:55 +01:00
Alexander Mikhaylenko
e46522e4b5
theme: Round all window corners
2020-11-12 22:19:00 +05:00
Alexander Mikhaylenko
7ac7919697
theme: Restructure window style
2020-11-12 22:17:52 +05:00
Matthias Clasen
5d9799d4e3
Merge branch 'ebassi/for-master' into 'master'
...
ATContext lifetime fixes
Closes #3341
See merge request GNOME/gtk!2811
2020-11-12 12:35:23 +00:00
Jakub Steiner
f95943a752
Merge branch 'wip/jimmac/sassc-global-vars' into 'master'
...
Adwaita: avoid !global
See merge request GNOME/gtk!2816
2020-11-12 12:34:10 +00:00
Jakub Steiner
ef88e9ffcc
Adwaita: avoid !global
...
- Work around having !global variables as sassc will
no longer support it
2020-11-12 13:14:37 +01:00
Alexander Mikhaylenko
49613dca8e
button: Don't make the gesture exclusive
...
With the last commit, pressing the same button with multiple fingers
doesn't cause extra emissions, so we can remove exclusive and allow
pressing multiple buttons at once on touch.
2020-11-12 15:27:16 +05:00
Alexander Mikhaylenko
a651a0ce69
gestureclick: Only emit release for the same sequence
...
Avoid spurious releases when touching the same widget with another finger.
2020-11-12 15:26:36 +05:00
Emmanuele Bassi
08d59d3f68
docs: Add "Accessibility" section to various widgets
...
There are a few widgets that gained an accessible role, which means
adding an "Accessibility" section in their description.
2020-11-12 00:36:32 +00:00
Matthias Clasen
afff39c503
Merge branch 'suggestion-entry-demo2' into 'master'
...
gtk-demo: Add suggestion entry demos
See merge request GNOME/gtk!2812
2020-11-11 21:40:07 +00:00
Matthias Clasen
a2897e1868
gtk-demo: Add suggestion entry demos
...
Add a possible replacement for GtkEntryCompletion
as a demo.
Move the Dropdowns demo to Lists/Selections, and make
it show both GtkDropDown and the suggestion entry, with
some variations.
2020-11-11 15:54:43 -05:00
Matthias Clasen
15172ebdb0
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
See merge request GNOME/gtk!2810
2020-11-11 20:49:51 +00:00
Emmanuele Bassi
9ac4a7d99f
a11y: Simplify GtkModelButton
...
Instead of recreating GtkATContexts in order to change their role, we
can simply unrealize and realize them back.
2020-11-11 19:45:43 +00:00
Emmanuele Bassi
8157717e03
a11y: Add missing fallback for accessible-role getter
...
If the per-instance accessible role is unset, use the class role.
2020-11-11 19:45:43 +00:00
Emmanuele Bassi
9052f6dafe
a11y: Rework ownership and lifetime of GtkATContext
...
Now that GtkATContext is explicitly realized and unrealized, we should
always create an instance at widget initialization time, and drop it
during the widget finalization. This should make it easier to set up the
initial accessible state of a widget during the instance initialization,
as well as reduce the chances of accidental creation of GtkATContext
instances during the destruction sequence.
2020-11-11 19:45:43 +00:00
Emmanuele Bassi
292576f312
a11y: Defer to the GtkAccessible's implementation
...
Since GtkATContexts are now lazily realized, we need to go through the
GtkAccessible's implementation to access the :accessible-role property,
in case there are fallbacks.
2020-11-11 19:45:43 +00:00
Emmanuele Bassi
2285382074
a11y: Create AtSpiRoot on realization
...
There's no need to do a lot of work on construction, if we're delaying
all remote work after the GtkATContext is realized.
The GtkAtSpiContext should also keep a reference on the root, and drop
it at unrealize time.
2020-11-11 18:46:44 +00:00
Emmanuele Bassi
526f1e315b
a11y: Use GROUP role for GtkNotebook
...
A notebook is a grouping of a tab list, tabs, and tab pages.
2020-11-11 18:46:11 +00:00
Emmanuele Bassi
877a7f98ca
a11y: Protect should_present() from empty contexts
...
If the GtkAccessible implementation returns a NULL context, we should
not be calling methods on it.
2020-11-11 18:33:15 +00:00
Emmanuele Bassi
73b14a3c3a
a11y: Do not leak the ATContext in GtkStackPage
...
GtkStackPage is not a widget, so it must release the reference on the
ATContext it owns.
2020-11-11 18:33:15 +00:00
Emmanuele Bassi
40c0826921
a11y: Mark more containers as structural elements
...
Widgets that just provide grouping and layout to other widgets should
not be relevant to the accessible tree.
2020-11-11 18:33:15 +00:00
Emmanuele Bassi
27b9b2e76c
a11y: Use the window title as its label
2020-11-11 18:33:15 +00:00
Emmanuele Bassi
04c4d293a7
a11y: Skip unlabelled structural roles
...
If a structural role is left unlabelled, just leave it unnamed.
2020-11-11 18:33:15 +00:00
Emmanuele Bassi
033791b374
a11y: Translate ARIA windows to AT-SPI frames
...
For backward compatibility with GTK3.
2020-11-11 18:33:15 +00:00
Emmanuele Bassi
95ee5ff424
a11y: Add more ARIA/AT-SPI role translations
2020-11-11 18:33:15 +00:00
Emmanuele Bassi
65d29e00c7
a11y: Realize parent ATContext for the stack page
...
Just like for popovers, the stack page is not directly connected on the
widget's DOM, so we need to realize the parent ATContext ourselves.
2020-11-11 18:33:15 +00:00
Emmanuele Bassi
3b2cd972d5
a11y: Implement missing atspi.Component getters
...
Some of them are entirely innocuous, and we can easily provide values
that match what GTK3 provides.
2020-11-11 18:33:15 +00:00
Emmanuele Bassi
428ec29598
a11y: Unrealize ATContext on dispose()
...
By unrealizing the context we avoid additional work during the dispose
phase, in case widget code updates the accessible state. We use
GtkAccessible's API, to ensure we unrealize the right ATContext, instead
of the one we store inside GtkWidgetPrivate.
We drop the ATContext instance inside GtkWidget during finalization, to
mop up eventual vivifications there.
2020-11-11 18:33:15 +00:00
Matthias Clasen
bfe5b0d1b7
Adwaita: Don't do n-th child things for list rows
...
Making the list row child css depend on the position
is very expensive, and does not acutally work correctly
(since we don't have widgets for all children, so the
position of the child widget does not reflect the actual
model item position).
To make this more palatable, use the bottom border
instead of the top border, since most lists have a natural
border at the top (with headers), and may end up with
empty space at the bottom.
2020-11-11 13:18:08 -05:00
Matthias Clasen
82b855cc4b
label: Avoid a needless strdup
...
Don't duplicate the string before we know if it
has actually changed.
2020-11-11 12:24:35 -05:00
Matthias Clasen
0db504edde
label: Optimize GtkLabel setters
...
The overarching goal here is to not queue a resize
unless something has actually changed. In columnview
scenarios, we often deal with hundreds of labels.
Labels are cattle, not pets.
2020-11-11 11:48:27 -05:00
Matthias Clasen
5ed3ad6cc8
gtk-demo: Split off SvgPaintable
...
Put the SvgPaintable implementation into its
own source files, for ease of copying.
2020-11-11 10:35:54 -05:00
Matthias Clasen
27c4c19333
Don't hide widgets in dispose()
...
This is leftover code from when widgets were hidden
by default, and was setting them back to their initial
state.
This is getting in the way now, as hiding the widget
updates the HIDDEN accessible state, which ends up
re-creating the at context that we've already disposed
of, leading to memory leaks.
2020-11-11 10:35:54 -05:00
Luca Bacci
aec87a3514
GdkWin32: Fix mouse events in presence of transparent windows on the desktop
...
In gdkdevice-win32.c we are interested in knowing which window
receives mouse input at a specific location.
Only WindowFromPoint is the right API for the task, other API's
(such as (Real)ChildWindowFromPoint(Ex)) have shortcomings because
they are really designed for other purposes. For example, only
WindowFromPoint is able to look through transparent layered windows.
So even if we want to find a direct child we have to use
WindowFromPoint and then walk up the hierarchy.
Fixes : #370 , #417
See: !2800
2020-11-11 12:46:52 +01:00
Matthias Clasen
74a7f73239
Merge branch 'matthiasc/builder-requires' into 'master'
...
Matthiasc/builder requires
See merge request GNOME/gtk!2806
2020-11-11 03:53:52 +00:00
Matthias Clasen
a047b7d6d1
Merge branch 'fix-demos-wo-pangoft2' into 'master'
...
gtk-demo: Fix building scrolling demo without PangoFT2
See merge request GNOME/gtk!2807
2020-11-11 03:50:46 +00:00
Chun-wei Fan
a76f37a501
gtk-demo: Fix building scrolling demo without PangoFT2
...
For builds that do not have PangoFT2, the demo fails to link because we weren't
building listview_ucd.c. Fix the build by building listview_ucd.c with
script-names.c and unicode-names.c for all builds, as we now require a Pango
version that already always depends on HarfBuzz and those sources do not use
anything from PangoFT2.
2020-11-11 11:15:05 +08:00
Matthias Clasen
d6a0948182
testsuite: Update buildertool tests
...
gtk-builder-tool simplify --3to4 now produces a
<requires lib="gtk" version="4.0"/>.
Adapt for that, and also add some tests that check that we
actually verify the requires, and accept 3.99 and 4.0, but
not 5.x.
2020-11-10 19:20:51 -05:00
Matthias Clasen
7215c74933
buildertool: Supplant a requires
...
When we convert a ui file to GTK 4 syntax, we *know*
that it requires GTK 4, so put that in the output.
2020-11-10 19:19:40 -05:00
Matthias Clasen
e4be785c6c
builder: Be a bit more strict about requires
...
Check that the major version matches (without this, the
requires check is really toothless), but allow 3.99 to
match 4.0.
2020-11-10 19:18:26 -05:00
Matthias Clasen
18779b9d67
testsuite: Remove <requires> from ui files
...
We don't need these here, the testsuite is shipped
with GTK.
2020-11-10 19:17:45 -05:00
Matthias Clasen
9b056f57f7
examples: Remove requires from ui files
...
No need to check requires for things that are shipped
with GTK.
2020-11-10 18:38:54 -05:00
Matthias Clasen
d6c753bde7
gtk4-demo: Remove <requires> from ui files
...
No need to check requires for things that are shipped
with GTK.
2020-11-10 18:37:40 -05:00
Matthias Clasen
d69a943661
gtk: Remove <requires> from ui files
...
We don't need to check requirements for things
that are shipped *with* gtk.
2020-11-10 18:36:03 -05:00
Matthias Clasen
0ececc7109
Merge branch 'ebassi/for-master' into 'master'
...
Ebassi/for master
Closes #3343 and #3342
See merge request GNOME/gtk!2804
2020-11-10 18:33:36 +00:00
Matthias Clasen
3cc0870084
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
See merge request GNOME/gtk!2805
2020-11-10 16:59:47 +00:00
Emmanuele Bassi
2229d7f66c
docs: Add example of relations with lists of references
2020-11-10 14:38:09 +00:00
Emmanuele Bassi
ed7619ec16
a11y: Clone GtkATContext in GtkModelButton
...
The hypothetical widget that needs to clone ATContext instances
because it needs to control the accessible role post-construction is
really GtkModelButton.
Fixes : #3342
2020-11-10 14:31:57 +00:00
Emmanuele Bassi
7ed06480cf
a11y: Add private API to clone a GtkATContext
...
Some widgets might want to override GtkAccessible and create their own
context in order to control the accessible role post-construction time.
To avoid explicitly copying the existing state over from the original
ATContext to the new one, we need a way to clone the context's state
from inside the ATContext itself.
2020-11-10 14:31:56 +00:00
Emmanuele Bassi
f9db651f32
a11y: Do not copy the list of references
...
The constructor for GtkReferenceListAccessibleValue is transfer full,
which means we should not be copying the GList around.
Fixes : #3343
2020-11-10 14:31:56 +00:00
Emmanuele Bassi
c264254d4b
a11y: Parse reference lists using varargs
...
Using GList is a bit lame, and makes the API more complicated to use
than necessary in the common case.
The only real use case for a GList is gtk_widget_add_mnemonic_label(),
and for that we can use the GValue-based API instead.
Fixes : #3343
2020-11-10 14:31:56 +00:00
Emmanuele Bassi
6af89e9034
a11y: Add GValue initializers for accessible attributes
...
Consumers of the GValue-based API for GtkAccessible need to have a way
to initialize the GValue with the correct type for the given attribute.
2020-11-10 14:31:56 +00:00
Emmanuele Bassi
1bdc8b9061
a11y: Proxy GtkWidget:accessible-role
...
The accessible-role property in GtkWidget has three possible targets:
- the :accessible-role of a GtkATContext, if realized
- the accessible_role field of GtkWidgetPrivate
- the accessible_role field of GtkWidgetClassPrivate
When we set the accessible role of a widget using the GObject property
mechanism, we want to either set the GtkWidgetPrivate.accessible_role
field, if there's no ATContext *or* if the ATContext is not realized.
Conversely, when we get the accessible-role property we want to have a
series of fallbacks in place:
- if GtkAccessible.get_at_context() returns an ATContext, and that
ATContext is realized, return the :accessible-role of the context
- if GtkWidgetPrivate.accessible_role is not WIDGET, return the
stored accessible role
- return GtkWidgetClassPrivate.accessible_role
This should help catch the case of getting the accessible role of
widgets that override GtkAccessible.get_at_context(), like
GtkModelButton.
See: #3342
2020-11-10 14:31:56 +00:00
Matthias Clasen
c442f9f05a
printdialog: Plug listmodel memory leaks
...
We were leaking references returned from g_list_model_get_item
in some places.
2020-11-10 09:07:54 -05:00
Matthias Clasen
6cbd7e29dd
fontchooser: Plug listmodel memory leaks
...
We were leaking references returned from g_list_model_get_item
in some places.
2020-11-10 09:07:40 -05:00
Matthias Clasen
6079033cde
columnview: Plug listmodel memory leaks
...
We were leaking references returned from g_list_model_get_item
in some places.
2020-11-10 09:07:22 -05:00
Matthias Clasen
d63afaf5ad
x11: Plug listmodel memory leaks
...
We were leaking references returned from g_list_model_get_item
in some places.
2020-11-10 09:07:01 -05:00
Matthias Clasen
7e089664fc
win32: Plug listmodel memory leaks
...
We were leaking references returned from g_list_model_get_item
in some places.
2020-11-10 09:06:37 -05:00
Matthias Clasen
06fbad0b26
wayland: Plug listmodel memory leaks
...
We were leaking references returned from g_list_model_get_item
in some places.
2020-11-10 09:05:55 -05:00
Yuri Chornoivan
2a3c3b4c6a
Update Ukrainian translation
2020-11-10 08:15:59 +00:00
Yuri Chornoivan
eb3933cffd
Update Ukrainian translation
2020-11-10 07:58:38 +00:00
Matthias Clasen
d1de9234c5
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
See merge request GNOME/gtk!2803
2020-11-10 04:47:28 +00:00
Matthias Clasen
3e8260d528
gtk-demo: Plug a memory leak
2020-11-09 23:29:03 -05:00
Matthias Clasen
192f515682
gtk-demo: Tweak a demo title
2020-11-09 23:28:45 -05:00
Matthias Clasen
2543c9f5a3
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
See merge request GNOME/gtk!2802
2020-11-10 01:42:30 +00:00
Matthias Clasen
a745dbfc15
gkt-demo: Add a columview to the scroll demo
...
This is an interesting case, since it has many labels,
and we are struggling to provide good scrolling performance.
2020-11-09 20:07:09 -05:00
Matthias Clasen
14be50839e
gtk-demo: Improve consistency
...
Make the shortcut triggers demo big enough
to not ellipsize the window title.
2020-11-09 19:54:17 -05:00
Matthias Clasen
a85d9cda07
gtk-demo: Improve consistency
...
Make the paintable svg demo follow the same
pattern we use for other demos.
2020-11-09 19:53:44 -05:00
Matthias Clasen
7d49f1e250
gtk-demo: Improve consistency
...
Make the paintable emblems demo follow the same
pattern we use for other demos.
2020-11-09 19:52:28 -05:00
Matthias Clasen
6fa2936956
gtk-demo: Set default size for drawingarea demo
...
Set a default size, so we don't ellipsize the window
title when the window is presented.
2020-11-09 18:50:43 -05:00
Matthias Clasen
b81463e7d3
gtk-demo: Plug a memory leak
2020-11-09 18:48:10 -05:00
Matthias Clasen
b622745501
gtk-demo: Plug a memory leak
2020-11-09 18:48:10 -05:00
Matthias Clasen
5379a4bf34
a11y: Clean up properly in unregister_object
...
Things that are set up in register_object should
be cleaned up in unregister_object.
2020-11-09 18:48:10 -05:00
Matthias Clasen
b966f593a5
Merge branch 'wip/jimmac/search-entry-icon' into 'master'
...
search entry: icon
Closes #3340
See merge request GNOME/gtk!2801
2020-11-09 22:41:41 +00:00
Jakub Steiner
706a8f9784
search entry: icon
...
Fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/3340
2020-11-09 22:55:21 +01:00
Matthias Clasen
2dc7e327ad
Merge branch 'ebassi/for-master' into 'master'
...
docs: Add missing a11y environment variables
See merge request GNOME/gtk!2788
2020-11-09 17:19:12 +00:00
Matthias Clasen
7b151c3ef0
Merge branch 'kinetic-scroll-velocity-accumulation' into 'master'
...
scrolledwindow: Accumulate velocity with kinetic scrolling
See merge request GNOME/gtk!2768
2020-11-09 17:14:03 +00:00
Emmanuele Bassi
0af6630521
a11y: Consolidate accessibility environment variables
...
Use a single environment variable for everything:
- select the ATContext implementation
- select the test ATContext
- disable ATContext entirely
We use the same pattern as GSK_RENDERER, GTK_DEBUG, etc.
The documentation needs to be updated to include the environment
variable.
2020-11-09 16:21:49 +00:00
Chris Lord
4b459a99be
scrolledwindow: Accumulate velocity with kinetic scrolling
...
Accumulate existing velocity when decelerating from a swipe if the swipe
velocity is above a certain fraction of that existing velocity.
2020-11-09 15:28:32 +00:00
Matthias Clasen
e093ed7d67
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
Closes #3337
See merge request GNOME/gtk!2799
2020-11-09 14:21:26 +00:00
Matthias Clasen
ddbea8feda
Remove GtkPlacesOpenFlags from public headers
...
The GtkPlacesOpenFlags enum is only used in private
API, so move it to private headers. Since we still need
a GType for it, add gtkplacessidebarprivate.h to the
headers we use for generating private enum types. In turn,
this registers the other private enums in that header, so
take the opportunity to fix their naming, and use the
generated types for the corresponding sidebarrow properties.
Fixes : #3337
2020-11-09 08:45:36 -05:00
Matthias Clasen
6b5dff5667
docs: Document GTK_MEDIA
...
Add a paragraph about the GTK_MEDIA environment variable.
2020-11-08 09:58:26 -05:00
Matthias Clasen
53cd499621
Revert "Update gtktreestore.c: gtk_tree_store_remove didn't have the proper comment annotation"
...
This reverts commit 32baa0a549 .
See discussion in https://gitlab.gnome.org/GNOME/gtk/-/issues/78
for the background.
2020-11-07 21:36:34 -05:00
Matthias Clasen
30c5a6f79c
Merge branch 'patch-3' into 'master'
...
gtk/gtktextbuffer: remove GtkTextBufferTargetInfo
See merge request GNOME/gtk!2797
2020-11-08 01:11:26 +00:00
Emmanuele Bassi
4e1191550c
Merge branch 'patch-4' into 'master'
...
gtk/gtkversion: fix doc comment references
See merge request GNOME/gtk!2798
2020-11-08 00:50:40 +00:00
David Lechner
3b1363d31a
gtk/gtkversion: fix doc comment references
...
Cross-references for constants use the "%" prefix rather than the "#" prefix.
2020-11-07 23:57:13 +00:00
David Lechner
160e29ea95
gtk/gtktextbuffer: remove GtkTextBufferTargetInfo
...
GtkTextBufferTargetInfo is not used anywhere and can be removed.
2020-11-07 22:29:11 +00:00
Emmanuele Bassi
b9adad304e
Merge branch 'patch-6' into 'master'
...
gtk/enums: remove GtkPopoverConstraint
See merge request GNOME/gtk!2796
2020-11-07 22:19:33 +00:00
Emmanuele Bassi
ef17d716d7
Merge branch 'patch-4' into 'master'
...
doc: fix missing GtkNotebookTab
See merge request GNOME/gtk!2794
2020-11-07 22:01:33 +00:00
Emmanuele Bassi
8ec01772be
Merge branch 'patch-5' into 'master'
...
gtk/enums: remove GtkMenuDirectionType
Closes #3336
See merge request GNOME/gtk!2795
2020-11-07 21:59:04 +00:00
David Lechner
4084b4c6c6
gtk/enums: remove GtkPopoverConstraint
...
GtkPopoverConstraint is no longer used anywhere and can be removed.
2020-11-07 21:47:32 +00:00
David Lechner
c3cb8e0a79
gtk/enums: remove GtkMenuDirectionType
...
This was used by GtkMenu and can safely be removed.
Closes #3336
2020-11-07 21:39:34 +00:00
Emmanuele Bassi
19b5e5349e
Merge branch 'gles-no-queries' into 'master'
...
gl renderer: Generate queries only on desktop GL
See merge request GNOME/gtk!2792
2020-11-07 21:33:09 +00:00
Emmanuele Bassi
f87923e09e
Merge branch 'patch-3' into 'master'
...
docs: include GtkFilterMatch
See merge request GNOME/gtk!2793
2020-11-07 21:32:40 +00:00
David Lechner
05684f6c3c
doc: fix missing GtkNotebookTab
...
GtkNotebookTab was listed under private, but it is used by the "focus-tab" signal, so it needs to be public.
2020-11-07 21:17:09 +00:00
Emmanuel Gil Peyrot
08193ecf1c
gl renderer: Generate queries only on desktop GL
...
On desktop GL, GL 1.5 or GL_ARB_occlusion_query is required to get the
glGenQueries() etc. symbols. This isn’t the case on GLES, where they
are provided by GL_EXT_occlusion_query_boolean, and more importantly
have never been made core.
This patch allows gtk4-demo to start when GDK_DEBUG=gl-gles is set, on
my Mali 400 MP running the Lima driver from Mesa.
2020-11-07 21:49:42 +01:00
David Lechner
8c9a827516
docs: include GtkFilterMatch
...
The GtkFilterMatch enum type was missing from the documentation.
2020-11-07 20:45:41 +00:00
Timm Bäder
638987f359
Merge branch 'dlech-master-patch-13962' into 'master'
...
gtk/enums: fix doc comment references
See merge request GNOME/gtk!2791
2020-11-07 18:47:55 +00:00
David Lechner
8190f0c420
gtk/enums: fix doc comment references
...
Enum members need a "%" prefix rather than "@" or "%@" in order to
automatically create links in the documentation.
2020-11-07 17:46:26 +00:00
Arnaud Bonatti
f7de0bc9c8
Fix tests with regard to GtkBuilder <requires>.
2020-11-07 16:17:36 +01:00
Arnaud Bonatti
08f2990eac
Document the GtkBuilder <requires> tag changes.
2020-11-07 16:17:14 +01:00
Arnaud Bonatti
e6d46ec5ad
Teach gtk-builder-tool to rewrite <requires>.
2020-11-07 16:17:01 +01:00
Arnaud Bonatti
db6d7dccd8
Drop “gtk+” plus sign in GtkBuilder <requires>.
2020-11-07 16:16:55 +01:00
Piotr Drąg
4e8a5f2ec8
Update POTFILES.skip
2020-11-07 11:45:07 +01:00
Matthias Clasen
63e9414210
Merge branch 'wip/carlosg/for-master' into 'master'
...
Minor text handle fixes
See merge request GNOME/gtk!2787
2020-11-07 03:10:27 +00:00
Carlos Garnacho
4751ac1ac8
gtk/textview: Improve check for cursor-mode
...
Check the text handle role, instead of looking for the other handle
visibility. The other handle may be invisible during selection mode
(e.g. pointing to offscreen contents). This fixes both this code
switching to cursor mode out of the blue, and possible crashes later
on as this handle might be hidden in the process, while its own event
controller is handling events on the parent surface.
2020-11-06 14:30:18 +01:00
Carlos Garnacho
9d56c56117
gtk/texthandle: Point handle to the middle of the pointing_to rect
...
At least vertically, this gives again as much space up and down before
moving the selection the the prev/next line.
2020-11-06 14:28:46 +01:00
Matthias Clasen
0d82faa239
Merge branch 'wip/carlosg/for-master' into 'master'
...
Text handle fixes
Closes #3176
See merge request GNOME/gtk!2785
2020-11-06 01:23:16 +00:00
Matthias Clasen
fb27724042
Merge branch 'wip/chergert/gdk-macos-for-master' into 'master'
...
macos: tweak opacity, color/alpha size requests
See merge request GNOME/gtk!2786
2020-11-06 01:20:23 +00:00
Christian Hergert
90141ef305
macos: use NSOpenGLContext directly for current tracking
...
We don't need to interact with GdkGLContext here to keep the
current context active.
2020-11-05 13:57:41 -08:00
Christian Hergert
bc05da8dc0
macos: explicitly request color and alpha sizes
2020-11-05 13:37:25 -08:00
Christian Hergert
bf3e1e5b40
macos: use opaque GL context when possible
...
This is better for situations where the window is decorated and therefore we can
rely on window system clipping of rounded corners.
2020-11-05 13:34:29 -08:00
Carlos Garnacho
0ae93c8cdc
gtk/textview: Do not forcibly show text handles
...
The gtk_text_view_set_handle_position() function called some lines above
takes care of handle visibility already, also accounting for other
conditions (e.g. whether the handle points to contents onscreen).
Forcibly showing handles here misbehaves if the handle should stay hidden,
and somewhat expensively as it involves creating and throwing a native
surface every time.
2020-11-05 21:29:20 +01:00
Carlos Garnacho
f9813019a7
gtk/textview: Defer touchscreen focus placing to drag end
...
With the scrolledwindow drag gesture not claiming the sequence immediately,
we end up placing the cursor (and undoing the previous selection) each time
we scroll.
There is already handling too short drags in ::drag-end, so let this code
handle touchscreens as well.
2020-11-05 21:29:20 +01:00
Carlos Garnacho
5e907ebd58
gtk/textview: Clean up further if the drag gesture is taken over
...
If the gesture becomes captured (e.g. from a parent scrolledwindow), we
leave some things in the air. Clean these up properly. This is recurrent
with touch scroll.
2020-11-05 21:29:20 +01:00
Carlos Garnacho
fa5fa3a881
gtk/imcontextwayland: Unset focus when unsetting widget
...
In destruction paths of a focused entry, the IM context might first
end up detached from its widget, then destroyed. This currently prevents
the IM context from detaching itself from the GtkIMContextWaylandGlobal.
Make it do so when unsetting the client widget, so the IM context gets
properly unfocused before destruction.
Fixes: https://gitlab.gnome.org/GNOME/gtk/-/issues/3176
2020-11-05 21:29:20 +01:00
Carlos Garnacho
9b9cc2f947
gtk/texthandle: Handle events on parent surface's native
...
In wayland, popup positioning and event handling are doubly async.
This makes it unreliable to figure out parent surface coordinates
out of the popup position and the events received. This results in
jumpy text handles there.
The best way to deal with parent surface coordinates is to handle
the events there. Make the handles transparent to input, and make
the drag gesture be set up on the parent widget's native.
The gesture is set up in the capture phase, setting it on the native
(as opposed to the parent widget) achieves a feeling similar to it
being a distinct surface, as it should take precedence over other
gestures in the emission chain (e.g. scrolledwindows).
As everything is in parent widget's native's coordinates, the drag
handles become smooth again.
2020-11-05 21:29:20 +01:00
Carlos Garnacho
80f5be8b13
gdk/wayland: Ensure to update input area on map
...
If a surface is hidden, then shown again, it should preserve the
input area specified. Make sure that happens.
2020-11-05 21:29:20 +01:00
Matthias Clasen
ec5b5e8aaa
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
Closes #3325
See merge request GNOME/gtk!2784
2020-11-05 16:43:08 +00:00
Emmanuele Bassi
95463719ae
Merge branch 'ebassi/for-master' into 'master'
...
Ebassi/for master
See merge request GNOME/gtk!2783
2020-11-05 15:37:38 +00:00
Emmanuele Bassi
041415e9b4
docs: Add a note on the "presentation" role
2020-11-05 14:50:40 +00:00
Emmanuele Bassi
abd5383d40
docs: Add a section on accessible buttons
...
Anything that behaves like a button should do so at the accessibility
level as well.
2020-11-05 13:57:50 +00:00
Emmanuele Bassi
c5dc0e2e4c
a11y: Use proper role and state for tree expander image
...
The "expander" image is a button, and it controls the expansion of the
row, so it has a state associated to it that we must update.
2020-11-05 13:46:43 +00:00
Emmanuele Bassi
88116712f6
a11y: Use "presentation" role instead of "hidden" state
...
The intended use case of the "presentation" role is
| […] when an element is used to change the look of the page but does not
| have all the functional, interactive, or structural relevance implied
| by the element type, or may be used to provide for an accessible
| fallback in older browsers that do not support WAI-ARIA.
One of the examples is, literally:
| An element whose content is completely presentational (like a spacer
| image, decorative graphic, or clearing element);
Which fits perfectly for the GtkTreeExpander's "indent" builtin icon
widget.
2020-11-05 13:25:53 +00:00
Emmanuele Bassi
7dfa41bbc4
a11y: ARIA's "presentation" role maps to ATSPI_ROLE_SECTION
...
See the mapping role table in the Core-AAM normative document:
https://w3c.github.io/core-aam/#mapping_role_table
2020-11-05 13:14:08 +00:00
Matthias Clasen
c09ff35df4
dragicon: Make a function propertly exported
...
Mark gtk_drag_icon_create_widget_for_value with
GDK_AVAILABLE_IN_ALL, since it is meant to be public.
Also, clarify the documentation a bit.
Fixes : #3325
2020-11-05 07:23:38 -05:00
Matthias Clasen
d526bcc71b
Cosmetics
...
Fix argument ordering of gdk_cursor_new_from_name.
2020-11-04 23:36:09 -05:00
Matthias Clasen
13d1e497f7
testsuite: Improve GdkCursor coverage
2020-11-04 23:36:09 -05:00
Matthias Clasen
3eaae748d3
3.99.4
2020-11-04 21:46:10 -05:00
Matthias Clasen
7f16067383
Merge branch 'wip/chergert/gdk-macos-gl-renderer' into 'master'
...
macos: gl context improvements and event cleanup
See merge request GNOME/gtk!2780
2020-11-05 02:21:02 +00:00
Matthias Clasen
024e048c26
Merge branch 'wip/chergert/fix-macos-pointer-position-over-surface' into 'master'
...
macos: fix calculation of mouse position
See merge request GNOME/gtk!2781
2020-11-05 02:19:18 +00:00
Christian Hergert
c31c3848df
macos: fix calculation of mouse position
...
This fixes the calculation of the position of the pointer over the surface
which was incorrectly providing negative values.
2020-11-04 18:03:54 -08:00
Matthias Clasen
b0e0af1838
Merge branch 'patch-5' into 'master'
...
Update comment annotations of gtk_tree_model_iter_previous and...
See merge request GNOME/gtk!2775
2020-11-05 01:53:34 +00:00
Matthias Clasen
3785bf1f17
Merge branch 'fix-issue-2019-for-master' into 'master'
...
[master] GdkW32: remove klassTEMPSHADOW
Closes #2019
See merge request GNOME/gtk!2750
2020-11-05 01:53:02 +00:00
Matthias Clasen
79fb5724f9
Merge branch 'mr1063-for-master' into 'master'
...
Forward port MR !1063 (Win32 IME fixes) to GTK master
See merge request GNOME/gtk!2777
2020-11-05 01:48:37 +00:00
Christian Hergert
65b2ea1888
macos: resize extra GL window/view when surface changes
...
Once we figure out what is going on with textures, changes are we'll be
able to let this stay a zero rect. But that is still a bit up in the air right now.
2020-11-04 17:21:21 -08:00
Christian Hergert
6309bd12ac
macos: clip damage when swapping buffers
...
This ensures that we only copy the changed area.
2020-11-04 17:21:17 -08:00
Christian Hergert
7444a151b2
macos: remove synthesize_motion helper
...
We can use gdk_surface_request_motion() now instead of our extra
helper to do essentially the same thing.
2020-11-04 16:58:50 -08:00
Christian Hergert
ce9cc2db86
macos: always create dummy window/view for GL context
...
This simplifies the creation by always creating the dummy views, and then
removes it if necessary by detecting the begin_frame/end_frame pair.
2020-11-04 16:52:12 -08:00
Christian Hergert
e91b930648
Revert "Simplify gdk_surface_queue_render"
...
This reverts commit 2120e9df88 .
2020-11-04 16:28:13 -08:00
Matthias Clasen
ed78fb1366
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
See merge request GNOME/gtk!2779
2020-11-04 20:41:09 +00:00
Matthias Clasen
388f12b7d9
Merge branch 'ebassi/for-master' into 'master'
...
Ebassi/for master
See merge request GNOME/gtk!2778
2020-11-04 20:37:39 +00:00
Matthias Clasen
8ae415acff
popovermenu: Fail gracefully if no model
...
If we don't have a model yet, return FALSE from
gtk_popover_menu_add_custom().
2020-11-04 14:59:32 -05:00
Matthias Clasen
d2cc9365fc
Cosmetics
...
Extraneous pair of parens snuck in with 2120e9df88 .
2020-11-04 14:59:27 -05:00
Matthias Clasen
dcfb6e5ef5
surface: Be smarter about autohide
...
When we close grabbing popups due to an outside
click, check at each level if the click is still
outside. This makes closing the nested popover
menu in the popover on page 3 of widget-factory
work as expected, when you click the menubutton
again.
2020-11-04 14:56:30 -05:00
Matthias Clasen
75f96b83de
surface: Be more lenient for autohide
...
When an event happens on a non-grabbing popup that hangs off
a grabbing popup, don't trigger the autohide. This makes touch
text handles work inside the popover on page 3 of widget-factory.
2020-11-04 14:56:30 -05:00
Emmanuele Bassi
66bba1493e
a11y: Remove stray g_printerr()
2020-11-04 19:39:08 +00:00
Emmanuele Bassi
1dde54b872
a11y: Hide the "indent" in GtkTreeExpander
...
It's just padding.
2020-11-04 19:38:14 +00:00
Emmanuele Bassi
c48a990778
a11y: Describe window controls
...
The window controls for client side decorations have only icons, which
means they are not accessible.
2020-11-04 18:59:11 +00:00
Matthias Clasen
23c425618e
Merge branch 'a11y/atcontext-realize' into 'master'
...
A11y/atcontext realize
See merge request GNOME/gtk!2772
2020-11-04 18:10:55 +00:00
Matthias Clasen
d2a7ecf72c
gtk-demo: Simplify the run button
...
Don't create the label manually. It is not necessary,
and letting the button do it also improves the
accessibility setup.
2020-11-04 12:54:48 -05:00
Matthias Clasen
f220a1e3c7
gtk-demo: Set some accessible properties
...
Set labels in the builder demo. The ARIA authoring practices
say that both menubars and toolbars *must* have an accessible
label.
2020-11-04 12:53:23 -05:00
Emmanuele Bassi
ba63aa76ca
a11y: Move parent context ref getter to its own function
...
Keeps the body of handle_accessible_get_property() readable.
2020-11-04 17:16:24 +00:00
Emmanuele Bassi
72415eaa49
a11y: Make the Button labelled by its child label
...
Establish the relation whenever we set the label widget.
2020-11-04 17:15:13 +00:00
Emmanuele Bassi
d88f7c9459
a11y: Use the tooltip text as the accessible description
...
It's more common to have a tooltip as the accessible description than an
explicit description. This is also the behaviour of GTK3.
2020-11-04 17:15:13 +00:00
Emmanuele Bassi
425d8ad02a
Set accessible label on GTK Demo's primary menu
...
Otherwise its label is going to be "GtkMenuButton".
2020-11-04 17:15:13 +00:00
Emmanuele Bassi
ae9758b964
a11y: Unrealize ATContext on dispose
2020-11-04 17:15:13 +00:00
Matthias Clasen
828a067b2b
Propagate accessible-role to backend
...
We want to allow setting the accessible role as long
as the context is unrealized, so we need to propagate
the new role.
2020-11-04 11:53:07 -05:00
Matthias Clasen
bb24b350ac
gtk-demo: Set an accessible role
...
Set an accessible role for the toolbar in the
builder demo. This tests accessibility support
in GtkBuilder.
2020-11-04 11:36:52 -05:00
Emmanuele Bassi
dafb2b0361
a11y: Allow updating role on unrealized contexts
...
We can still change the accessible role if an ATContext instance is
unrealized.
2020-11-04 15:22:31 +00:00
Emmanuele Bassi
30210c7087
a11y: Move ATContext to an explicit realization model
...
We are doing too much work during the construction phase of the
AT-SPI backend for GtkATContext. Instead of having the AtSpiContext
register itself at construction time, let's add explicit realize
and unrealize operations, and connect the ATContext realization to the
rooting operation of a GtkWidget.
2020-11-04 15:02:44 +00:00
Philip Zander
d8a795df0a
Win32 IME fixes
...
See merge request !1063
2020-11-04 17:17:52 +08:00
kai-berlin
499e4b4c50
broadway: Set modifier state of scroll events
...
Set modifier state of scroll events, so Ctrl-scroll
works.
Fixes : #2733
2020-11-03 19:21:00 -05:00
Matthias Clasen
fd52220b1b
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
Closes #3318 , #3319 , and #3320
See merge request GNOME/gtk!2776
2020-11-03 20:15:08 +00:00
Matthias Clasen
e9438224ab
texthandle: Queue a draw when role changes
...
This helps with role changes not taking immediate
effect.
Fixes : #3320
2020-11-03 14:39:29 -05:00
Matthias Clasen
2120e9df88
Simplify gdk_surface_queue_render
...
We can just call gdk_surface_invalidate_rect here
like we do elsewhere in gdk, and I'm a bit uncertain
about the current code that adds an empty update
region.
2020-11-03 14:37:27 -05:00
Matthias Clasen
ddd16dd312
texthandle: Fix positioning
...
Use the same approach we use for popovers, using
gtk_widget_get_surface_allocation. It works.
Fixes : #3319
2020-11-03 12:37:39 -05:00
Matthias Clasen
7624f66fec
widget-factory: Make sure we close popover on page 3
...
We don't want the popover to stay open when we open
an about dialog or shortcuts window. Since cascade-popdown
would also affect e.g. the context menu of the text widgets,
do this explicitly.
2020-11-03 12:09:43 -05:00
Matthias Clasen
dab11ea841
popover: Change default for cascade-popdown
...
We've found a number of cases where this cascading
has unexpected side-effects. So, turn it off by
default, and only set it for menus.
2020-11-03 11:00:32 -05:00
Matthias Clasen
a3f3dc0f1c
Adwaita: Set a background for magnifiers
...
The magnifier in entries is magnifying the GtkText
widget, which does not draw any background itself.
Therefore, we give the magnifier a background, to
make things look as expected.
Fixes : #3318
2020-11-03 11:00:32 -05:00
Matthias Clasen
5d59447ccb
magnifier: Set a css name
...
Predictably, we use the name "magnifier".
2020-11-03 11:00:32 -05:00
Matthias Clasen
e3c38e4143
NEWS: Updates
2020-11-03 11:00:32 -05:00
Matthias Clasen
e5ec4df702
docs: Mention g_file_get_basename
...
Mention g_file_get_basename in the migration guide section
about GtkFileChooser api changes.
2020-11-03 11:00:32 -05:00
Danny Milosavljevic
1340ff2bc2
Update comment annotations of gtk_tree_model_iter_previous and gtk_tree_model_iter_next to state that the ITER parameter is modified.
2020-11-03 15:10:11 +00:00
Matthias Clasen
dbdc909e19
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
See merge request GNOME/gtk!2774
2020-11-03 12:14:21 +00:00
Matthias Clasen
c6ef1943e4
gtk-demo: Remove more gtk3-demo icon uses
...
Use our own logo everywhere.
2020-11-02 22:50:03 -05:00
Matthias Clasen
a3c9f8594a
gtk-demo: Tweak images demo
...
Use our own logo instead of the gtk3-demo one, and
tweak the headings to refledct what we show.
2020-11-02 22:43:44 -05:00
Matthias Clasen
354f2b65fa
gtk-demo: Reanimate floppy buddy
...
Implement a GdkPaintable wrapper around GdkPixbufAnimation,
so floppy buddy can waive again.
2020-11-02 21:38:02 -05:00
Matthias Clasen
b3657d5f2e
widget-factory: Restore modality of the about dialog
...
Make the about dialog of widget-factory modal again.
This was lost in 87a8fda163 .
2020-11-02 21:37:55 -05:00
Timm Bäder
82ca65956f
gl renderer: Make debugging code shorter
2020-11-02 14:55:14 -05:00
Timm Bäder
c8c2106f3e
gl renderer: Refactor vertex data loading code
2020-11-02 14:55:14 -05:00
Timm Bäder
8178dfb85a
gl renderer: Use the load_vertex_data* functions more often
2020-11-02 14:55:14 -05:00
Timm Bäder
50e78198a8
gl renderer: More load_vertex_data* usage
2020-11-02 14:55:14 -05:00
Timm Bäder
ee04cbcfa8
gl renderer: Reword a comment
2020-11-02 14:55:14 -05:00
Timm Bäder
fc312f7ffe
gl renderer: Remove an outdated comment
2020-11-02 14:55:14 -05:00
Timm Bäder
e6e964c3f3
gl renderer: Refactor rendering shadow nodes
...
Also use load_vertex_data_with_region here.
2020-11-02 14:55:14 -05:00
Timm Bäder
df5e796d99
gl renderer: Refactor blurred shadow drawing code
...
We already have various load_vertex_data* code, so try to reuse that
here.
2020-11-02 14:55:14 -05:00
Timm Bäder
d3239c953d
gl renderer: Nine-slice unblurred outset shadows
...
See #3284
2020-11-02 14:55:13 -05:00
Timm Bäder
fb9a3bf32b
printoperation: Remove double assignment
2020-11-02 14:55:13 -05:00
Matthias Clasen
ace83a938d
Merge branch 'matthiasc/for-master' into 'master'
...
gtk-demo polish
See merge request GNOME/gtk!2773
2020-11-02 19:36:09 +00:00
Matthias Clasen
fb028f0fe7
gtk-demo: Renovate the paned demo
...
Make this look less like testgtk from GTK 2.
2020-11-02 13:56:19 -05:00
Matthias Clasen
8a13909bab
fixup: window titles
2020-11-02 12:02:19 -05:00
Matthias Clasen
4e745f06e9
gtk-demo: Polish all entry demos
...
Make the spacing a bit more consistent, and tweak
some strings here and there.
2020-11-02 12:01:11 -05:00
Matthias Clasen
14b65a3c4f
gtk-demo: Polish the search bar demo
...
Rename this, and make it look a bit less like a
debugging tool, and more like a demo.
2020-11-02 12:00:24 -05:00
Matthias Clasen
64ad490bc1
gtk-demo: Tweak tagged entry styling
...
Move the tags closer together, and avoid resizing too much.
2020-11-02 11:59:22 -05:00
Matthias Clasen
d2d7a4bcab
gtk-demo: Tweak window titles
...
This is an attempt to improve consistency in the sidebar
and the window titles.
2020-11-02 11:11:44 -05:00
Matthias Clasen
14cbd13ef2
gtk-demo: Use typographic style classes
...
We don't need to hardcode <u> in markup anymore.
Use the heading style class instead.
2020-11-02 08:38:20 -05:00
Matthias Clasen
efc314196d
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
See merge request GNOME/gtk!2769
2020-11-02 11:52:13 +00:00
Matthias Clasen
403a70ca89
testsuite: Add tests for gtk4-builder-tool validate
2020-11-01 23:09:26 -05:00
Matthias Clasen
44b36b6321
builder-tool: Stop rewriting GtkPopoverMenu
...
We no longer allow manual creation of GtkPopoverMenu,
translating individual properties is not going to
change that.
2020-11-01 23:09:26 -05:00
Matthias Clasen
4bd829e3e1
testsuite: Test GtkFixed rewriting
2020-11-01 23:09:26 -05:00
Matthias Clasen
38f74d8a23
builder-tool: Rewrite GtkFixed more
...
GtkFixedLayout does not have layout properties
for x and y, so turn those into a transform.
2020-11-01 23:09:26 -05:00
Matthias Clasen
2613c2ef9b
builder-tool: Avoid duplicate path prefixes
...
It is enough to print the file in which the error
occurred once; GtkBuilder already makes that part
of its error message.
2020-11-01 23:09:26 -05:00
Matthias Clasen
5751cd662d
builder-tool: Install a log writer
...
Install a log writer function that is a bit simpler than
the default GLib log writer, and does not put PIDs and
timestamps in the output, so we can compare easily in
our testsuite.
2020-11-01 23:09:26 -05:00
Matthias Clasen
4039b713c3
Set G_LOG_USE_STRUCTURED globally
...
It doesn't make much sense to set this in per-directory
meson files, since that makes use use different logging
facilities in different parts of the project. Set it
globally.
2020-11-01 21:23:35 -05:00
Matthias Clasen
c3f8010b19
testsuite: Test GtkToolbar rewriting
2020-11-01 21:23:35 -05:00
Matthias Clasen
3e8a22ae8a
builder-tool: Rewrite GtkToolbar more
...
Replace GtkToolbar with GtkBox and GtkToolButton with
GtkButton.
2020-11-01 21:23:35 -05:00
Matthias Clasen
c01f3be6e6
testsuite: Test GtkActionBar rewriting
2020-11-01 21:23:35 -05:00
Matthias Clasen
0cf372c814
testsuite: Test GtkPaned rewriting
2020-11-01 21:23:35 -05:00
Matthias Clasen
ac20c9cd41
builder-tool: Fix rewriting GtkPaned
...
The properties have been renamed in bc6643f3c2 .
2020-11-01 21:23:35 -05:00
Matthias Clasen
d74c2a74e5
builder-tool: Drop unneeded code
...
We are rewriting the tree before simplifying it,
so there is no need to 'keep things for rewriting'
in the simplify phase.
2020-11-01 21:23:35 -05:00
Matthias Clasen
b79637ac41
testsuite: Test GtkOverlay rewriting
2020-11-01 21:23:35 -05:00
Matthias Clasen
e135772119
buildertool: Improve GtkOverlay rewriting
...
Translate the GtkOverlay:pass-through child property to
the GtkWidget:measure property, and drop the :index
child property.
2020-11-01 21:23:35 -05:00
Matthias Clasen
3cf26b471b
Fix the definition of GtkWidget:can-target
...
We are setting the value to TRUE initially, but
the property had a declared default of FALSE.
This is messing up the simplification of .ui files
with gtk4-builder-tool, since it thinks it can
omit can-target properties when it really can't.
2020-11-01 21:23:35 -05:00
Matthias Clasen
c630285692
Cosmetics
2020-11-01 21:23:35 -05:00
Matthias Clasen
5702b71037
Remove leftover file
...
This was never used in tests.
2020-11-01 21:23:35 -05:00
Matthias Clasen
a4e5f5ca50
testsuite: More gtk4-builder-tool tests
2020-11-01 21:23:35 -05:00
Matthias Clasen
b0b00d49d2
testsuite: Test gtk4-builder-tool simplify --replace
...
Run all gtk4-builder-tool test with and without --replace.
This improves test coverage for gtk4-builder-tool
2020-11-01 21:23:35 -05:00
Matthias Clasen
cb018ec047
builder-tool: Avoid a crash
...
Be more careful about types that have been removed.
I was getting criticals when converting ui files
containing GtkToolbars.
2020-11-01 21:23:35 -05:00
Matthias Clasen
168b21c77e
testsuite: Improve coverage for GdkTexture
2020-11-01 21:23:35 -05:00
Matthias Clasen
2dcc641d5a
testsuite: Improve coverage for GdkDisplayManager
2020-11-01 21:23:35 -05:00
Matthias Clasen
c8432ae668
testsuite: Improve coverage for seats
2020-11-01 21:23:35 -05:00
Matthias Clasen
642ad4e06f
testsuite: Improve coverage for rectangles
2020-11-01 21:23:35 -05:00
Tim Sabsch
924796b478
Update German translation
2020-11-01 14:08:13 +00:00
Piotr Drąg
319d4c7e01
Update Polish translation
2020-11-01 10:37:21 +01:00
Matthias Clasen
07c491f235
testsuite: Improve coverage for keys
2020-10-31 14:57:02 -04:00
Matthias Clasen
970f91ec24
testsuite: Add more css parser tests
...
Add tests for url parsing.
2020-10-31 09:18:40 -04:00
Matthias Clasen
48381bd4f6
testsuite: Add a forgotten test
...
I've written this test a while ago, but did not add
it to the test data list in meson.build.
2020-10-31 08:30:02 -04:00
Matthias Clasen
1a12999431
testsuite: Add a css test
...
This test verifies that CDO and CDC are ignored
as required.
2020-10-31 00:38:49 -04:00
Matthias Clasen
90676540ec
css: Fix tokenization of CDO
...
A CDO is 4 characters: <!--, not 3 as our tokenizer
was pretending.
2020-10-31 00:38:49 -04:00
Matthias Clasen
7db58d5f8d
gsk: Don't compile unused code
...
The NodeSample and GskGLImage code is not used,
so don't compile it.
2020-10-30 23:36:39 -04:00
Matthias Clasen
875452b476
testsuite: Improve coverage for GtkMultiSorter
2020-10-30 23:33:34 -04:00
Matthias Clasen
1c4c5e3b80
testsuite: Improve coverage for GtkStringList
2020-10-30 23:33:15 -04:00
Matthias Clasen
af5e13b9a1
Remove an unused function
...
The only property of GtkStringObject is readonly since
commit fb14f50ec1 , so we don't need a
set_property implementation.
2020-10-30 23:32:30 -04:00
Matthias Clasen
9b78bc4af7
testsuite: Improve coverage
2020-10-30 23:04:23 -04:00
Matthias Clasen
1702a4c223
Drop an unused private function
2020-10-30 22:51:54 -04:00
Matthias Clasen
f0e35c8ed8
Drop unused includes
2020-10-30 22:50:38 -04:00
Matthias Clasen
26150d8489
testsuite: Improve coverage for GtkExpression
2020-10-30 22:27:40 -04:00
Matthias Clasen
48dcbf4935
expression: Fix property expressions for interfaces
...
We were not checking the passed-in type in the right
way. An interface type can still pass the
g_type_is_a (..., G_TYPE_OBJECT) check, if G_TYPE_OBJECT
is one of its prerequisites. What we need to check is
whether the fundamental type is G_TYPE_OBJECT.
2020-10-30 22:27:40 -04:00
Matthias Clasen
59dd7d8900
testsuite: Improve coverage for GtkMultiFilter
2020-10-30 22:27:40 -04:00
Matthias Clasen
c279bdaa81
testsuite: Improve coverage for GtkStringFilter
2020-10-30 20:15:25 -04:00
Matthias Clasen
01d52a7292
testsuite: Make all css tests run again
...
The tests in subdirectories of testsuite/css were
using an environment defined in the parent directory,
causing them to not find their test data. Give each
test directory its own environment.
2020-10-30 20:14:17 -04:00
Matthias Clasen
2b38d14bf5
tests: Improve coverage for css data url parsing
...
Cover the error conditions as well.
2020-10-30 19:26:56 -04:00
Matthias Clasen
d35a21873e
testsuite: Improve coverage for GtkBoolFilter
2020-10-30 18:17:50 -04:00
Matthias Clasen
b23cae9643
Drop unused gtk_buildable_set_buildable_property
2020-10-30 17:19:52 -04:00
Matthias Clasen
505df337c2
Add a test for constraints in ui files
...
Test the various values that are possible for the constraint
attributes.
2020-10-30 16:21:14 -04:00
Matthias Clasen
117997da54
Merge branch 'wip/chergert/gdk-macos-gl-renderer' into 'master'
...
macos: add more aggressive clip to transparent subview
See merge request GNOME/gtk!2762
2020-10-30 19:48:57 +00:00
Matthias Clasen
19052d4360
gtk-demo: Tweak descriptions of constraints demos
...
Make these a little longer, and include more details.
2020-10-30 15:26:37 -04:00
Matthias Clasen
2dbaca2464
constraintlayout: Make sure guides get their constraints
...
When using GtkBuilder to create constraints and guides,
the layout manager is already rooted when the guides get
created, and we were forgetting to create the guides
constraints in this case. Fix it by adding a call to
gtk_constraint_guide_update().
This was showing up in the new builder-based constraints
demo as the guide not having the expected effect.
2020-10-30 15:04:13 -04:00
Matthias Clasen
4b8134b19b
constraintlayout: Emit less change notification
...
This isn't strictly required for correctness, but
it makes the GtkBuilder codepath do the same that
the vfl codepath does: call gtk_layout_manager_layout_changed
only once, after all the constraints have been added.
2020-10-30 15:04:13 -04:00
Matthias Clasen
588fe5b5c1
gtk-demo: Tweak the new constraints demo
...
With these somewhat random ordering changes, things get
closer to working the same as the code example. Still,
the guide doesn't work right.
2020-10-30 15:04:13 -04:00
Matthias Clasen
b8f44de48e
constraintlayout: Fix parsing from ui file
...
Guides were not properly looked up when creating
constraints in a ui file.
2020-10-30 15:04:13 -04:00
Matthias Clasen
49bdc4f0c2
Add another constraints demo
...
This one attempts to use constraints in a ui file.
It doesn't work.
2020-10-30 15:04:13 -04:00
Matthias Clasen
a0ee25a21e
gtk-demo: Remove unnecessary code
...
I was distracted by this code that sets names
on widgets in the constraints demo - the names
aren't used and aren't needed, so remove them.
2020-10-30 15:01:50 -04:00
Christian Hergert
d8192013f3
macos: add more aggressive clip to transparent subview
...
The Cairo implementation for the Macos backend uses a toplevel
window with full transparency and a series of NSView to create opaque
regions. This improves compositor performance because it allows the
display server to avoid costly blends.
However, we want to ensure we clip better when exposing the
transparent region so that we only expose the shadows/corners as
necessary.
2020-10-29 19:41:21 -07:00
Matthias Clasen
8ed1f51f7f
Merge branch 'wip/chergert/remove-GDK_WINDOWING_QUARTZ' into 'master'
...
gdk: remove remaining GDK_WINDOWING_QUARTZ usage
See merge request GNOME/gtk!2761
2020-10-30 01:36:10 +00:00
Matthias Clasen
03fec389f4
docs: Add details for gsk_renderer_new_for_surface
...
Mention the GSK_RENDERER variable here.
2020-10-29 18:21:44 -04:00
Matthias Clasen
38c39e2aa1
NEWS: Updates
2020-10-29 18:21:32 -04:00
Christian Hergert
6298fd1eef
gdk: remove remaining GDK_WINDOWING_QUARTZ usage
2020-10-29 13:57:28 -07:00
Matthias Clasen
5a77994516
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
See merge request GNOME/gtk!2760
2020-10-29 18:55:53 +00:00
Matthias Clasen
6142238237
Merge branch 'wip/chergert/gdk-macos-gl-renderer' into 'master'
...
macos: implement GL rendering on with Cairo renderer
See merge request GNOME/gtk!2759
2020-10-29 18:33:13 +00:00
Matthias Clasen
3164f328b5
docs: Some restructuring
...
Give the GDK docs some more structure.
2020-10-29 14:23:46 -04:00
Matthias Clasen
ce78d0c301
docs: Tweak GdkToplevel docs
2020-10-29 14:23:46 -04:00
Matthias Clasen
94305f248b
docs: Tweak GdkPopup docs
2020-10-29 14:23:46 -04:00
Matthias Clasen
3afd5d7a89
docs: Tweak GdkSurface docs
...
Add more details, and refer to the GdkToplevel / GdkPopup
docs.
2020-10-29 14:23:46 -04:00
Matthias Clasen
d2adbad408
docs: Tweak frame clock docs
2020-10-29 14:23:46 -04:00
Matthias Clasen
2df382277d
docs: Small additions for GdkCursor docs
2020-10-29 14:23:46 -04:00
Matthias Clasen
9f71bdd045
docs: Cosmetics
...
Make the GdkRGBA heading less repetitive.
2020-10-29 14:23:46 -04:00
Matthias Clasen
838d0924b9
docs: Tweak GdkPaintable docs
...
Minor additions here and there.
2020-10-29 14:23:46 -04:00
Matthias Clasen
1f8d593931
docs: Add some detail to GdkTexture docs
...
Minor additions here and there.
2020-10-29 14:23:46 -04:00
Matthias Clasen
574a3a456d
gdk: Drop GdkPoint from the api
...
This typedef was not used in any public APIs, and is
only used in the MacOS backend. It is not worth preserving
as public API, move it to the only user.
2020-10-29 14:23:46 -04:00
Matthias Clasen
3617fbab42
docs: Include GDK_WINDOWING_MACOS
...
We no longer have a Quartz backend, it is called
MacOS now.
2020-10-29 14:23:46 -04:00
Matthias Clasen
29ccd13e15
docs: Stop referring to the Quartz backend
...
Its MacOS now.
2020-10-29 14:23:46 -04:00
Christian Hergert
de9c9efa6f
macos: implement GL context
...
This implements the basics for a GdkGLContext on macOS. Currently, rendering
only is fully working for the GskCairoRenderer case where we read back pixels
into a cairo surface for rendering. More work on synchronization is required for
the GL on GskGLRenderer case.
When we attempt to render a surface itself with GL, the context will ensure that
the new GdkMacosGLView is placed within the NSWindow. In other cases, we
use a dummy NSView and NSWindow for backing the NSOpenGLContext to
ensure that we can get accelerated drawing.
This gets GtkGLArea working when running with GSK_RENDERER=cairo.
2020-10-29 10:57:02 -07:00
Christian Hergert
eb809ba425
macos: tweak gravity while resizing
...
This helps a situation where the window contents has not changed
in time for a drawing. Setting the texture gravity helps that side or
corner to be less jittery while moving.
Ideally, we can get to a point where we are synchronized and keeping
up with drawing fast enough to not need this. That may require some
work to drive frame clocks from drawRect: though.
2020-10-29 10:57:02 -07:00
Christian Hergert
adf60fb3a1
macos: be tolerant of NULL GL context
...
Some code appears to unconditionally attempt to make the context current,
so this makes things tolerant to a NULL GdkGLContext and just return FALSE.
2020-10-29 10:57:02 -07:00
Christian Hergert
a3fd46c516
glsl: tweak pre-processor to support Apple GLSL compiler
...
The Apple GLSL compiler cannot deal with empty pre-processor blocks such as
#if GSK_GLES
#elif GSK_LEGACY
2020-10-29 10:57:02 -07:00
Christian Hergert
0040667965
macos: remove unused GL layer
...
This isn't being used, and instead we'll go the route of a NSView for
the OpenGL implementation.
2020-10-29 10:57:02 -07:00
Christian Hergert
60e67a62e6
macos: move setNeedsDisplay helper to GdkMacosCairoView
...
This isn't needed in the base class, which will eventually get a GL subclass.
2020-10-29 10:57:02 -07:00
Matthias Clasen
931f130377
Merge branch 'wip/chergert/gdk-remove-texture_from_surface' into 'master'
...
gl: remove unused texture_from_surface API
See merge request GNOME/gtk!2756
2020-10-29 15:50:01 +00:00
Christian Hergert
524fbc35a7
gl: remove unused texture_from_surface API
...
This is not used anywhere and only exists within the X11 backend. It
can be removed now.
2020-10-29 08:26:27 -07:00
Matthias Clasen
51d35750f6
Cosmetics
...
Whitespace fix.
2020-10-29 07:40:30 -04:00
Matthias Clasen
90fde9c939
Merge branch 'matthiasc/for-master' into 'master'
...
textview: Update child allocations
See merge request GNOME/gtk!2757
2020-10-29 11:21:30 +00:00
Matthias Clasen
5cbc55578f
textview: Update child allocations
...
This was accidentally lost when display line caching
was introduced.
2020-10-28 20:18:54 -04:00
Piotr Drąg
f90e7b9c56
Update POTFILES.skip
2020-10-28 15:12:01 +01:00
Matthias Clasen
d5b9489408
Merge branch 'wip/baedert/for-master' into 'master'
...
Wip/baedert/for master
Closes #3282
See merge request GNOME/gtk!2755
2020-10-27 22:38:58 +00:00
Matthias Clasen
975d763db1
Merge branch 'dropdown-checkmark' into 'master'
...
Dropdown checkmark
Closes #3291
See merge request GNOME/gtk!2754
2020-10-27 20:41:34 +00:00
Matthias Clasen
907fc30fac
gtk-demo: Add checkmarks to all dropdown demos
...
This follows the mockups that these demos are
copied from. Unfortunately, it has to be implemented
for every item factory, so we repeat it here.
Fixes : #3291
2020-10-27 16:13:44 -04:00
Matthias Clasen
25d2efeabe
dropdown: Add a checkmark to the selected item
...
Make the default factory add a checkmark to the
currently selected item (not the hovered item)
in the popup. This will unfortunately have to be
done in non-default factories too.
Related: #3291
2020-10-27 16:13:38 -04:00
Matthias Clasen
3a119a3d3a
dropdown: Make search entry shrink
...
We don't want the popup to be wider than the button
if we can help it. The search entry does not need
to be very wide.
2020-10-27 15:35:34 -04:00
Matthias Clasen
8df883ed71
Merge branch 'matthiasc/atspi-child' into 'master'
...
Emit ChildrenChanged signal on hierarchy updates
See merge request GNOME/gtk!2752
2020-10-27 18:24:43 +00:00
Matthias Clasen
0c49f7349d
Merge branch 'matthiasc/a11y-buildable' into 'master'
...
Implement accessible attributes for ui files
See merge request GNOME/gtk!2751
2020-10-27 18:13:44 +00:00
Luca Bacci
eef1097c90
GdkW32: remove klassTEMPSHADOW
...
Fixes issue #2019
2020-10-27 18:26:45 +01:00
Benjamin Otte
08004d4eed
Merge branch 'wip/otte/for-master' into 'master'
...
Wip/otte/for master
Closes #3295
See merge request GNOME/gtk!2748
2020-10-27 16:27:10 +00:00
Benjamin Otte
6d7e56bed6
cloudprint: Make compile without warnings
2020-10-27 16:43:34 +01:00
Benjamin Otte
8e6701c9a6
gtkmediafile: Use cubic volume function
...
Gstreamer suggests doing that.
https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/issues/1439
Fixes #3295
2020-10-27 16:32:53 +01:00
Jakub Steiner
6d5c512571
Merge branch 'wip/jimmac/gtk4-dropdown-papercuts' into 'master'
...
Adwaita: dropdown search box
See merge request GNOME/gtk!2747
2020-10-27 12:55:33 +00:00
Jakub Steiner
b94ea1b4f7
Adwaita: dropdown search box
...
- have some whitespace around entry
Partial fix for https://gitlab.gnome.org/GNOME/gtk/-/issues/3291
2020-10-27 13:32:04 +01:00
Matthias Clasen
b2d6011679
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
See merge request GNOME/gtk!2746
2020-10-27 05:05:33 +00:00
Matthias Clasen
c0aa1c8a49
Merge branch 'popover-menu-custom-child' into 'master'
...
popovermenu: Allow custom items
Closes #3260
See merge request GNOME/gtk!2728
2020-10-27 04:51:00 +00:00
Matthias Clasen
5fe837483c
docs: Add GtkOverlay to the widget gallery
2020-10-27 00:42:38 -04:00
Matthias Clasen
4f15b988e7
docs: Add box, grid and center box to the gallery
2020-10-27 00:24:54 -04:00
Matthias Clasen
6cd3bc7384
modelbutton: Explicitly set up LABELLED-By relation
...
GTK does this automatically based on mnemonics, but only
if the string actually contains a mnemonic. This makes
orca read out menuitems, as expected.
2020-10-26 22:48:01 -04:00
Matthias Clasen
0faadef36f
widget-factory: Add a scale to the gear menu
...
This tests the custom menuitem support, and lets you
control the transition duration for the main stack.
2020-10-26 22:43:12 -04:00
Matthias Clasen
af6c3017fb
popovermenu: Allow adding custom items in ui files
...
Support <child type="ID"> to fill custom child slots
in both GtkPopoverMenus and GtkPopoverMenuBars that
are created in ui files.
2020-10-26 22:42:28 -04:00
Matthias Clasen
8157abe591
popovermenu: Allow custom items
...
Add a way to add children at certain places in
the generated menu for both GtkPopoverMenu and
GtkPopoverMenuBar.
New apis:
gtk_popover_menu_add_child
gtk_popover_menu_remove_child
gtk_popover_menu_bar_add_child
gtk_popover_menu_bar_remove_child
Fixes : #3260
2020-10-26 22:41:33 -04:00
Matthias Clasen
61e08baec1
Merge branch 'master' into 'master'
...
Fix the build with cups < 2.2.12
Closes #2968
See merge request GNOME/gtk!2744
2020-10-26 20:09:30 +00:00
Thomas Lange
0493e89897
Fix the build with cups < 2.2.12
...
PPD_CUSTOM_UNKNOWN was introduced in cups 2.3.
and has been backported to 2.2.12.
Only handle it when we build against a new enough cups.
Fixes : #2968
2020-10-26 19:16:26 +01:00
Matthias Clasen
c783e9aa5f
Treat tristate as an enum when parsing
...
This makes it so that you have to explicitly specify
"true" and "false" for the checked state, but it
matches how this enumeration is meant to be used.
2020-10-26 08:01:13 -04:00
Matthias Clasen
4661f15fab
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
See merge request GNOME/gtk!2741
2020-10-26 05:28:43 +00:00
Matthias Clasen
e51a98d184
docs: Add GtkDrawingArea to the gallery
2020-10-26 01:08:49 -04:00
Matthias Clasen
b67eee5741
docs: Add GtkShortcutsWindow to the widget gallery
2020-10-26 01:08:49 -04:00
Matthias Clasen
d9259fc958
docs: Add GtkPopoverMenu to the widget gallery
2020-10-26 01:08:49 -04:00
Matthias Clasen
65f748fc62
docs: Add GtkPopover to the widget gallery
2020-10-26 01:08:49 -04:00
Matthias Clasen
bed3616bf0
docs: Add GtkPopoverMenuBar to the gallery
2020-10-26 01:08:49 -04:00
Matthias Clasen
1605ca0140
docs: Add GtkExpander to the gallery
2020-10-26 01:08:49 -04:00
Matthias Clasen
8692f5d8e3
docs: Add GtkEmojiChooser to the gallery
...
To make this possible enable the doc shooter
to take screenshots of popovers.
2020-10-26 01:08:49 -04:00
Matthias Clasen
42e2c54922
docs: Redo the GtkColorChooserDialog gallery image
...
Show the new palette.
2020-10-25 22:54:53 -04:00
Matthias Clasen
291c61891a
docs: Improve the GtkStackSidebar gallery image
2020-10-25 22:54:41 -04:00
Matthias Clasen
59e08c0dac
docs: Tweak gallery layout
...
Now that the volume button image is small, move it
to a better place in its section. Improves the layout.
2020-10-25 22:46:30 -04:00
Matthias Clasen
a70c9c69a0
docs: Fix the GtkVolumeButton gallery image
...
Give up on showing the popup, we don't do that
for other buttons either.
2020-10-25 22:42:40 -04:00
Matthias Clasen
dffe6b87e4
docs: Add GtkCalendar to the gallery
...
It has been missing far too long.
2020-10-25 22:32:27 -04:00
Matthias Clasen
28b7962bee
docs: Improve the GtkMediaControls gallery image
2020-10-25 22:26:19 -04:00
Matthias Clasen
64e131f285
docs: Improve the GtkVideo gallery image
2020-10-25 22:17:15 -04:00
Matthias Clasen
a9f0f18c3a
docs: Tweak gallery layout
...
Improve the breaks in the container section.
2020-10-25 22:16:26 -04:00
Matthias Clasen
2e0822bed0
docs: Shrink the editable label gallery image
...
Makes it fit better with the other entries.
2020-10-25 21:52:51 -04:00
Matthias Clasen
b0fb31fc96
docs: Some reordering in the gallery
...
Align things better.
2020-10-25 21:47:40 -04:00
Matthias Clasen
163d32eea1
docs: Work around GtkPicture growing
...
Make the GtkPicture gallery image stay within its
limits, by overpowering its request mode.
2020-10-25 21:30:15 -04:00
Matthias Clasen
b7728a884b
docs: Tweak gallery ordering
...
Move GtkSpinButton to the entries, where it
belongs, despite its name.
2020-10-25 21:10:12 -04:00
Matthias Clasen
86b4b2eef2
docs: Fix links from the gallery
...
It turns out gtk-doc can't even parse its own custom
links if you don't arrange for the <link> element to
on a single line, since it is just a glorified sed
script :(
2020-10-25 21:07:12 -04:00
Matthias Clasen
09eda804f7
docs: Add GtkWindowControls to the gallery
2020-10-25 21:06:46 -04:00
Matthias Clasen
37d4932b31
a11y: Add more tests
...
Test some of the attributes that GTK maintains
for every widget.
2020-10-25 19:29:00 -04:00
Matthias Clasen
0fddf73ddb
a11y: Add some parser tests
...
Checking basic support for acessible states, properties
and relations in ui files.
2020-10-25 13:01:44 -04:00
Matthias Clasen
f981ab7a9e
Remove erroneous preconditions
...
Tests found these functions to be non-working.
2020-10-25 12:43:52 -04:00
Matthias Clasen
677ea5f22d
a11y: Reuse builder parsing for enums
...
No need to manually write all these parsing functions
when _gtk_builder_enum_from_string does exactly what
is needed here.
2020-10-25 12:38:52 -04:00
Matthias Clasen
fce455ae0b
a11y: Parse booleans in ui files as expected
...
Accept the same syntax for booleans as GtkBuilder
does elsewhere.
2020-10-25 12:20:55 -04:00
Matthias Clasen
e050a2661c
builder: Expot _gtk_builder_boolean_from_string privately
...
When specifying accessible properties in ui files, it
is better to accept the same syntax for booleans as
elsewhere, so lets reuse this function.
2020-10-25 12:19:21 -04:00
Piotr Drąg
a03581ce39
Update Polish translation
2020-10-25 10:37:47 +01:00
Matthias Clasen
13b9b9b7d8
scale: Set round-digits to -1 initially
...
This ensures that keybindings for small-step changes
work despite draw-value being FALSE now. This was
fallout from 8ca612c966 that showed up
as arrow keys not working anymore for the color scales
in the color chooser.
2020-10-25 00:31:18 -04:00
Matthias Clasen
0a3b370805
Cosmetics
...
Remove some comments that refer to no longer
existing menu code.
2020-10-25 00:31:18 -04:00
Matthias Clasen
313ba0280a
color editor: Add accessible labels
...
Add some labels to the controls in this dialog.
2020-10-24 23:55:56 -04:00
Matthias Clasen
adb7676fc1
a11y: More State<>Change confusion
...
We should really avoid this needless duplication
- the 'state' is never stored anywhere.
2020-10-24 23:12:36 -04:00
Matthias Clasen
8ffb398517
a11y: Handle all cases for state change
...
Make state_change handle state changes for non-widgets,
and handle the cases for HIDDEN involving stack pages.
2020-10-24 22:05:17 -04:00
Matthias Clasen
9a943e21d3
stack: Update HIDDEN a11y state for stack pages
...
This will let us handle additions and removals
in the AT-SPI backend.
2020-10-24 22:04:26 -04:00
Matthias Clasen
7c106578ed
Cosmetics
...
Make gtk_at_spi_root_child_changed take a
GtkAccessible for the child.
2020-10-24 21:35:35 -04:00
Matthias Clasen
d1d9b92aee
Merge branch 'meson-deps-continued' into 'master'
...
Turn more options into "feature"
See merge request GNOME/gtk!2708
2020-10-25 01:10:01 +00:00
Matthias Clasen
434b145ee0
stack: Don't transition when the visible child is remove
...
This is a corner-case, and it is causing crashes in
the shortcuts window, after a11ab6c995 .
2020-10-24 20:54:55 -04:00
Matthias Clasen
2546b88661
a11y: Redo child-added/-removed for toplevels
...
Instead of monitoring the list of toplevels, rely
on GtkWindow updating the HIDDEN state before windows
get removed. This is better, since we still have the
object available when it happens, so we can pass it
to the ATs.
2020-10-24 15:26:12 -04:00
Matthias Clasen
bba6d604f0
window: Maintain accessible HIDDEN state
...
We want to use the HIDDEN state to control when
things get added and removed from the accessible
tree, so ensure that we a) set HIDDEN to true
initially for windows, and b) we update HIDDEN
when a window is shown or hidden.
The second part is handled by gtk_widget_hide
for other widgets, but hiding a window does not
always go through that code path.
2020-10-24 15:25:03 -04:00
Matthias Clasen
274f9ad919
a11y: Emit child notification when toplevels get hidden
...
When a toplevel window gets hidden (and not destroyed),
the frontend code set the HIDDEN state, and we need to
emit child notification when that happens.
2020-10-24 13:17:20 -04:00
Matthias Clasen
89a8c89663
a11y: Improve child index helpers
...
We need to use gtk_accessible_should_present() whenever we
calculate accessible tree positions, to avoid inconsistencies.
While we are at it, make these helpers usable for finding
the position of accesibles that are now ignored, by not
looking at should_present for the object itself. This will
be relevant when we calculate the position of objects whose
HIDDEN state changes.
2020-10-24 13:14:44 -04:00
Matthias Clasen
e7b290debb
a11y: Improve child notification for toplevels
...
We need to translate the list model position into
an accessible tree position, since hidden toplevels
will be skipped.
While we are at it, add an api for this notification
that will be used in the next commit.
2020-10-24 13:13:07 -04:00
Matthias Clasen
46e754a17d
a11y: Skip non-presented children when required
...
Whenever we determine the index of a child, we need
to skip its non-presented siblings.
2020-10-24 11:22:09 -04:00
Matthias Clasen
b12992c1cb
a11y: Handle HIDDEN state changes
...
Hidden elements are not presented in the accessible
tree, so when then HIDDEN state changes, we should
emit child-added or -removed signals.
This commit does not yet handle all cases (HIDDEN
toplevels or hidden stack pages are not handled),
but it should cover the common case.
2020-10-24 11:17:56 -04:00
Matthias Clasen
374a451eeb
a11y: Don't present HIDDEN accessibles
...
The ARIA spec is clear on this: when an element has the
HIDDEN state, it should not be presented in the accessible
tree.
This change is incomplete, we also need to emit child-added/
removed signals when the state changes, but that needs to
wait for the child added infrastructure to land.
2020-10-24 11:17:56 -04:00
Matthias Clasen
1e13acb206
widget: Don't add reordered children
...
gtk_widget_reposition_after is called both to add new children,
and to reposition existing children. We only want to emit
accessible changes in the former case (since AT-SPI doesn't
have events for reordering).
2020-10-24 11:17:56 -04:00
Matthias Clasen
5b2b2feb9f
a11y: Fix up state / change enum confusion
2020-10-24 11:17:56 -04:00
Matthias Clasen
77af993181
Merge branch 'flush-events' into 'master'
...
Flush events
See merge request GNOME/gtk!2740
2020-10-24 12:53:01 +00:00
Matthias Clasen
c5ed5c5ff9
gdk: Deliver queued events on flush
...
The current code was marking queued events as flushed,
but left them in the queue. That doesn't make sense to
me - we should deliver all events we have before we
reach the paint phase of the frame cycle.
2020-10-23 17:03:00 -04:00
Matthias Clasen
6b53a55dd7
NEWS: Updates
2020-10-23 15:07:25 -04:00
Matthias Clasen
83fbdcd5e6
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
Closes #3226
See merge request GNOME/gtk!2739
2020-10-23 17:25:33 +00:00
Matthias Clasen
cb8bf6540c
editablelabel: Properly clean up in dispose
...
Unparenting the stack finalizes the entry and label,
but at least the label is available via the
gtk_editable_get_delegate API, and the a11y
implementation uses that at dispose time. So, clear
the pointers to prevent them from being dangling.
This was showing up as a segfault of the doc-shooter.
2020-10-23 12:27:55 -04:00
Matthias Clasen
fdb1fa4d08
Give all search entries an icon
...
This was first requested for the search entry in
GtkDropDown, but it is better to be consistent and
give every search entry an icon.
Related: #3291
2020-10-23 12:19:31 -04:00
Matthias Clasen
10d7ccc8e0
window: Fix state updates
...
When the compositor unmaximized the window, we get a
state-changed signal, and we update the maximized field.
But then we go and recompute our layout based on the
maximize_initially field, and that is still TRUE, when
we were maximized initially. So we need to update both
fields.
This fixes a problem where using the window menu to
unmaximize an initially maximized window would not
work.
Fixes : #3226
2020-10-23 11:51:02 -04:00
Matthias Clasen
b973f7f375
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
See merge request GNOME/gtk!2737
2020-10-23 01:45:22 +00:00
Matthias Clasen
7671c1074b
Tweak focus tests
...
These tests are a bit fragile because the initial focus
that is taken depends on what ends up in the center of
the window, horizontally or vertically, which depends
on things like fonts, or theme spacing.
This commit makes some tweaks to push things in the
widget-factory example around far enough to make the
tests work again.
We should figure out a way to make this more robust.
2020-10-22 21:18:46 -04:00
Matthias Clasen
6ce2e19bbe
Merge branch 'ebassi/for-master' into 'master'
...
Ebassi/for master
See merge request GNOME/gtk!2735
2020-10-22 22:53:34 +00:00
Matthias Clasen
3a08706e40
dropdown: Add an icon the search entry
...
A small detail for #3291 .
2020-10-22 14:33:41 -04:00
Matthias Clasen
e5722fe9d2
passwordentry: Respect border spacing
...
We are not using a box layout here since we want
to ignore the icons for measuring. But we still
want the layout to respect border spacing that
comes from the theme.
2020-10-22 14:27:19 -04:00
Matthias Clasen
700f957d9a
Adwaita: Set border-spacing for entries
...
When our entries contain icons, they should not run
directly into the text, so put some spacing between
the children of entries.
2020-10-22 14:26:21 -04:00
Timm Bäder
9109dee072
gl renderer: Don't use blur node bounds
...
The blur node bounds are different/larger than the ones we use. This
made the textures get stretched to the blur node bounds.
Fixes #3282
2020-10-22 17:46:34 +02:00
Timm Bäder
b6a843a05b
gl renderer: Fix two scale_x/y mixups
2020-10-22 17:46:34 +02:00
Timm Bäder
ff1fb4f10d
text: Remove empty root() implementation
2020-10-22 17:46:34 +02:00
Timm Bäder
1bf79a4dae
text: Fix a documentation mishap
2020-10-22 17:46:34 +02:00
Timm Bäder
85d4b86545
text: Fold focus_{in,out} into only caller
2020-10-22 17:46:34 +02:00
Timm Bäder
98e88b7b53
text: Avoid a crash
...
Calculate the "was previous focus in a child widget" condition before
chaining up into grab_focus, to a void that unreffing the prev_focus
widget.
2020-10-22 17:46:34 +02:00
Timm Bäder
85702f8f5d
dnd demo: Make the transform code a bit more idiomatic
2020-10-22 17:46:34 +02:00
Timm Bäder
d97cb851f1
textview: Remove a broken debug output statement
...
redraw_rect does not exist.
2020-10-22 17:46:34 +02:00
Timm Bäder
6dcdb4a601
atspitextbuffer: Explicitly cast between pango and gtk enums
2020-10-22 17:46:34 +02:00
Timm Bäder
41ef1d87ef
atspicontext: Add a few missing break statements
2020-10-22 17:46:34 +02:00
Timm Bäder
44728d09a9
stack: assert for some assumptions
2020-10-22 17:46:34 +02:00
Timm Bäder
b1664534af
gdksurface: Ensure some assumptions
...
Just to please scan-build
2020-10-22 17:46:34 +02:00
Timm Bäder
56e89e8d26
demos: Remove a dead assignment
2020-10-22 17:46:34 +02:00
Timm Bäder
f6ebc06767
filechooserwidget: Avoid an uninitialized value
...
If the operation mode is OPERATION_MODE_RECENT and we end up in the
'goto file_entry' case, we don't set info.result. Then later after
calling check_save_entry, is_empty is TRUE which causes a goto out and
here we then try to use info.result, which is uninitialized.
Initialize info.result before doing all this.
Found by scan-build
2020-10-22 17:46:33 +02:00
Timm Bäder
3db5e15bde
filechooserwidget: gtk_widget_get_root() can return NULL
2020-10-22 17:46:33 +02:00
Timm Bäder
a2291fb989
showrendernode: Pass error to deserialize()
2020-10-22 17:46:33 +02:00
Timm Bäder
af97f19926
textview: Respect return value of get_text_surface_coords()
2020-10-22 17:46:33 +02:00
Timm Bäder
0dae1f48fd
listbox test: Only compare values for rows we have
...
This shouldn't happen, but don't compare 100 values if we didnt' get 100
values from the listbox.
2020-10-22 17:46:33 +02:00
Timm Bäder
c7dbb8ef91
label: Plug a potential memory leak
...
This only happens in error cases so pretty insignificant.
Found by scan-build
2020-10-22 17:46:33 +02:00
Timm Bäder
3a1e019e83
print-editor: Fix a wrong comparison
...
If error is NULL, replacing the file contents worked and we don't
show the error dialog. The previous version pretty explicitly
dereferenced a NULL pointer by first ensuring that error is NULL and
then accessing error->message.
Found by scan-build
2020-10-22 17:46:33 +02:00
Matthias Clasen
a923be95b3
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
See merge request GNOME/gtk!2736
2020-10-22 14:52:57 +00:00
Matthias Clasen
a11ab6c995
a11y: Handle stack case for addition/removal
...
Since we interpose stack pages as non-widget accessibles,
we need to tweak the signals we emit when their corresponding
widgets get added or removed.
2020-10-22 10:06:06 -04:00
Matthias Clasen
1d802881eb
stack: Change ordering for removal
...
Unparent the child widget before tearing down its
stack page. This is necessary so a11y can still access
the stack page accessible to emit change notification
when it learns that the child is removed.
2020-10-22 10:05:17 -04:00
Emmanuele Bassi
6c796cf201
docs: Fix cross-linking for GIO types
2020-10-22 13:33:49 +01:00
Matthias Clasen
44c6619660
gtk-demo: Speed up image demo
...
The progressive loading demo here was so slow as to appear
broken. Make it faster, and ensure that it updates regularly.
2020-10-22 07:51:44 -04:00
Matthias Clasen
ef7499a31b
gtk-demo: Add alternative text to a GtkPicture
...
This lets us text GtkPicture a11y support.
2020-10-22 07:51:44 -04:00
Matthias Clasen
ed571ae68a
picture: Set alternative text as description
...
Use the alternative text as accessible description
for GtkPicture.
2020-10-22 07:51:44 -04:00
Matthias Clasen
e2b3cbac23
colorbutton: Improve accessibility
...
Make the swatch not appear selectable, and
set an accessible label on it.
2020-10-22 07:51:44 -04:00
Matthias Clasen
ba290eb9b0
a11y: Add actions for color swatches
...
Add the same actions that we exported in GTK 3.
2020-10-21 23:36:22 -04:00
Matthias Clasen
3805e1d507
colorswatch: Export some functions for a11y
...
Make simple functions to activate, select or customize
a GtkColorSwatch. These will be exported by a11y as
actions.
2020-10-21 23:36:22 -04:00
Matthias Clasen
daf3b3a3b4
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
See merge request GNOME/gtk!2734
2020-10-22 02:52:46 +00:00
Matthias Clasen
800eb76a2d
linkbutton: Use the LINK role
...
It is a bit ambiguous, but I think link buttons are
more links than buttons. See WAI-ARIA for a discussion
of the differences.
Update tests to match.
2020-10-21 22:19:54 -04:00
Matthias Clasen
bcbc6159f4
a11y: Document abstract roles
...
Since we mention abstract roles in the documentation
for GtkAccessibleRole, we should say what roles are
abstract. Doing this shows that we actually use two
abstract roles heavily, ourselves: WIDGET and WINDOW.
2020-10-21 21:47:14 -04:00
Matthias Clasen
5f8c6d2287
a11y: Document roles used in menu
2020-10-21 21:40:19 -04:00
Matthias Clasen
88eb3a9c34
atspi: Give model buttons a click action too
...
GtkModelButton is no longer derived from GtkButton,
but can still treat it like a button for the purposes
of having a click action. This lets ATs activate
menu items again.
2020-10-21 21:27:38 -04:00
Matthias Clasen
3e43dda9d4
modelbutton: Recreate our AT context
...
When the button role changes, we want to update the
accessible role to match. Since accessible roles are
unchangeable post-creation of the AT context, we have
to cheat a bit and recreate the whole context.
2020-10-21 21:27:38 -04:00
Matthias Clasen
f96a1cfadd
modelbutton: Initial accessibility setup
...
Set the accessible role to GTK_ACCESSIBLE_ROLE_MENU_ITEM.
This is incomplete, we need to recreate the context when
the buttons role changes, and there are other things that
need to be set.
2020-10-21 21:27:38 -04:00
Matthias Clasen
758bcd5343
popovermenubar: Initial accessibility setup
...
Set roles, properties and relations according to the
ARIA authoring practices document. This is not quite
complete.
2020-10-21 21:27:38 -04:00
Matthias Clasen
2bfd4196fb
popovermenu: Initial accessibility setup
...
Set roles, properties and relations according to the
ARIA authoring practices document.
2020-10-21 21:27:38 -04:00
Xavier Claessens
1b7a99cb24
Apply 1 suggestion(s) to 1 file(s)
2020-10-22 00:36:23 +00:00
Matthias Clasen
087c0078ca
menubutton: initial accessibility setup
...
Set roles, properties and relations according to the
ARIA authoring practices document.
2020-10-21 19:47:48 -04:00
Matthias Clasen
b9ae54c951
separator: Remove unnecessary code
...
gtk_widget_update_orientation already sets the
accessible property, no need to do it again.
2020-10-21 19:47:48 -04:00
Emmanuele Bassi
7ac6e25ffc
Use GtkApplication in the examples
...
Some people read the "Getting Started" section as a series of
incremental lessons, and having the examples go from GtkApplication to
the old style "init / spin the main loop" confuses them.
We should be using GtkApplication everywhere in our examples.
2020-10-21 22:44:53 +01:00
Matthias Clasen
d3089ebbc2
progressbar: Hide internal structure from a11y
...
According to section 7.1 of WAI-ARIA, the progressbar role
has the "Children presentational" characteristic, which
indicates that children should not be represented in
the a11y tree.
2020-10-21 15:09:55 -04:00
Matthias Clasen
14a64c7372
levelbar: Hide internal structure from a11y
...
According to section 7.1 of WAI-ARIA, the meter role
has the "Children presentational" characteristic, which
indicates that children should not be represented in
the a11y tree.
2020-10-21 15:04:34 -04:00
Matthias Clasen
ca9b06878d
switch: Hide internal structure from a11y
...
According to section 7.1 of WAI-ARIA, the switch role
has the "Children presentational" characteristic, which
indicates that children should not be represented in
the a11y tree.
2020-10-21 14:55:13 -04:00
Matthias Clasen
8f100269ad
scale: Hide internal structure from a11y
...
According to section 7.1 of WAI-ARIA, the slider role
has the "Children presentational" characteristic, which
indicates that children should not be represented in
the a11y tree, which makes sense, since these are all
just internal gizmos.
2020-10-21 14:53:17 -04:00
Matthias Clasen
48bb9200d9
a11y: Treat PRESENTATION like NONE
...
This is what ARIA tells us to do. NONE is just another
name for PRESENTATION.
2020-10-21 14:40:34 -04:00
Matthias Clasen
d7794bf608
docs: Add some more to the migration guide
...
Expand the section on life-cycle handling with some
more details.
2020-10-21 14:30:17 -04:00
Matthias Clasen
3151906157
docs: Small corrections to the a11y overview
...
The section titles were mixed up wrt to the content
of the sections.
2020-10-21 14:23:10 -04:00
Matthias Clasen
6153efd02a
Document GTK_ACCESSIBLE_ROLE_NONE
...
We use it for a specific purpose now, so document it.
2020-10-21 14:21:12 -04:00
Matthias Clasen
b5b8f42a0c
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
Closes #3285
See merge request GNOME/gtk!2733
2020-10-21 18:09:42 +00:00
Matthias Clasen
043ffd38bc
text: React to text attribute changes in css
...
Recompute the layout when the css style change
affects text attributes. This matches what we do
in GtkLabel, and without this, changing the
font-features-setting css property in the Inspector
does not have immediate effect.
2020-10-21 13:46:58 -04:00
Carlos Garnacho
32b826e312
Merge branch 'wip/exalm/swipe4' into 'master'
...
gestureswipe: Count last event when calculating velocity
See merge request GNOME/gtk!2715
2020-10-21 16:20:58 +00:00
Alexander Mikhaylenko
700ca3b946
gestureswipe: Count last event when calculating velocity
...
The last event, matching lifting the finger/releasing the mouse button,
is important when there's a large delay between it and the previous events,
as in when performing a movement, stopping, then releasing fingers as
opposed to doing a swipe.
If this event is skipped, doing this will result in kinetic deceleration
matching the previous finger movement, while the expected behavior would
be no deceleration.
See also 5dc6194b98 for a similar fix in
GtkEventControllerScroll.
2020-10-21 20:59:15 +05:00
Emmanuele Bassi
e45dd771db
a11y: Emit ChildrenChanged for toplevel list changes
...
GtkAtSpiRoot is not a context, which means it needs to emit
ChildrenChanged events by itself whenever a toplevel is added to, or
removed from, the list of toplevels.
2020-10-21 15:37:57 +01:00
Emmanuele Bassi
698cbee1fb
a11y: Move ChildrenChanged emitter to ATSPI utilities
...
We are going to use it from GtkAtSpiRoot, which is not a
GtkAtSpiContext.
2020-10-21 15:18:23 +01:00
Emmanuele Bassi
80756322cd
a11y: Handle relations in UI files
...
A bit hacky: we skip parsing values that have a reference or
reference-list type, but we do not error out. Instead, we return a NULL
value, which we catch in the GtkBuildable interface implementation to
get the actual object, and construct a reference list value.
There's still some ickyness around the value type that can only be
solved by having an attribute and role taxonomy.
2020-10-21 14:48:49 +01:00
Emmanuele Bassi
f1e14c4858
a11y: Implement ChildrenChanged atspi.Event
2020-10-21 14:33:20 +01:00
Emmanuele Bassi
8d46bd1d7c
a11y: Notify of changes in the children list
2020-10-21 14:04:49 +01:00
Emmanuele Bassi
fbb08a30e2
a11y: Add child state change to GtkATContext
...
And the required private API in GtkAccessible to notify AT contexts of
changes in the children list.
2020-10-21 14:04:49 +01:00
Matthias Clasen
81371e7c79
columnview: Put overshoot underneath the headers
...
This matches what we do in GtkTreeView.
Fixes : #3285
2020-10-21 08:39:50 -04:00
Emmanuele Bassi
7702670d86
docs: Document the "accessibility" custom tag
2020-10-21 13:33:37 +01:00
Emmanuele Bassi
9e4316bf96
a11y: Add an "accessibility" section to the builder XML tree
...
Accessible attributes are not GObject properties. This means that we
need a custom parser for setting attributes in our UI description files.
The new section is defined as a sub-tree with the `<accessibility>`
element at its root, and elements for each type of accessible
attributes, i.e. properties, relations, and states:
```xml
<object class="..." id="...">
<accessibility>
<property name="label">The accessible label</property>
<state name="pressed">false</state>
<relation name="labelled-by">label1</relation>
</accessibility>
</object>
```
The name of the attribute is the enumeration value; the value is defined
by the WAI-ARIA specification.
2020-10-21 13:33:37 +01:00
Emmanuele Bassi
4ea2a6628f
a11y: Add parsing code for accessible values
...
We need to be able to go from a string representation of an accessible
value to its GtkAccessibleValue instance.
2020-10-21 13:33:37 +01:00
Matthias Clasen
39dfdac771
range: Hide internals from accessibility
...
The nameless, faceless gizmos inside a range do not
contribute to the accessible experience at all, lets
not add them to the tree. All the accessible functionality
is on the main widget (either a scale or a scrollbar).
2020-10-21 08:01:25 -04:00
Matthias Clasen
b7fa00e22d
Cosmetics
2020-10-21 08:01:25 -04:00
Matthias Clasen
3df0a333ad
frame: Set up accessible relations
...
Mark the child as labelled-by the label.
2020-10-21 08:01:25 -04:00
Matthias Clasen
8880e3bd2e
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
See merge request GNOME/gtk!2729
2020-10-21 11:43:58 +00:00
Timm Bäder
0b5b908a74
Merge branch 'wip/exalm/nullable' into 'master'
...
widget: Add missing (nullable) on binding functions
See merge request GNOME/gtk!2730
2020-10-21 08:17:45 +00:00
Alexander Mikhaylenko
31a072497d
widget: Add missing (nullable) on binding functions
...
Even though they are marked as (skip), they are used in Vala and have wrong
types there atm.
2020-10-21 12:27:51 +05:00
Matthias Clasen
cbb6828657
docs: Document more accessible roles
...
Document that GtkText is skipped in accessibility.
2020-10-20 23:19:30 -04:00
Matthias Clasen
8e170217a1
Cosmetics
...
Typo fix.
2020-10-20 23:19:18 -04:00
Matthias Clasen
36d4a8090f
docs: Document more accessible roles
...
GtkColumnView and its various components use a lot
of accessible roles.
2020-10-20 23:09:11 -04:00
Matthias Clasen
341244203f
docs: Document more accessible roles
...
GtkListView and GtkGridView were missing this as well.
2020-10-20 22:53:30 -04:00
Matthias Clasen
2023914186
docs: Document accessible roles of some classes
...
GtkListBox and GtkFlowBox were missing this.
2020-10-20 22:51:11 -04:00
Matthias Clasen
ef9ec43469
a11y: Add some more tests
2020-10-20 22:44:24 -04:00
Matthias Clasen
67411701c6
inspector: Show accessible object path
...
Show the object path of the object on the a11y bus,
this is can be useful information. While we are here,
make sure that the Inspector does not throw criticals
when used with GTK_NO_A11Y=1.
2020-10-20 21:56:54 -04:00
Matthias Clasen
e20a3339bf
atsi: Fix emission of text selection changes
...
We were not emitting text-selection-changed and
text-caret-moved as expected.
2020-10-20 21:31:23 -04:00
Matthias Clasen
a8baee342c
a11y: Fix handling of LABELLED_BY relation
...
There were several places where we were confusing
GList and GSList and list->data and list->next, causing
a crash in the accessible name computation for buttons
with mnemonic labels.
2020-10-20 21:27:39 -04:00
Matthias Clasen
6a1cb3304b
docs: Mention subclassing and destroy in the migration guide
...
Mention changes regarding subclassing and life-cycle
handling in the migration guide.
2020-10-20 18:26:38 -04:00
Benjamin Otte
45400fe381
Merge branch 'wip/otte/for-master' into 'master'
...
Wip/otte/for master
Closes #3280
See merge request GNOME/gtk!2725
2020-10-20 14:05:49 +00:00
Matthias Clasen
5504278b78
Merge branch 'matthiasc/for-master' into 'master'
...
Some more a11y tests
See merge request GNOME/gtk!2726
2020-10-20 05:57:45 +00:00
Matthias Clasen
93481e6c2e
a11y: Add tests for GtkFlowBox
...
Test that roles, states and properties are as expected.
2020-10-20 01:12:20 -04:00
Matthias Clasen
b9e9898212
a11y: Add tests for GtkListBox
...
Test that roles, states and properties are as expected.
2020-10-20 01:07:13 -04:00
Matthias Clasen
7c47b6907b
a11y: Add tests for GtkStack and GtkStackSwitcher
...
Test that the roles, states and relations are
as expected.
2020-10-20 00:46:07 -04:00
Matthias Clasen
b10d5ec8ff
a11y: Add a test for label properties
...
Now that we set the label property, we should test it too.
2020-10-20 00:25:39 -04:00
Benjamin Otte
8dad615f04
gtk: Remove unused header include
...
gtkcssnodeprivate.h was mainly used for repositioning CSS nodes in
gadgets, and gadgets are gone now.
2020-10-20 04:50:12 +02:00
Benjamin Otte
23e086089d
entry: Keep widget order
...
... instead of just ordering the CSS nodes.
2020-10-20 04:50:12 +02:00
Benjamin Otte
9317a9f35c
flowbox: Keep widget order
...
... instead of just ordering the CSS nodes.
2020-10-20 04:50:12 +02:00
Benjamin Otte
22100089c3
listbox: Reorder the widgets when sorting
...
... instead of just reordering the CSS nodes.
2020-10-20 04:50:12 +02:00
Benjamin Otte
074d54ef5a
listitemwidget: Remove unnecessary code
...
gtk_widget_insert_after() reorders CSS nodes properly.
2020-10-20 04:50:12 +02:00
Benjamin Otte
ddd1b0958d
notebook: Remove unnecessary code
...
gtk_widget_insert_after() reorders CSS nodes properly.
Also fix page reordering code to actually reorder the widget instead of
just the CSS nodes.
2020-10-20 04:50:12 +02:00
Benjamin Otte
d77902365d
box: Remove unnecessary code
...
gtk_widget_insert_after() reorders CSS nodes properly.
2020-10-20 04:50:12 +02:00
Benjamin Otte
d9b216e629
widget: Always update the CSS node
...
Anybody who keeps their own CSS nodes around or wants to order CSS nodes
different from widgets will from now on have to do it manually all the
time.
This is outdated behavior, nobody should be doing either of those two
things.
Also, the correct case is much more common, and not doing it
automatically was causing bugs.
Fixes #3280
2020-10-20 04:50:12 +02:00
Matthias Clasen
a7bd6b094a
Merge branch 'matthiasc/for-master' into 'master'
...
Some a11y docs and fixes
See merge request GNOME/gtk!2724
2020-10-20 01:45:17 +00:00
Matthias Clasen
eeae1b1ea7
a11y: Fix accessible tree inconsistency
...
The stack page objects were not properly integrated
in the accessible tree - they were appearing as parent
of the pages when navigating up, but not as children
of the stack when navigating down.
2020-10-19 21:15:44 -04:00
Matthias Clasen
0a71dc1bed
stack: Minor doc addition
2020-10-19 21:15:44 -04:00
Matthias Clasen
feb73a5ebb
docs: Flesh out a11y section
...
Add some advice for making custom widgets accessible.
2020-10-19 20:01:57 -04:00
Matthias Clasen
83d8ae2f30
Merge branch 'wip/chergert/fix-macos-surface-under-pointer' into 'master'
...
macos: fix discovery of surface under pointer
See merge request GNOME/gtk!2722
2020-10-19 21:26:47 +00:00
Emmanuele Bassi
51f5690ae3
Merge branch 'ebassi/for-master' into 'master'
...
Ebassi/for master
See merge request GNOME/gtk!2720
2020-10-19 20:26:57 +00:00
Matthias Clasen
e58e6a0fbe
Merge branch 'a11y/editable' into 'master'
...
Improve the accessible support for editables
See merge request GNOME/gtk!2719
2020-10-19 20:16:21 +00:00
Christian Hergert
eb82b2a9ca
macos: fix discovery of surface under pointer
2020-10-19 12:35:41 -07:00
Matthias Clasen
dfc7d26275
a11y: Tweak name and description computation
...
Instead of falling back to the role nick for both,
fall back to the class name for the name, and to
the empty string for the description. This makes
labels show up in Accerciser the same way they
did in GTK 3, and seems more useful to me than
the alternative.
2020-10-19 14:58:34 -04:00
Matthias Clasen
77d1026c5a
atspi: Use name and description as provided
...
GtkATContext already does fallbacks to derive values
for these, so no need for the atspi implementation to
do its own fallback on top of that.
2020-10-19 14:57:43 -04:00
Matthias Clasen
08ae513064
label: Set the accessible label property
...
This will make label text show up in ATs again.
2020-10-19 14:29:19 -04:00
Emmanuele Bassi
f52c86ae21
docs: Add a section on a11y patterns
2020-10-19 18:39:40 +01:00
Emmanuele Bassi
03745a489c
docs: Start outlining a11y authoring practices
...
We should have documentation for application developers and widget
authors, so they can deal with the new accessibility API.
2020-10-19 18:37:30 +01:00
Matthias Clasen
63421b1876
a11y: Rename some methods
...
Our EditableText implementation works fine for any
editable, so don't name the functions in a way that
looks like they are only for entries.
2020-10-19 12:58:29 -04:00
Matthias Clasen
80e0e3fe4f
gtk-demo: Set an accessible role
...
Set the expected accessible role on the tagged entry
widget in the demo of the same name. Accessible tools
may decide to ignore widgets that have the wrong role,
so setting an appropriate role is important.
2020-10-19 12:56:50 -04:00
Matthias Clasen
ef46fe0e8e
Merge branch 'a11y/component' into 'master'
...
a11y: Implement Component
See merge request GNOME/gtk!2718
2020-10-19 16:54:45 +00:00
Emmanuele Bassi
7c7dabae8c
a11y: Rework accessible name/description computation
...
The ARIA spec determines the name and description of accessible elements
in a more complex way that simply mapping to a single property; instead,
it will chain up multiple definitions (if it finds them). For instance,
let's assume we have a button that saves a file selected from a file
selection widget; the widgets have the following attributes:
- the file selection widget has a "label" attribute set to the
selected file, e.g. "Final paper.pdf"
- the "download" button has a "label" attribute set to the
"Download" string
- the "download" button has a "labelled-by" attribute set to
reference the file selection widget
The ARIA spec says that the accessible name of the "Download" button
should be computed as "Download Final paper.pdf".
The algorithm defined in section 4.3 of the WAI-ARIA specification
applies to both accessible names (using the "label" and "labelled-by"
attributes), and to accessible descriptions (using the "description" and
"described-by" attributes).
2020-10-19 17:54:14 +01:00
Matthias Clasen
9f9e7dffef
atspi: Implement Text for more editables
...
Our Text implementation requires that we have
a GtkEditable with a delegate that is a GtkText
widget.
This change make the Text implementation work for
the custom widget in the tagged entry demo.
2020-10-19 12:44:50 -04:00
Goran Vidović
94729b4880
Update Croatian translation
...
(cherry picked from commit fab2558747 )
2020-10-19 16:37:36 +00:00
Matthias Clasen
3918dd4643
Add gtk_editable_get_delegate
...
We need access to the delegate in the a11y layer,
so we might as well make this function public.
2020-10-19 12:36:54 -04:00
Matthias Clasen
04a51837f7
atspi: Emit bounds-changed
...
This is using the new bounds_change vfunc in GtkATContext.
2020-10-19 12:19:55 -04:00
Matthias Clasen
75a0bef921
widget: Mark the size as changed when it changes
...
This notifies the AT context that the widgets size
has changed.
2020-10-19 12:19:55 -04:00
Matthias Clasen
d50ebd947c
a11y: Add bounds change api
...
Add a way for GTK to pass bounds change information
to the AT context.
2020-10-19 12:19:55 -04:00
Matthias Clasen
8e4f8a45a9
atspi: Implement Component
...
Implement the non-questionable parts of the Component interface
for accessibles which are widgets.
This does not include:
- global coordinates
- setters
- scrolling
- alpha, layers, zorder, and the like
2020-10-19 12:19:55 -04:00
Matthias Clasen
3ad03b1706
a11y: Add a separate vfunc for platform changes
...
The state_change vfunc is becoming unwieldy. Lets move
the platform changes to their own vfunc, as a start.
2020-10-19 12:09:08 -04:00
Matthias Clasen
dfe00c4ac4
atspi: Be more careful
...
We have non-widget accessibles now, so guard against
change notification being emitted on them.
2020-10-19 12:09:08 -04:00
Matthias Clasen
5bb656af4c
Cosmetics
...
Add some more fold markers.
2020-10-19 12:08:47 -04:00
Matthias Clasen
469b913cdf
Cosmetics
2020-10-19 12:00:53 -04:00
Matthias Clasen
9c1c8a554a
Cosmetics
2020-10-19 11:46:25 -04:00
Matthias Clasen
2359510b1f
Merge branch 'matthiasc/for-master' into 'master'
...
Various columnview fixes
Closes #3265 , #3272 , and #3276
See merge request GNOME/gtk!2717
2020-10-19 15:00:17 +00:00
Xavier Claessens
25a1c421b5
Merge branch 'msvc' into 'master'
...
gdkglcontext: Fix build with MSVC
Closes #3268
See merge request GNOME/gtk!2713
2020-10-19 13:46:54 +00:00
Matthias Clasen
ef308e5f17
Merge branch 'annotations_gtkaboutdialog' into 'master'
...
Add nullable return annotations in GtkAboutDialog
See merge request GNOME/gtk!2712
2020-10-19 13:46:32 +00:00
Sophie Herold
33f0809784
Add nullable return annotations in GtkAboutDialog
2020-10-19 13:46:32 +00:00
Matthias Clasen
81ee273e98
columnview: Make right-aligned content work
...
Make right-aligned content work in resized columns.
There is currently no way to make a title right-aligned,
but we can still make it work correctly. This is a follow
up to 7eb0ae39c5 .
Fixes : #3276
2020-10-19 09:39:07 -04:00
Matthias Clasen
f3fe1812aa
Adwaita: Put column separators on the left
...
When resizing columns, we clip a shrunk column
on the right, so the separator disappears in that
case unless we put it on the left side of the other
column.
2020-10-19 09:39:05 -04:00
Xavier Claessens
be8246a6cb
gdkglcontext: Fix build with MSVC
...
GLDEBUGPROC callback is defined with APIENTRY which is a windows
specific calling convention. That macro expands to nothing when building
on other platforms.
Fixes : #3268 .
2020-10-19 09:17:53 -04:00
Matthias Clasen
25d0fb4c76
columview: Make resize area a bit larger
...
This make column resizing feel less like a game
of hit-and-miss. Ultimatively, we should add an
alternative to this.
2020-10-19 08:31:37 -04:00
Matthias Clasen
98b66acbdd
columview: Implement double-click to reset headers
...
Implement the same behavior as GtkTreeView:
double-click on the header boundary resets the
header to its automatic width.
Fixes : #3272
2020-10-19 08:31:37 -04:00
Matthias Clasen
1976df1e54
columnview: Make resize cursors reliable
...
Ensure that the column resize cursor stays in place
for the duration of the resize drag. This is a bit
annoying, since the implicit grab can end up on the
header of a different column from the one we are
resizing, so just set the cursor on all column headers.
2020-10-19 08:30:22 -04:00
Matthias Clasen
39baf4fff4
columnview: Fix more issues with column resizing
...
Make it so that for overlapping resize rectangles (with
very narrow columns), we prefer the narrow column, so you
can regrow a column after shrinking it all the way.
Related: #3274
2020-10-19 08:30:05 -04:00
Matthias Clasen
a88e5a5f4e
columnview: Fix some issues with column resizing
...
Ensure that we place the resize rectangle at the visible
right edge of the column, not where the allocation ends
(we clip the header drawing, after all).
Related: #3274
2020-10-19 08:29:29 -04:00
Matthias Clasen
a39e519bed
inspector: Clear overlays on unroot
...
In dispose(), we can't access the root anymore,
since we're already unrooted.
Fixes : #3265
2020-10-17 13:11:58 -04:00
Emmanuele Bassi
e9eb385f25
Merge branch 'patch-1' into 'master'
...
Add some missing nullable return annotations
See merge request GNOME/gtk!2707
2020-10-17 14:08:29 +00:00
Xavier Claessens
a4aa6d79ad
meson: Use feature options for media and print backends
...
This gracefully disable ffmpeg, gstreamer, cups and cloudprint optional
dependencies when they are not available, while still giving full
control to distributors using -Dauto_features=enabled.
2020-10-17 09:54:47 -04:00
Xavier Claessens
ea3933b87a
meson: Make vulkan and xinerama optional deps default to 'auto'
...
It is nicer for contributors to have a build that works by default.
Distributors should be using -Dauto_features=enabled to get ride of
automagic options.
2020-10-17 09:54:47 -04:00
Xavier Claessens
6ae9f7e7c3
meson: Simplify xinerama dependency check
2020-10-17 09:54:47 -04:00
Xavier Claessens
efbbfb6547
meson: Simplify how cairo dependencies are checked
...
There is no reason to fallback to find_library for cairo and still rely
on pkg-config for all other dependencies, and just when using MSVC. When
building and pkg-config is not working it is preferable to fallback to a
subproject just like for all other dependencies.
Also add cairo.wrap now that meson support has been merged upstream.
2020-10-17 09:54:47 -04:00
Sophie Herold
cd0bef9390
Add some missing nullable return annotations
2020-10-17 15:32:36 +02:00
Matthias Clasen
5a79cc4d70
Merge branch 'wip/chergert/fix-macos-fps-calculation' into 'master'
...
macos: fix fps calculation for frame timings
See merge request GNOME/gtk!2705
2020-10-17 12:20:04 +00:00
Piotr Drąg
954855783a
Update POTFILES.in
2020-10-17 11:11:24 +02:00
Christian Hergert
7ae8ed82c9
macos: fix fps calculation for frame timings
...
We need to mark the timings as complete after adding the
presentation time so that we have a valid FPS for the overlay
widget and/or fishbowl demo.
2020-10-15 21:04:51 -07:00
Matthias Clasen
1021e12121
3.99.3
2020-10-15 23:03:03 -04:00
Matthias Clasen
5833e8afa6
Merge branch 'win32.modal' into 'master'
...
GDK/Win32: Fix modal window handling and window stacking (for GTK4)
See merge request GNOME/gtk!2675
2020-10-16 03:01:38 +00:00
Matthias Clasen
34625142f4
docs: Expand opacity docs
...
Explain the situation with popovers and opacity.
Fixes : #3246
2020-10-15 22:39:01 -04:00
Matthias Clasen
6cbf1d0379
Merge branch 'a11y-action-fixes' into 'master'
...
A11y action fixes
See merge request GNOME/gtk!2703
2020-10-16 02:19:08 +00:00
Chun-wei Fan
2cc650ced2
gdk/Win32: Fix mouse pointer capture
...
Call SetCapture() explcitly for the (new) modal window so that we make the
modal window respond to mouse input, and also call SetCapture() to the parent
of the transient window that we are destroying so that mouse input capture is
returned to the parent window.
This attempts to fix the following:
* Upon creating a new modal window, the new modal window does not receive
pointer input unless one switches to another program and back
* Upon closing a transient window, the parent window that activated the
transient window does not receive pointer input unless one switches to
another and back
2020-10-16 10:03:50 +08:00
Matthias Clasen
7165deb630
Merge branch 'fix-listbox-selection' into 'master'
...
Revert "listbox: Activate single-click rows if n_press >= 1"
Closes #3263
See merge request GNOME/gtk!2704
2020-10-16 02:03:16 +00:00
Руслан Ижбулатов
6a0c181886
GDK W32: Remove stacking functions
...
Stacking functions enforce non-native stacking behaviour that is
mostly unneeded, and doing so introduces bugs and complicates things.
2020-10-16 10:02:57 +08:00
Руслан Ижбулатов
89286af620
Revert "GDK W32: Use SWP_NOOWNERZORDER everywhere it can be applied"
...
This reverts commit fc2008f2 .
Turns out, we *don't* have code to maintain Z-order. Restacking
code is not doint that, it just enforces a few weird Z-order-related
behaviours.
2020-10-16 10:01:46 +08:00
Chun-wei Fan
bc142b9c43
GDK/Win32: Fix modal window handling
...
Make sure that we get the state of the modal window properly, and send out the
corresponding notification signals.
This will ensure that we do not try to activate windows that should have become
inactivated due to it opening modal windows and render the program unresponsive
because we are not activating the correct window that is due to receive user
input.
2020-10-16 09:56:42 +08:00
Matthias Clasen
8eb6e876bd
Revert "listbox: Activate single-click rows if n_press >= 1"
...
This reverts commit e669433cde .
This broke selection in several listbox examples.
Fixes : #3263
2020-10-15 21:46:58 -04:00
Matthias Clasen
ab61b7b9ae
atspi: Properly filter out parent actions
...
We only want to show relevant, local actions for
widgets, but _gtk_widget_get_action_muxer() will
return the muxer of a parent widget (all the way
up to the toplevel), if the widget does not have
any actions of its own. To detect this situation,
compare what _gtk_widget_get_action_muxer() returns
for the parent widget, and act accordingly.
2020-10-15 21:32:11 -04:00
Matthias Clasen
3eae91255d
atspi: Fix a thinko in action filtering
...
get_action_at_index() was trying hard to find out
which actions are valid, only to then return the
invalid ones anyway.
2020-10-15 21:31:58 -04:00
Matthias Clasen
5bbacc647c
Merge branch 'a11y/atspi-action' into 'master'
...
A11y/atspi action
See merge request GNOME/gtk!2699
2020-10-16 00:13:23 +00:00
Emmanuele Bassi
cfb327974b
a11y: Add atspi.Action for GtkPasswordEntry
2020-10-16 00:34:01 +01:00
Emmanuele Bassi
a83d3078c2
Allow toggling the password entry visibility programmatically
...
We are going to need a method for toggling the visibility from the
accessibility layer.
2020-10-16 00:34:01 +01:00
Emmanuele Bassi
f67345eb55
a11y: Add atspi.Action for GtkEntry
...
We need to handle the activation on the entry widget, as well as the
activation of the primary and secondary icons.
2020-10-16 00:34:01 +01:00
Emmanuele Bassi
c10bcf0a60
Add GtkEntry icon signals emitter
...
We need a (private) way to programmatically trigger the activation of
the entry's icons, so that we can call it from the accessibility layer.
2020-10-16 00:34:01 +01:00
Emmanuele Bassi
9ae08fc0f0
a11y: Add atspi.Action for GtkExpander
2020-10-16 00:34:01 +01:00
Emmanuele Bassi
5f1128899c
a11y: De-duplicate some action code
...
The widgets with hard coded actions should share more code, instead of
copy-pasting it.
2020-10-16 00:34:01 +01:00
Emmanuele Bassi
e44f27a7ed
a11y: Special case buttons and switches
...
These widgets have specific actions.
2020-10-16 00:34:01 +01:00
Emmanuele Bassi
374bd21340
Initial ATSPI Action implementation for widget
...
Use the actions from the GtkActionMuxer of each widget to populate the
list of actions available.
2020-10-16 00:34:01 +01:00
Matthias Clasen
916ef485d1
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
Closes #3245
See merge request GNOME/gtk!2702
2020-10-15 21:00:44 +00:00
Matthias Clasen
92585b75fa
Fix compiler warnings
2020-10-15 16:33:35 -04:00
Matthias Clasen
4bd2595421
actionmuxer: Make it possible to enumerate local actions
...
This will be useful for exposing actions via the
AT-SPI Actions interface.
Update all callers.
2020-10-15 16:32:55 -04:00
Matthias Clasen
aa4c0bf272
spinbutton: Hide the buttons from accessibility
...
The buttons here are not really buttons (the action
is not tied to the "clicked" signal), so triggering
the buttons via a11y does not have the expected effect.
And we expose the Value interface that ATs can use
to set the value.
2020-10-15 16:32:55 -04:00
Matthias Clasen
4e04c39609
emojicompletion: Avoid a memory overrun
...
Don't read beyond the beginning of the string.
Fixes : #3245
2020-10-15 16:32:55 -04:00
Matthias Clasen
0bd5a96d71
gtk-demo: Fix some issues with the multi view demo
...
The nested window was not modal, causing it to be
inoperable. And the nested views within were all
shrunk down to nothingness. Give them some width.
Fixes : #3257
2020-10-15 14:42:43 -04:00
Matthias Clasen
7d22616a0e
Merge branch 'a11y-list-view-selection-fixes' into 'master'
...
atspi: Add fold markers
See merge request GNOME/gtk!2701
2020-10-15 17:36:47 +00:00
Matthias Clasen
8a14f019d0
atspi: Add fold markers
...
This makes it much easier to navigate in these
multi-implementation files.
2020-10-15 13:14:56 -04:00
Matthias Clasen
329efee643
Merge branch 'a11y-list-view-selection-fixes' into 'master'
...
A11y list view selection fixes
See merge request GNOME/gtk!2700
2020-10-15 17:10:00 +00:00
Matthias Clasen
bf58b6f88c
Merge branch 'ebassi/for-master' into 'master'
...
GdkWayland API cleanups
Closes #3249
See merge request GNOME/gtk!2688
2020-10-15 16:55:19 +00:00
Matthias Clasen
8701e65635
atspi: Implement Selection more correctly
...
The Selection interface is defined in terms of child
positions, so we need to always translate from that
to model positions if we want to use the selection
model apis.
2020-10-15 12:46:52 -04:00
Matthias Clasen
5f22ad8848
Remove debug spew
2020-10-15 12:19:58 -04:00
Matthias Clasen
1d40f29776
wayland: Make gdk_wayland_device_pad_set_feedback private
...
It is not a generally useful api, and awkwardly named.
2020-10-15 12:00:00 -04:00
Matthias Clasen
6d1dcaa92a
docs: Explain the symbolic icon paintable situation
...
Add a paragraph to the migration guide that explains
how to properly render symbolic GtkIconPaintables.
Also mention this in the GtkIconPaintable docs.
There's a reason you can't spell 'paintable' without
'pain'...
2020-10-15 11:42:50 -04:00
Matthias Clasen
9c28ecb0da
Merge branch 'a11y/atspi' into 'master'
...
A11y/atspi
See merge request GNOME/gtk!2698
2020-10-15 14:59:24 +00:00
Matthias Clasen
2488d71a0a
Merge branch 'clipboard-emo' into 'master'
...
gtk-demo: Fix up image handling in the clipboard demo
Closes #3252
See merge request GNOME/gtk!2697
2020-10-15 14:50:54 +00:00
Matthias Clasen
5c8663e383
Merge branch 'wip/wayland-dont-respond-to-destroyed-surface-configure' into 'master'
...
wayland/surface: Clear has_uncommitted_ack_configure when hiding
Closes #3262
See merge request GNOME/gtk!2696
2020-10-15 14:25:55 +00:00
Matthias Clasen
4b36bceb26
Merge branch 'meson-epoxy-subproject' into 'master'
...
meson: Fix error when epoxy is a subproject on Windows
See merge request GNOME/gtk!2695
2020-10-15 13:41:47 +00:00
Matthias Clasen
8cf955731f
gtk-demo: Fix up image handling in the clipboard demo
...
Using GtkIconPaintable+GtkPicture is not good for symbolic
icons - they don't get properly colored that way. So change
things around to use the icon name if we have it.
Fixes : #3252
2020-10-15 09:19:17 -04:00
Jonas Ådahl
7dfb25f124
wayland/surface: Clear has_uncommitted_ack_configure when hiding
...
The 'has_uncommitted_ack_configure' state was added to make sure we're
responding to 'xdg_surface.configure' events with
'xdg_surface.ack_configure' requests, as is necessary according to spec.
What we didn't do was to clear this state when hiding, meaning that if
we hid the surface after a configure event, but before the frame
finished and we processed the 'has_uncommitted_ack_configure', we'd try
to acknowledge the surface configuration after having destroyed the
surface.
Closes : #3262
2020-10-15 14:56:06 +02:00
Matthias Clasen
8737692b2b
atspi: Implement Selection for list views
...
This implementation works for both GtkListView and
GtkGridView, and by extension, also for GtkColumnView
and GtkDropDown, since those just use a list view
internally.
2020-10-15 08:35:06 -04:00
Xavier Claessens
fe89fd2317
meson: Fix error when epoxy is a subproject on Windows
...
epoxy_dep cannot be used in a configure time check when it comes from a
subproject. Use variables set in pc file instead.
This requires https://github.com/anholt/libepoxy/pull/231 .
2020-10-15 08:01:16 -04:00
Matthias Clasen
c7bf33a3de
columnview: Set accessible roles
...
Use the TREE_GRID, ROW, COLUMN_HEADER and GRID_CELL roles
for the various widgets involved in a GtkColumnView. To
enable this, we subclass GtkListView for the internal
list in the column view.
2020-10-15 00:16:25 -04:00
Matthias Clasen
6d562b6176
listview: Set accessible roles
...
Use the LIST and LIST_ITEM roles for GtkListView
and its children. Use the GRID and GRID_CELL roles
for GtkGridView and its children.
2020-10-14 23:34:51 -04:00
Matthias Clasen
1bf21d3dba
Document accessible roles for stacks and notebooks
...
This was forgotten when I implemented the Tabs pattern.
2020-10-14 22:27:09 -04:00
Matthias Clasen
14640cec85
flowbox: Set accessible roles
...
Use the GRID and GRID_CELL roles for GtkFlowBox
and GtkFlowBoxChild.
2020-10-14 22:20:43 -04:00
Matthias Clasen
147868a30c
listbox: Set accessible roles
...
Use the LIST and LIST_ITEM roles for GtkListBox
and GtkListBoxRow.
2020-10-14 22:18:21 -04:00
Matthias Clasen
57ebc351a9
Merge branch 'wip/chergert/fix-macos-popup-events' into 'master'
...
macos: fix popup motion and button event delivery
See merge request GNOME/gtk!2694
2020-10-15 01:41:42 +00:00
Matthias Clasen
375bd5e691
Merge branch 'wip/chergert/gdk-macos-fixes' into 'master'
...
macos: fix crash when displaying a context menu
See merge request GNOME/gtk!2693
2020-10-15 01:41:06 +00:00
Matthias Clasen
f4f732694a
atspi: Add some docs
...
Add a comment that explains a few of the more subtle
points of the Atspi context tree contstruction.
2020-10-14 21:04:25 -04:00
Matthias Clasen
bf04beb711
atspi: Implement Selection for notebook tabs
...
This is a bit different from the way things were done
in GTK 3 - we follow what was done for GtkStackSwitcher,
and make the tab bar carry the GTK_ACCESSIBLE_TAB_LIST
role, and implement Selection there.
2020-10-14 21:04:25 -04:00
Matthias Clasen
08b586bb57
notebook: Set accessible roles and properties
...
Set up the necessary roles, relations and properties
for the tab patterns. This parallels what we have done
for GtkStackSwitcher, and implements the Tabs pattern
as described in the ARIA authoring guidelines.
2020-10-14 21:04:25 -04:00
Matthias Clasen
41d4c37563
atspi: Don't crash on unnamed stack pages
...
GtkNotebook creates unnamed stack pages, and we should
not crash when that happens.
2020-10-14 21:04:25 -04:00
Matthias Clasen
984e8ac5e3
gizmo: Add a way to set accessible role
...
This will be used for some of the gizmo used
inside GtkNotebook.
2020-10-14 21:04:25 -04:00
Matthias Clasen
512387afcc
atspi: Implement Selection for GtkStackSwitcher
2020-10-14 21:04:25 -04:00
Matthias Clasen
b39684b692
stackswitcher: Set up relations and states
...
Set up a CONTROLS relation between each tab button
and its page, and update the SELECTED property of
the buttons to match their active state.
2020-10-14 21:04:25 -04:00
Matthias Clasen
380488f829
stackswitcher: Use the tablist and tab roles
...
Set the tablist role on the stackswitcher itself, and
the tab role on the buttons. This is another step towards
implementing the tabs pattern for GtkStack.
2020-10-14 21:04:25 -04:00
Matthias Clasen
2370429752
accessible: Avoid realizing the context prematurely
...
platform change is called from gtk_widget_set_focusable
which is likely to be called early on in init(). We don't
want to create an AT context that early if we can help
it, e.g. since it makes it impossible to override the
accessible-role with a construct property.
2020-10-14 21:04:25 -04:00
Matthias Clasen
7c6c718e19
stack: Turn pages into accessibles
...
This requires some cleanup to remove assumptions
about accessibles being widgets in the backend,
and some code to navigate the tree with these
extra objects in between widgets.
The accessibles for stack pages have the role
GTK_ACCESSIBLE_ROLE_TAB_PANEL. This is the first
step towards implementing the tabs patterns
as described in the aria authoring guidelines
for GtkStack.
2020-10-14 21:04:17 -04:00
Christian Hergert
6e84c7c59e
macos: fix discover of surface under cursor
...
This was incorrectly reporting the toplevel surface instead of the
popup surface that was placed above it. This fixes event delivery
to popups for selecting menu items and more.
2020-10-14 16:59:38 -07:00
Christian Hergert
0af3d21573
macos: only emit popup-layout-changed after initial present
...
Otherwise we risk being re-entrant where GtkPopover will not have a
GdkPopupLayout causing other issues.
2020-10-14 16:28:44 -07:00
Christian Hergert
e089bba4f5
macos: ensure we have access to a GdkMonitor
2020-10-14 16:28:44 -07:00
Matthias Clasen
2dfced7edc
Merge branch 'wip/chergert/gdk-macos-fixes' into 'master'
...
macos: fix button release events outside of window during grabs
See merge request GNOME/gtk!2692
2020-10-14 23:04:03 +00:00
Christian Hergert
b462bc35c0
macos: allow pointer release event outside surface coords
...
This helps with grab situations so that we can end it when releasing
the pointer buttons outside of the window coordinates.
2020-10-14 15:45:50 -07:00
Christian Hergert
d700cfa2ef
macos: break grabs after sending release event
2020-10-14 15:45:50 -07:00
Christian Hergert
cdb2c1698c
macos: dont send crossing events during grab
...
Fixes an issue where we can't drag scrollbars or text selections while
outside of the application window.
2020-10-14 15:45:50 -07:00
Matthias Clasen
85394b04e0
Merge branch 'wip/chergert/gdk-macos-fixes' into 'master'
...
GTK4: fix macos device state query for surfaces
See merge request GNOME/gtk!2690
2020-10-14 19:10:11 +00:00
Matthias Clasen
a772d8fcac
Merge branch 'wip/baedert/for-master'
...
Leaving out the gboolean -> bool change.
2020-10-14 15:07:09 -04:00
Timm Bäder
f93784f9e7
pixbufutils: Pass calculated height value along
2020-10-14 15:06:13 -04:00
Timm Bäder
d695b15f1a
main: Make sure we don't leak axes
...
Mainly a change to appease the static analyzer
2020-10-14 15:06:13 -04:00
Timm Bäder
e1e53cd8cc
infobar: Remove unused include
2020-10-14 15:06:12 -04:00
Timm Bäder
211d669ae7
overlay: Remove empty finalize implementation
2020-10-14 15:06:12 -04:00
Timm Bäder
20bd8e56ee
gtk4-demo: Add missing margin-bottom
...
This was setting margin-end twice
2020-10-14 15:06:12 -04:00
Timm Bäder
df2d7c56c7
gtk4-demo: Remove connection to removed signal
2020-10-14 15:06:12 -04:00
Timm Bäder
8f24b7ad27
stacksidebar: Fold some functions into their only callers
2020-10-14 15:06:12 -04:00
Timm Bäder
61afb0984c
stacksidebar: Set GtkListBox:show-separators
...
Instead of doing this ourselves
2020-10-14 15:06:12 -04:00
Timm Bäder
93b12a8110
frame: Remove need_resize logic
...
gtk_widget_set_parent() will queue a resize anyway.
2020-10-14 15:06:12 -04:00
Timm Bäder
d9cc589339
windowcontrols: gtk_widget_get_root() can return NULL
2020-10-14 15:06:12 -04:00
Timm Bäder
557a363b4f
windowcontrols: decoration-layout is nullable
2020-10-14 15:06:12 -04:00
Timm Bäder
ae009b344f
stylecontext: Remove some unnused includes
2020-10-14 15:06:12 -04:00
Timm Bäder
78c343ba96
snapshot: Refactor some device code
...
Make a bit clearer what this does.
2020-10-14 15:06:12 -04:00
Timm Bäder
eca3eab96f
Remove unneeded gtkstylecontext.h includes
2020-10-14 15:06:12 -04:00
Timm Bäder
2bcef7f030
stylecontext: Remove render_insertion_cursor()
...
This is unused and there already is a snapshot alternative.
2020-10-14 15:06:12 -04:00
Timm Bäder
18c4bdad6f
widget: Remove gtk_widget_list_devices() from private header
2020-10-14 15:06:12 -04:00
Timm Bäder
f20795471c
window: Remove unused struct member
2020-10-14 15:06:12 -04:00
Timm Bäder
ec8f329332
widget: Slightly update opacity docs
2020-10-14 15:06:12 -04:00
Timm Bäder
07fb33c033
gl renderer: Fix private function name
...
It's a GskGLRenderer, not a GskGLRender
2020-10-14 15:06:12 -04:00
Timm Bäder
1fe7043be4
gl renderer: Add more scale_x/scale_y code
...
We really need all of this to be aware of both dimensions of course...
2020-10-14 15:06:12 -04:00
Timm Bäder
0e6014f2f6
gl renderer: Remove two unused uniforms
2020-10-14 15:06:12 -04:00
Timm Bäder
0a4d442849
gl renderer: return empty texture for too small blurred nodes
2020-10-14 15:06:12 -04:00
Timm Bäder
5f9fa13c65
gl renderer: Use op builder to render flipped texture
...
Otherwise, we don't know about the uniform state
2020-10-14 15:06:12 -04:00
Timm Bäder
da0abfce3a
showrendernode: Plug GOptionContext memory leak
2020-10-14 15:06:12 -04:00
Timm Bäder
161b171004
gl renderer: Remove unused parameter
2020-10-14 15:06:12 -04:00
Timm Bäder
4eee6e732b
filechooserwidget: Cosmetics
2020-10-14 15:06:12 -04:00
Timm Bäder
958e4be86d
testfilechooser: Stop listening to ::selection-changed
...
Doesn't exist anymore.
2020-10-14 15:06:12 -04:00
Timm Bäder
eb345cd033
gl renderer: Use nearest filtering for textures in render_texture()
...
Makes the output in the node editor a bit more bearable.
2020-10-14 15:06:12 -04:00
Timm Bäder
ef7c5747c4
build: Only add -Wcast-align for gcc
...
Either we or clang needs to get its shit together about this warning.
But using it during development with clang just makes actually usable
warnings get lost in a flood of -Wcast-align warnings.
2020-10-14 15:06:12 -04:00
Timm Bäder
f456438051
vulkan: Remove double initialization
...
Clang said:
../gsk/vulkan/gskvulkanrenderpass.c:250:5: warning: initializer overrides prior initialization of this subobject [-Winitializer-overrides]
.render.node = node
^~~~~~~~~~~~~~~~~~~
../gsk/vulkan/gskvulkanrenderpass.c:249:13: note: previous initialization is here
.type = GSK_VULKAN_OP_FALLBACK,
^~~~~~~~~~~~~~~~~~~~~~
2020-10-14 15:06:12 -04:00
Timm Bäder
4735c27e69
gl renderer: Avoid some code duplication
2020-10-14 15:06:12 -04:00
Timm Bäder
44f10c5861
gl renderer: Flip texture in render_texture()
2020-10-14 15:06:12 -04:00
Timm Bäder
44d1e81ae9
glsl: Add a comment
2020-10-14 15:06:12 -04:00
Timm Bäder
c5909d4dc4
gtkbuilder: Remove pointless function prototype
2020-10-14 15:06:12 -04:00
Timm Bäder
9698cd67a1
gdkgl: Remove flipping when downloading GL texture
...
This fix is correct and fixes:
1) GL textures being upside down in the inspector. They are getting
downloaded because they've been created in a different GL context
2) GL textures being upside down in the cairo renderer (same reason)
However, it breaks the testsuite. We do the flipping via the projection
matrix, but most of the shaders don't care about that.
2020-10-14 15:06:12 -04:00
Timm Bäder
d4efb5b738
gdkgl: Stop getting the clip region from cairo
...
Unused
2020-10-14 15:06:12 -04:00
Timm Bäder
ddcff9eb0f
gl renderer: simplify ->render() implementation a bit
...
We already use self->scale_factor when initialized whole_surface,
so set self->scale_factor first.
2020-10-14 15:06:12 -04:00
Timm Bäder
9fe21b7181
shaderbuilder: Print error message after source code
...
My terminal scrolls down, so showing the error message last makes sense.
2020-10-14 15:06:12 -04:00
Timm Bäder
7bf858b9d0
gl renderer: Add a helper to setup projection matrix
2020-10-14 15:06:12 -04:00
Timm Bäder
bc034d1190
gl renderer: Ignore rendering if accumulated opacity is too small
2020-10-14 15:06:12 -04:00
Timm Bäder
904772c719
gdkgl: Rename function
...
This returns the name of the shader type.
2020-10-14 15:06:12 -04:00
Timm Bäder
7222a0901d
unblurred outset shadow shader: Use premultiply()
2020-10-14 15:06:12 -04:00
Timm Bäder
a0bb248bb3
gl renderer: Use premultiply() in inset shadow shader`
2020-10-14 15:06:12 -04:00
Timm Bäder
0dc0b03d6f
glarea demo: Add min size to gl area
2020-10-14 15:06:12 -04:00
Timm Bäder
9f574a596f
gdkgl: Remove unused cairo_get_matrix() call
2020-10-14 15:06:12 -04:00
Timm Bäder
4b8f3e9b92
colorscale: Refactor creating the hue texture
...
Make this a bit shorter and don't call gtk_hsv_to_rgb in the inner
loop as that is unnecessary.
2020-10-14 15:06:12 -04:00
Timm Bäder
769b15c29b
colorplane: Remove (un)realize handlers
...
Creating the texture in realize() is unnecessary these days, since we
can just rely on size_allocate to do that.
2020-10-14 15:06:12 -04:00
Timm Bäder
8e9a810045
colorutils: Refactor hsv_to_rgb and fold into only caller
2020-10-14 15:06:12 -04:00
Timm Bäder
663ae67935
colorplane: Refactor create_texture()
...
Create a R8G8B8 texture here so we don't waste memory and do work for
an alpha channel we don't care about.
2020-10-14 15:06:12 -04:00
Timm Bäder
76e4002226
colorutils: Remove unused macro
2020-10-14 15:06:12 -04:00
Timm Bäder
ae71fe3739
colorplane: Whitespace
2020-10-14 15:06:12 -04:00
Emmanuele Bassi
66ce0cbec0
Generate introspection for GdkWayland API
...
Like we do for GdkX11. We can't use all of the public C API, but we can
expose enough type information to allow non-C developers to actually
check if they are running the Wayland GDK backend or not—plus some
additional Wayland-specific API.
2020-10-14 15:06:12 -04:00
Emmanuele Bassi
fe871f9d46
Add type annotations for GdkWayland API
...
The GdkWayland API takes generic GDK types and performs a run time
check, which means we need to properly annotate the actual expected
type in order to have methods recognised as such.
2020-10-14 15:06:12 -04:00
Emmanuele Bassi
40e4f3758e
Skip GdkWayland symbols that use wayland-client types
...
The wayland-client API does not have introspection annotations, so we
can't use these types anyway.
2020-10-14 15:06:12 -04:00
Aurimas Černius
2fb1f4a747
Updated Lithuanian translation
2020-10-14 15:06:12 -04:00
Christian Hergert
fb02c99868
macos: port gtk to GDK_WINDOWING_MACOS
...
For the various uses of GDK_WINDOWING_QUARTZ, we need to use
alternatives from GDK_WINDOWING_MACOS.
Some minor loss of functionality is here, such as icons sent with
application menus. That can certainly be added back at a future
point.
2020-10-14 15:06:12 -04:00
Christian Hergert
036b56a43b
gtk: use GDK_WINDOWING_MACOS in gentypefuncs.py
2020-10-14 15:06:12 -04:00
Christian Hergert
9279c2cbd1
gdk: remove quartz subdirectory from backends
2020-10-14 15:06:12 -04:00
Christian Hergert
aed279ed4e
macos: add key equivalent helper
...
This is needed by quartz code in gtk/.
2020-10-14 15:06:12 -04:00
Christian Hergert
cc2e69cbd8
macos: remove workaround for scroll delta
...
This gets handled differently in gtk/ and so we shouldn't translate it here.
2020-10-14 15:06:12 -04:00
Christian Hergert
ff279d03b2
macos: track various changes in GDK
2020-10-14 15:06:12 -04:00
Christian Hergert
1519b40ffa
macos: lookup NSEvent by translated GdkEvent
...
This will be needed by the quartz imcontext.
2020-10-14 15:06:12 -04:00
Christian Hergert
28d2e608f9
macos: move input method names to private header
2020-10-14 15:06:12 -04:00
Piotr Drąg
c753f8f30b
Update Polish translation
2020-10-14 15:05:46 -04:00
Marek Černocký
58769467cf
Updated Czech translation
2020-10-14 15:05:46 -04:00
Matthias Clasen
8a361f901d
gtk-demo: Keep undisplayable resources out of view
...
No point in showing an apologetic tab for a blob of binary data.
gtk4-demo shows the resources under /DEMONAME/ for each demo,
so move the data to /DEMONAME_data/.
2020-10-14 15:05:46 -04:00
Matthias Clasen
9b26660095
Send focus events to the root
...
We are not propagating focus change events, and that is the only
place where we are listening for focus change events. If GtkWindow
does not see focus-in events for its popovers, we end up with
inadvertendly inactive windows.
Fixes : #3240
2020-10-14 15:05:46 -04:00
Matthias Clasen
8dce92e82b
window: Be more careful when looking for focus
...
When passing focus up to a parent, make sure the
newly chosen focus widget actually accepts the focus.
2020-10-14 15:05:46 -04:00
Matthias Clasen
2d927d0ee0
build: Require sysprof 3.38.0
...
We use sysprof_collector_request_counters, which
was introduced in sysprof 3.38.0.
2020-10-14 15:05:46 -04:00
Matthias Clasen
2273e27808
gtk-demo: Ellipsize columns in the characters demo
...
some of the columns have uneven widths, causing them
to bounce around as you scroll. Ellipsize them and
give them a fixed with.
2020-10-14 15:05:46 -04:00
Matthias Clasen
2bdc8c7d9e
docs: Add more details to the migration guide
...
Add some details about GdkSurface and GtkWindow api changes.
Fixes : #3242
2020-10-14 15:05:45 -04:00
Christian Hergert
9f01d4fe44
macos: fix coordinates and state when querying device
...
When querying a device, we need to ensure we are providing coordinates
in the coordinate system of the surface. Further, we need to actually
provide the button and keyboard state.
This fixes some issues related to dragging scrollbars and selecting list
box rows more reliably.
2020-10-14 11:34:44 -07:00
Christian Hergert
d5b5410b8f
macos: use simple monotonic for event serial
2020-10-14 11:34:44 -07:00
Christian Hergert
d6abc125ad
macos: fix compiler warnings
2020-10-14 11:34:44 -07:00
Matthias Clasen
2142c6c086
docs: Fix a copy-paste error
2020-10-14 08:23:06 -04:00
Emmanuele Bassi
9377192102
Correctly annotate gdk_wayland_seat_get_wl_seat()
...
We expect a `GdkWaylandSeat` as the instance parameter.
2020-10-14 11:57:06 +01:00
Emmanuele Bassi
da007ac97b
Add a public header for GdkWaylandSeat
...
We have public API requiring it as a type.
2020-10-14 11:55:34 +01:00
Jakub Steiner
974ce500d6
Merge branch 'wip/jimmac/sidebar-hover-selected-focus' into 'master'
...
Adwaita: selected:hover and focus:selected:hover states
Closes #3251
See merge request GNOME/gtk!2686
2020-10-14 07:36:06 +00:00
Matthias Clasen
b818b34143
Cosmetics
...
Fix a few copy-paste errors.
2020-10-13 21:27:56 -04:00
Matthias Clasen
32d8db103a
Cosmetics
...
Avoid typo-prone repetition of the full interface names.
We have them in the introspection data already.
2020-10-13 18:58:25 -04:00
Matthias Clasen
9955d900db
dropdown: Use the combox accessible role
...
Its really just a combobox with another name.
2020-10-13 18:31:53 -04:00
Matthias Clasen
e3620bdc22
combobox: Use the combobox accessible role
...
Makes sense.
2020-10-13 17:53:39 -04:00
Matthias Clasen
b15328e0d6
atspi: Implement Selection for GtkFlowBox
...
This is a copy of the listbox implementation.
2020-10-13 17:24:06 -04:00
Matthias Clasen
2664c29454
flowbox: Update accessible state for children
...
Set the SELECTED state to reflect whether the selected
is selected, unselected, or unselectable. This is
enough to make selection changes appear in Accerciser.
While we are at it, also set the multi-selectable
property for the flowbox itself.
2020-10-13 17:24:06 -04:00
Matthias Clasen
db97f99359
atspi: Implement Selection for GtkComboBox
...
This doesn't really work in Accerciser. But then,
neither does the GTK 3 implementation from which
this is copied.
2020-10-13 17:24:06 -04:00
Matthias Clasen
caeea0e368
Remove excessively spammy debug messages
...
Non need to announce the same things for every context
we create, and the path is not really that interesting.
without knowing what it belongs to. I would suggest to
make it visible in the inspector instead, so you can
look it up for the widgets you are interested in.
2020-10-13 17:24:06 -04:00
Matthias Clasen
d0753f645e
Fix compiler warnings
2020-10-13 17:24:06 -04:00
Matthias Clasen
81e107885c
Remove some unused code
2020-10-13 17:24:06 -04:00
Matthias Clasen
8f4bc4a65d
atspi: Fix a variant parser oversight
...
When you pass a variant, the format needs an @.
GVariant is not your friend.
2020-10-13 17:24:06 -04:00
Matthias Clasen
08f57d5c3d
atspi: Implement Selection for listbox
...
Implement the selection interface for GtkListBox.
This also includes a convenience api for context
addresses: gtk_at_spi_context_to_ref.
2020-10-13 17:24:06 -04:00
Matthias Clasen
3cc9ac406d
listbox: Update accessible state for rows
...
Set the SELECTED state to reflect whether the row
is selected, unselected, or unselectable. This is
enough to make selection changes appear in Accerciser.
While we are at it, also set the multi-selectable
property for the listbox itself.
2020-10-13 17:24:06 -04:00
Jakub Steiner
f1e9f853de
Adwaita: selected:hover and focus:selected:hover states
...
- getting pretty deep, but visually seems to make sense. Selected row hovers
increase contrast.
Fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/3251
2020-10-13 21:27:17 +02:00
Matthias Clasen
18b6c4e69d
Merge branch 'wip/carlosg/for-master' into 'master'
...
Cascade-close popovers by default
Closes #3200
See merge request GNOME/gtk!2685
2020-10-13 19:25:59 +00:00
Matthias Clasen
ccbacb5cce
Fix the build
...
I forgot a few casts in a02c50e72f .
2020-10-13 11:23:13 -04:00
Carlos Garnacho
a939203e6e
gtkmodelbutton: Drop special case to close GtkPopoverMenu
...
With ::cascade-popdown in place, this special case is not necessary
anymore.
2020-10-13 16:55:53 +02:00
Carlos Garnacho
3ba60b06fe
gtkpopover: Remove GtkPopoverMenu special case
...
Now that there's ::cascade-popdown, we don't need to treat
GtkPopoverMenu especially here.
2020-10-13 16:55:53 +02:00
Carlos Garnacho
024d832d94
gtkpopover: Add cascade-popdown property/functions
...
And honor it in gtk_popover_popdown(). By default, a GtkPopover
pops down automatically if a child popover was closed, if this
property is FALSE, the popover will remain opened.
2020-10-13 16:55:53 +02:00
Matthias Clasen
b909455154
atspi: Fix up the role for password entries
...
We use to set the the 'password text' role for entries with
visibility = FALSE. Nowadays, we have a separate class for
password entries, so fix up the role mapping based on that.
2020-10-13 10:52:43 -04:00
Matthias Clasen
bf0f3a82cf
atspi: Make text change notification work
...
Make text change notification work for editables, by connecting
to the ::insert-text and ::delete-text signals on the wrapped
GtkText widget, and for GtkTextView by connecting to the
corresponding GtkTextBuffer signals.
This code is more or less directly copied from GtkTextViewAccessible
and GtkEntryAccessible in GTK 3.
2020-10-13 09:44:04 -04:00
Matthias Clasen
a02c50e72f
text: Make editable signals work again
...
Since the big editable reorg, GtkText was not emitting
::insert-text and ::delete-text, as is expected of
editables. We want to use those signals for a11y
change notification, so make them work again.
2020-10-13 00:49:10 -04:00
Matthias Clasen
81440675af
atspi: Set placeholder-text attribute
...
This is how GTK3 passes placeholder-text to orca,
and it works - orca reads it.
2020-10-12 23:31:03 -04:00
Matthias Clasen
3af56f5216
atspi: Implement EditableText interface for the entry wrappers
...
Drop the EditableText implementation for GtkText,
and implement it for all the wrapper widgets instead.
2020-10-12 22:07:18 -04:00
Matthias Clasen
63dd0405c7
accessible: Add some docs
...
Explain briefly how a11y works for entry wrappers
(since I won't remember a few months from now).
2020-10-12 21:58:49 -04:00
Matthias Clasen
b7ac660f37
atspi: Implement Text interface for the entry wrappers
...
Drop the Text implementation for GtkText, and implement
it for all the wrapper widgets instead.
2020-10-12 21:45:48 -04:00
Matthias Clasen
76b87272a6
spinbutton: Implement GtkAccessible
...
This copies what was done for GtkEntry: get
the focused state from the GtkText within.
We also add a private getter for the text widget,
which was missing here.
2020-10-12 21:45:48 -04:00
Matthias Clasen
852c72fa28
passwordentry: Implement GtkAccessible
...
This copies what was done for GtkEntry: get
the focused state from the GtkText within.
2020-10-12 21:45:48 -04:00
Matthias Clasen
f796d02fea
searchentry: Implement GtkAccessible
...
This copies what was done for GtkEntry: get
the focused state from the GtkText within.
2020-10-12 21:45:48 -04:00
Matthias Clasen
8faf1f64ee
entry: Implement GtkAccessible
...
Override the get_platform_state vfunc to get
the focused state from the GtkText widget within.
2020-10-12 21:45:48 -04:00
Matthias Clasen
8182fab4d9
text: Ignore text widgets for a11y
...
We want to implement the Text interface on the
wrapper entries.
2020-10-12 21:45:48 -04:00
Matthias Clasen
d0d7848cf2
atspi: Use gtk_accessible_get_platform_state
2020-10-12 21:45:48 -04:00
Matthias Clasen
ade9e4b82a
accessible: Add gtk_accessible_get_platform_state
...
As a companion to go with the platform_change api,
add a gtk_accessible_get_platform_state() function
that can be used by backends to get the platform
state.
This is in preparation for making entries inherit
their focus states from the text widget within.
2020-10-12 21:45:41 -04:00
Matthias Clasen
663934b2dc
atspi: Use gtk_accessible_should_present
...
Replace explicit visibility check by this
more general method of determining whether
an accessible should be presented to the
a11y layer.
2020-10-12 21:43:17 -04:00
Matthias Clasen
d9adc1b5aa
accessible: Add a way to hide accessibles
...
Similar to gtk_widget_should_layout(), add a
gtk_accessible_should_present() function that backends can
use to determine whether an accessible should be presented
or not.
Ways to make a widget not presented in a11y:
- hide the widget
- set its role to NONE
- make it have a NULL AT context
We will use this in future to hide the GtkText inside
an entry, since the Text implementation will be done
by the wrapper.
2020-10-12 21:43:17 -04:00
Matthias Clasen
3bfb32e699
Cosmetics
2020-10-12 21:43:17 -04:00
Matthias Clasen
5eb482ebaa
atspi: Treat all entries the same for collecting state
...
We are determining editable state based on the
accessible role (although we could make it platform
state now), so cover all the roles that we use for
entry wrappers.
2020-10-12 21:43:17 -04:00
Matthias Clasen
61474b5a94
atspi: Fix collecting states
...
This is somewhat embarrassing.
2020-10-12 21:42:51 -04:00
Matthias Clasen
8f63443393
Fix the build
2020-10-12 21:37:09 -04:00
Matthias Clasen
dd650ff90e
atspi: D-Bus methods return tuples
...
I've learned this the hard way: When returning a
value from a D-Bus call, the variant construct must
*always* be g_variant_new ("(...)"...
2020-10-12 15:50:36 -04:00
Matthias Clasen
101cbe690e
Don't unref a floating variant
...
It gets consumed somewhere along the way.
2020-10-12 15:10:40 -04:00
Matthias Clasen
62747eb243
atspi: Unregister objects on the bus
...
When a widget is going away, we need to remove
the context from the bus, or else ATs might have
the idea to call methods on them, leading to badness.
2020-10-12 15:10:40 -04:00
Matthias Clasen
d432cbb02b
atspi: Emit property changes for focus
...
With this orca, actually speaks \o/. Sadly, it only
says 'gtk modelbutton widget' so far, but its a start.
2020-10-12 15:10:40 -04:00
Matthias Clasen
45e82adf87
atspi: Cosmetics
...
Use simple wrappers instead of opencoding bit twiddling
all over the place.
2020-10-12 15:10:40 -04:00
Matthias Clasen
a2d220edfa
widget: Notify a11y of focus changes
...
This is using the new 'platform changes' mechanism
to tell the a11y backends when focus changes.
2020-10-12 15:10:40 -04:00
Matthias Clasen
b5ee73d299
a11y: Pass on platform changes
...
Add an enum for 'platform changes' to the at context
change notification mechanism. This will let us pass
along things that ARIA considers 'platform state' such
as focus or editability. The difference between the
platform state and other ARIA states is that we don't
keep the platform state separately in the at context
- backends are expected to just query the widgets.
This is just about avoiding notify listeners for
change notification.
2020-10-12 15:10:40 -04:00
Matthias Clasen
578c8b5068
atspi: Be more careful about indexes
...
Don't return a number for IndexInParent when we
don't have one.
2020-10-12 15:10:40 -04:00
Matthias Clasen
f9ee23825e
atspi: Set some more atspi states
...
Pass on more of the states that are represented
as properties in aria: modal, multi-line, orientation.
2020-10-12 15:10:40 -04:00
Matthias Clasen
35f70d5a99
Pass orientation property to accessible
...
We should set the accessible properties we have,
where they make sense. So set orientation, if the
widget is orientable.
2020-10-12 15:10:40 -04:00
Matthias Clasen
54f1eb4c04
wip: Emit StateChanged signals
...
This is not fully baked, but it is enough to make accerciser
notice when a text entry goes from editable to not editable.
2020-10-12 15:10:40 -04:00
Matthias Clasen
66a81f1187
atspi: Derive readonly state from aria properties
...
We can use the read-only property, together with the
accessible role, to determine whether to set editable
and read-only states for at-spi. This lets us avoid
directly poking at the widgets.
2020-10-12 15:10:40 -04:00
Matthias Clasen
2a5af4e1d6
text: Set the readonly accessible property
...
This mirrors what we already do for GtkTextView.
2020-10-12 15:10:40 -04:00
Matthias Clasen
d37b0357b3
atspi: Set editable state
...
ATs look at not just the implemented interfaces, but
also the states to decide what to do. It turns out that
the EditableText interface is only used by accerciser
if the editable state is set. So set it.
2020-10-12 15:10:40 -04:00
Matthias Clasen
aea25cbbe5
atspi: Implement EditableText interface
...
Implement EditableText for GtkText and GtkTextView.
2020-10-12 15:10:40 -04:00
Matthias Clasen
a72a7d4aeb
atspi: Break out the Value implementation
...
This isn't necessarily very big, but it keeps
the widget checks out of gtkatspicontext.c, and
it is a nice pattern.
2020-10-12 15:10:40 -04:00
Matthias Clasen
d38182bb5d
atspi: Break out the Text implementations
...
Move the implementation of the Text interface
to its own source file, and split it up along
widget lines, to avoid it becoming too messy.
2020-10-12 15:10:40 -04:00
Matthias Clasen
f22edccb2a
scalebutton: Set accessible value properties
...
This is what we did in GTK 3.
2020-10-12 15:10:40 -04:00
Matthias Clasen
dc9fee6185
paned: Set accessible value properties
...
This is what we did in GTK 3.
2020-10-12 15:10:40 -04:00
Matthias Clasen
776b4aee0c
Simplify GetInterfaces handling
...
It is error prone to keep the same conditions in sync
in two places. Instead, just assemble the list of interfaces
as we register objects, and use when GetInterfaces is called.
2020-10-12 15:10:40 -04:00
Matthias Clasen
d37782c533
atspi: Implement Value for more widgets
...
Apply the Value implementation to the widgets where
we had one in GTK 3: GtkLevelBar, GtkRange, GtkScaleButton,
GtkSpinButton, GtkPaned, GtkProgressBar. To make these
work, the widgets need to set the accessible value properties.
2020-10-12 15:10:40 -04:00
Matthias Clasen
8c3e5124c2
atspi: Implement Value interface for ranges
2020-10-12 15:10:40 -04:00
Matthias Clasen
190059dca1
atspi: Implement Text interface for text views
...
With this, all relevant widgets support the
Text interface.
2020-10-12 15:10:40 -04:00
Matthias Clasen
925ef1f90f
atspi: Add textview utilities
...
These are very similar to the pango utilities,
and are copying code from the textview accessible
implementation in GTK 3.
2020-10-12 15:10:40 -04:00
Matthias Clasen
ba63daa1d2
atspi: Export more pango utils
...
We are going to reuse some of the code that does
the pango -> atspi attribute conversion for text
tags.
2020-10-12 15:10:40 -04:00
Matthias Clasen
5b076fee12
atspi: Implement text for GtkText widgets too
...
There is some open question here whether the interface
should be implemented on the outer or the inner widget
of the entry-text pairs. For now, our hand is forced,
since only GtkText provides access to the layout that
we need for implementing many of the interface methods.
2020-10-12 15:10:40 -04:00
Matthias Clasen
b80272a7e7
atspi: Implement Text interface for labels
...
This is a not-quite-complete implementation of the
Text interface for GtkLabel. The missing parts are
anything around extents and positions, as well as
the ScrollSubstring apis.
2020-10-12 15:10:40 -04:00
Matthias Clasen
7c8a16812e
atspi: Add pango utilities
...
This code is more or less a direct copy of what
we had in gtkpango.c in 3.x.
2020-10-12 15:10:40 -04:00
Matthias Clasen
ddb72accc0
atspicontext: Fix GetIndexInParent for toplevels
...
For toplevels, we need to return the index in the
list of toplevels, since that is what GtkAtspiRoot
is using.
2020-10-12 15:10:40 -04:00
Matthias Clasen
824ab7e4ed
atcontext: labelled-by has a reference list
...
This is unclear - our docs state that all the
relations have value type reference, but in fact
they all have value type reference list.
2020-10-12 15:10:40 -04:00
Matthias Clasen
3a867e26d0
atspicontext: Implement GetRelationSet
...
This translates relations as far as the match.
I'm not sure yet what we can do about the fact that
atspi expects relations to be bidirectional (ie have
label-for *and* labelled-by) while aria has only one
direction.
2020-10-12 15:10:40 -04:00
Matthias Clasen
e269cb7a81
atspiroot: Stub out GetRelationSet
...
This needs to be fully implemented, for now sending
an empty relation set back prevents accerciser from
getting hung up.
2020-10-12 15:10:40 -04:00
Matthias Clasen
0ae2ae7944
atspi: Add the AtspiRelationType enum
...
This is what we need to map the aria relation
types to.
2020-10-12 15:10:40 -04:00
Matthias Clasen
5db6c4b038
Move atspi enums to gtkatspiprivate.h
2020-10-12 15:10:40 -04:00
Matthias Clasen
db6bd018ca
Add a GetInterfaces method
...
It turns out that accerciser depends on this undocumented
method that is not in the xml at all, otherwise interface
sections in the accerciser ui never get enabled.
2020-10-12 15:10:40 -04:00
Matthias Clasen
9d43e5bd59
Don't pass NULL to g_variant_new_string
...
That does not work.
2020-10-12 15:10:40 -04:00
Matthias Clasen
edfc55ae89
atspi utils: Fix an oversight
...
gtk_accessible_role_to_atspi_role must always return
an atspi role. The fallback was returning an aria
role.
2020-10-12 15:10:40 -04:00
Matthias Clasen
d6b64b5e29
Fixup: Add a forgotten #pragma once
2020-10-12 15:10:40 -04:00
Emmanuele Bassi
13aa053f6b
Rename libgtk_only symbol in GdkWaylandToplevel
...
All public non-exported symbols in GDK can be used by GTK.
2020-10-12 16:49:10 +01:00
Emmanuele Bassi
4f316f3249
docs: Remove private GdkWayland API from the reference
2020-10-12 16:44:36 +01:00
Emmanuele Bassi
38304fc138
Hide gdk_wayland_display_prefers_ssd()
...
The function is not exported, so it should not be in a public header.
2020-10-12 16:44:05 +01:00
Emmanuele Bassi
da6c0f3ecb
Move private GdkSurface Wayland API into its own header
...
This allows us to hide private API from installed headers,
documentation, and introspection.
2020-10-12 16:40:19 +01:00
Emmanuele Bassi
9ce790032d
a11y: Convenience API for referencing ATSPI root node
...
We turn the root node into a reference fairly often, so it's worth it to
have a utility function that does this for us.
2020-10-12 16:19:32 +01:00
Emmanuele Bassi
35163bd7cc
a11y: Add utility function for null refs
...
ATSPI was written for CORBA, which allows passing around "nil"
as valid object references.
2020-10-12 16:19:32 +01:00
Matthias Clasen
9d0952bd7f
atspicontext: Implement GetState
...
Translate the aria states to at-spi's interpretation
of atk states.
2020-10-12 16:19:32 +01:00
Matthias Clasen
e189ccc8ed
atspiroot: Fix GetState implementation
...
When the GetState signature says 'au', it actually
means a bitset that is sent as a pair of 32bit integers.
2020-10-12 16:19:32 +01:00
Matthias Clasen
762fbf34fc
atspiroot: Implement GetIndexInParent
...
Just for good measure
2020-10-12 16:19:32 +01:00
Matthias Clasen
9f73638d43
atspicontext: Implement GetIndexInParent
...
This is needed for ATs to take our tree seriously.
2020-10-12 16:19:32 +01:00
Matthias Clasen
057b447137
atspicontext: Implement more accessible api
...
Implement GetChildAtIndex, GetChildren and ChildCount.
2020-10-12 16:19:32 +01:00
Matthias Clasen
78690845b1
atspiroot: Implement GetChildren
...
No surprises here.
2020-10-12 16:19:32 +01:00
Matthias Clasen
2ea338a8cf
atspiroot: Don't leak references
...
The reffing getter trap, lurking behind g_list_model_get_item().
2020-10-12 16:19:32 +01:00
Matthias Clasen
e2f3039663
atspiroot: Implement GetLocale
2020-10-12 16:19:32 +01:00
Matthias Clasen
8f20133769
atspicontext: Print out the a11y bus address
...
Make our debug spew useful: Having the bus address
makes it easy to jump on the a11y bus to look around
with dbus tools.
2020-10-12 16:19:32 +01:00
Emmanuele Bassi
55b1fbd0f3
a11y: Localise the role name of the root node
2020-10-12 16:19:32 +01:00
Emmanuele Bassi
b57f1588df
a11y: Register the Accessible interface on all AtSpiContext instances
...
This is not a complement implementation.
2020-10-12 16:19:32 +01:00
Emmanuele Bassi
60acdb9cad
a11y: Implement more ATSPI methods on the root node
2020-10-12 16:19:32 +01:00
Emmanuele Bassi
07759b158a
a11y: Add method to extract desktop data
...
We are going to need the desktop name and path to populate the parent
property of AtSpiContexts associated to top level widgets.
2020-10-12 16:19:32 +01:00
Emmanuele Bassi
9511c8273a
a11y: Validate the DBus context path
...
UUIDs use dashes to separate the various blocks; unfortunately, this
results in an invalid DBus object path. Replace the dashes with an
underscore.
2020-10-12 16:19:32 +01:00
Emmanuele Bassi
b85b1f5b51
a11y: Turn accessible roles to string
...
Add a simple utility function to turn GtkAccessibleRole values into the
appropriate string, including localization.
2020-10-12 16:19:32 +01:00
Emmanuele Bassi
716024d882
a11y: Convert GTK roles to ATSPI ones
...
There's not a precise, 1:1 mapping between the newer ARIA roles and the
older ATSPI ones. We make do with what we have.
2020-10-12 16:19:32 +01:00
Emmanuele Bassi
21482e8264
a11y: Compute the label for a GtkATContext
...
The ARIA spec defines the mechanism for determining the name of an
accessible element—see §4.3 of the WAI-ARIA spec.
We follow the specification as much as it makes sense for GTK to do
so:
1. if the element is hidden, return an empty string
1. if the element has a labelled-by relation set, retrieve the
label of the related element
2. if the element has a label property set, use the value of
the property
3. if neither labelled-by nor label attributes are set, we use
the role to compute the name:
- for a `range` role, we return the contents of the value of
the `value-text` or `value-now` properties
- for any other role, we return a textual representation of
the GtkAccessibleRole enumeration value
2020-10-12 16:19:32 +01:00
Emmanuele Bassi
88113956a3
tests: Use the test ATContext for every test
...
Otherwise we're going to need a full desktop session in order to run the
test suite.
2020-10-12 16:19:32 +01:00
Emmanuele Bassi
e6c5d57ffe
a11y: Return the ATSPI role for the root element
2020-10-12 16:19:32 +01:00
Emmanuele Bassi
d7ebf18723
a11y: Add AT-SPI cache object
...
Right now, the cache is unused, and we still need to implement the
serialisation method and emit the signals.
2020-10-12 16:19:32 +01:00
Emmanuele Bassi
658d910967
a11y: Ignore widgets during destruction
...
There's no point in creating a GtkATContext when a widget is getting
destroyed.
2020-10-12 16:19:32 +01:00
Emmanuele Bassi
bd43e9cfc5
a11y: Register the accessible root object
...
When we create the first AT-SPI context we also need to register the
accessible root on the accessibility bus. The accessible root object is
the main entry point of an accessible application, and it holds the
global state to present to the ATs that connect to the bus.
2020-10-12 16:19:32 +01:00
Emmanuele Bassi
8c18480092
a11y: Add a display to GtkATContext
...
Since we need to check at run time what kind of AT context to use, we
need a hook into the whole GDK backend machinery. The display connection
seems to be the best choice, in this case, as it allows us to determine
whether we're running on an X11 or Wayland system, and thus whether we
should create a GtkAtSpiContext.
This requires some surgery to fix the GtkATContext creation function, in
order to include a GdkDisplay instance.
2020-10-12 16:19:32 +01:00
Emmanuele Bassi
8f19bb0832
a11y: Add dummy AT-SPI context
...
Does not do anything, at the moment, but it's going to get filled out
soon.
The backend is selected depending on the platform being compiled in;
since we're using AT-SPI on X11 and Wayland, and we don't have other
accessibility implementations, we currently don't care about run time
selection, but we're going to have to deal with that.
2020-10-12 16:19:31 +01:00
Emmanuele Bassi
c50916d27b
a11y: Add the AT-SPI DBus descriptions
...
And generate the code for the DBus interfaces.
We don't want the full object manager experience, here, because we're
going to have a single object responding to various interfaces and
remote method calls. For this reason, we're not using the gnome module
in Meson to call gdbus-codegen for us: we need to use the interface info
command line arguments, and those are not available from Meson.
2020-10-12 16:19:31 +01:00
Emmanuele Bassi
4b60e7470a
Use test AT context with installed tests
...
Otherwise we're going to need an AT-SPI service on the session, and the
accessibility bus.
2020-10-12 16:19:31 +01:00
Matthias Clasen
77d4729483
Merge branch 'ebassi/for-master' into 'master'
...
Ebassi/for master
See merge request GNOME/gtk!2683
2020-10-12 14:39:39 +00:00
Emmanuele Bassi
daac36ea4c
Generate introspection for GdkWayland API
...
Like we do for GdkX11. We can't use all of the public C API, but we can
expose enough type information to allow non-C developers to actually
check if they are running the Wayland GDK backend or not—plus some
additional Wayland-specific API.
2020-10-12 14:07:26 +01:00
Emmanuele Bassi
f83ee2ab6a
Add type annotations for GdkWayland API
...
The GdkWayland API takes generic GDK types and performs a run time
check, which means we need to properly annotate the actual expected
type in order to have methods recognised as such.
2020-10-12 14:07:26 +01:00
Emmanuele Bassi
33e84edf0c
Skip GdkWayland symbols that use wayland-client types
...
The wayland-client API does not have introspection annotations, so we
can't use these types anyway.
2020-10-12 14:07:26 +01:00
Aurimas Černius
08fb8c1c2a
Updated Lithuanian translation
2020-10-11 17:25:45 +03:00
Matthias Clasen
035e303f83
Merge branch 'wip/chergert/gdk-macos-fixes' into 'master'
...
various build fixes for GDK/GTK on macos
See merge request GNOME/gtk!2680
2020-10-10 11:55:01 +00:00
Piotr Drąg
91ba0a31e7
Update Polish translation
2020-10-10 12:45:37 +02:00
Marek Černocký
72ea3a1655
Updated Czech translation
2020-10-10 12:17:27 +02:00
Christian Hergert
07bb07abbe
macos: port gtk to GDK_WINDOWING_MACOS
...
For the various uses of GDK_WINDOWING_QUARTZ, we need to use
alternatives from GDK_WINDOWING_MACOS.
Some minor loss of functionality is here, such as icons sent with
application menus. That can certainly be added back at a future
point.
2020-10-09 20:08:23 -07:00
Christian Hergert
41101673c3
gtk: use GDK_WINDOWING_MACOS in gentypefuncs.py
2020-10-09 20:05:20 -07:00
Christian Hergert
97f03edae4
gdk: remove quartz subdirectory from backends
2020-10-09 20:04:27 -07:00
Christian Hergert
d8ba916586
macos: add key equivalent helper
...
This is needed by quartz code in gtk/.
2020-10-09 20:03:52 -07:00
Christian Hergert
3f519e4d9b
macos: remove workaround for scroll delta
...
This gets handled differently in gtk/ and so we shouldn't translate it here.
2020-10-09 20:02:38 -07:00
Christian Hergert
58f9413464
macos: track various changes in GDK
2020-10-09 20:02:18 -07:00
Christian Hergert
59cdd7ae69
macos: lookup NSEvent by translated GdkEvent
...
This will be needed by the quartz imcontext.
2020-10-09 19:59:21 -07:00
Christian Hergert
a30adfe1e0
macos: move input method names to private header
2020-10-09 19:56:21 -07:00
Christian Hergert
6706623731
demo: fix out of bounds array index usage
2020-10-09 19:55:25 -07:00
Matthias Clasen
758675f44e
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
Closes #3242 and #3240
See merge request GNOME/gtk!2679
2020-10-09 13:35:57 +00:00
Matthias Clasen
8fcd4ac0f9
gtk-demo: Keep undisplayable resources out of view
...
No point in showing an apologetic tab for a blob of binary data.
gtk4-demo shows the resources under /DEMONAME/ for each demo,
so move the data to /DEMONAME_data/.
2020-10-09 07:52:29 -04:00
Matthias Clasen
4c3eb7c6f7
Merge branch 'ebassi/for-master' into 'master'
...
Tone down a user visible message
See merge request GNOME/gtk!2678
2020-10-09 11:47:38 +00:00
Matthias Clasen
115ed005e6
Send focus events to the root
...
We are not propagating focus change events, and that is the only
place where we are listening for focus change events. If GtkWindow
does not see focus-in events for its popovers, we end up with
inadvertendly inactive windows.
Fixes : #3240
2020-10-09 07:43:40 -04:00
Matthias Clasen
6a0704aeb4
window: Be more careful when looking for focus
...
When passing focus up to a parent, make sure the
newly chosen focus widget actually accepts the focus.
2020-10-09 07:43:25 -04:00
Matthias Clasen
eb647299d4
build: Require sysprof 3.38.0
...
We use sysprof_collector_request_counters, which
was introduced in sysprof 3.38.0.
2020-10-09 07:43:25 -04:00
Matthias Clasen
e7aa10342b
gtk-demo: Ellipsize columns in the characters demo
...
some of the columns have uneven widths, causing them
to bounce around as you scroll. Ellipsize them and
give them a fixed with.
2020-10-09 07:43:25 -04:00
Matthias Clasen
c835df5602
docs: Add more details to the migration guide
...
Add some details about GdkSurface and GtkWindow api changes.
Fixes : #3242
2020-10-09 07:43:25 -04:00
Emmanuele Bassi
43300b4047
Tone down a user visible message
...
Self-deprecating humour badly translates to a demo message.
2020-10-09 10:14:41 +01:00
Timm Bäder
cdd2a2af1b
Merge branch 'kjellahl/gdkseat' into 'master'
...
gdkseat: Make gdk_seat_get_tools() public
Closes #3241
See merge request GNOME/gtk!2677
2020-10-08 15:05:57 +00:00
Kjell Ahlstedt
cb98a732e4
gdkseat: Make gdk_seat_get_tools() public
...
Fixes #3241
2020-10-08 16:22:05 +02:00
Timm Bäder
4450f64421
Merge branch 'fix.builder.msvc' into 'master'
...
testsuite/gtk/builder.c: Fix running on Visual Studio
See merge request GNOME/gtk!2676
2020-10-08 09:42:04 +00:00
Chun-wei Fan
1e4d3b6ca1
testsuite/gtk/builder.c: Fix running on Visual Studio
...
Explicitly say in the code that we are exporting the symbols so that when the
test program runs, it can find the required builder symbols.
2020-10-08 16:11:35 +08:00
Matthias Clasen
08ecf779f9
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
See merge request GNOME/gtk!2674
2020-10-08 02:19:42 +00:00
Matthias Clasen
5d7907caa5
gdk: Drop gdk_surface_new_temp
...
It is not used anymore.
2020-10-07 21:18:25 -04:00
Matthias Clasen
606ab611bd
win32: Stop using gdk_surface_new_temp
...
No need to roundtrip through the frontend to create
one of our own surfaces.
2020-10-07 21:07:40 -04:00
Matthias Clasen
27ef9d9e5e
broadway: Stop using gdk_surface_new_temp
...
No need to roundtrip through the frontend to create
one of our own surfaces.
2020-10-07 21:04:05 -04:00
Matthias Clasen
839baf2bef
x11: Stop using gdk_surface_new_temp
...
No need to roundtrip through the frontend to create
one of our own surfaces.
2020-10-07 21:02:22 -04:00
Matthias Clasen
e602d67e59
wayland: Stop using gdk_surface_new_temp
...
No need to roundtrip through the frontend to create
one of our own surfaces.
2020-10-07 21:02:22 -04:00
Matthias Clasen
ba108f261f
gdk: Drop some unused private api
...
No users of gdk_display_peek_event, gdk_display_has_pending
_gdk_display_event_data_copy or _gdk_display_event_data_free,
so drop all of these, and related vfuncs.
2020-10-07 21:02:22 -04:00
Matthias Clasen
668868fb1f
Merge branch 'master' into 'master'
...
Allow LPR backend to print PDF and PS file formats
See merge request GNOME/gtk!418
2020-10-07 20:51:40 +00:00
Benjamin Otte
bc5723a846
Merge branch 'wip/otte/for-master' into 'master'
...
textbuffer: Don't serialize the \0 byte
See merge request GNOME/gtk!2672
2020-10-07 20:33:25 +00:00
Matthias Clasen
98c7de4aa3
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
Closes #3237
See merge request GNOME/gtk!2673
2020-10-07 20:30:52 +00:00
Benjamin Otte
0fdb33e82a
textbuffer: Don't serialize the \0 byte
...
... when converting to text/plain.
2020-10-07 22:14:18 +02:00
Matthias Clasen
cfb316799a
colorchooser: Bring color names back
...
These are useful for accessibility.
Fixes : #3237
2020-10-07 15:56:11 -04:00
Jan Alexander Steffens (heftig)
fb0c062506
gtkplacessidebar: Disconnect and unref cloud_manager in dispose
...
The manager's providers-changed signal can fire after the sidebar has
been freed. Make sure we disconnect the sidebar from the manager.
https://bugs.archlinux.org/task/57984
https://bugs.archlinux.org/task/68123
2020-10-07 15:16:31 -04:00
Matthias Clasen
3d9eb61bba
gtk-demo: Fix an off-by-one error
...
This was found by the asan build in our ci.
2020-10-07 15:16:31 -04:00
Timm Bäder
4993cde0cb
Merge branch 'migration-guide-fix' into 'master'
...
migration guide: Remove stray html tags
See merge request GNOME/gtk!2670
2020-10-07 08:00:43 +00:00
Nicola Fontana
35b0796a1f
migration guide: Remove stray html tags
2020-10-07 08:38:26 +02:00
Matthias Clasen
d839c1beab
Merge branch 'svg-demo' into 'master'
...
Svg demo
See merge request GNOME/gtk!2668
2020-10-06 20:55:28 +00:00
Matthias Clasen
5a9547da41
gtk-demo: Add an svg paintable demo
...
It is a little annoying that this demo will not show up
if we don't find librsvg, but I think showing how easy
this paintable is outweights the annoyance.
2020-10-06 15:12:09 -04:00
Matthias Clasen
25cbc1a15a
gtk-demo: Recognize .svg as images
...
We can't guarantee that we can load it, but worst
case you'll get a missing image.
2020-10-06 15:11:08 -04:00
Matthias Clasen
043207133d
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
Closes #3235
See merge request GNOME/gtk!2667
2020-10-06 18:25:48 +00:00
Matthias Clasen
490163efcd
Merge branch 'aboutwindow' into 'master'
...
gtkaboutdialog: Directly specialize GtkWindow
See merge request GNOME/gtk!2666
2020-10-06 18:25:27 +00:00
Matthias Clasen
44fd0c18c8
aboutdialog: Fix updating license tab
...
We need to update the license button visibility
whenever the license type changes.
2020-10-06 12:53:46 -04:00
Adrien Plazas
a17f33b1fe
gtkaboutdialog: Directly specialize GtkWindow
...
As it doesn't act as a dialog, there is no point specializing GtkDialog,
so his makes it specialize GtkWindow directly.
2020-10-06 18:46:48 +02:00
Matthias Clasen
22eac2f407
window: Fix setting min size
...
We were inadvertedly setting the windows min size
to the default size, making it so that you can never
shrink a window below its default size.
Fixes : #3235
2020-10-06 11:06:36 -04:00
Matthias Clasen
bdbfaef4d8
gdk: Tweak our GL debug message callback
...
Go back to installing our debug message callback
unconditionally if G_ENABLE_CONSISTENCY_CHECKS is
defined, and allow opting into it using GDK_DEBUG=gl-debug
otherwise.
2020-10-06 10:34:30 -04:00
Matthias Clasen
214c35ffc7
gdk: Docs tweaks
...
We don't have library initialization api anymore,
update the section title to reflect that.
2020-10-06 07:58:01 -04:00
Matthias Clasen
7698b4dd63
treelistrowsorter: Add a bandaid
...
The GtkTreeListRowSortKeys implementation doesn't
know how it wants to cache its keys, and just crashes.
Since that is not cool, add a bandaid fix that forces
it to recreate its keys instead. Extra work, but hey,
no crash.
Related: #3228
2020-10-06 07:58:01 -04:00
Emmanuele Bassi
e532f2322b
Merge branch 'FixWin32PopupFocus' into 'master'
...
Gtk4/Win32: Fix popup focus stealing when CSD is disabled
See merge request GNOME/gtk!2665
2020-10-06 10:30:07 +00:00
firox263
f0a8c6311e
Fix Win32 popup focus when using SSD
...
Prevents GDK Popups from stealing focus from the parent window when
using Server Side Decorations on win32.
It uses `ShowWindow` and the `SW_SHOWNOACTIVATE` flag.
2020-10-06 22:37:35 +13:00
Matthias Clasen
b6d4067717
Merge branch 'wip/carlosg/for-master' into 'master'
...
gtkpopover: Revert focus to parent on hide()
Closes #3214
See merge request GNOME/gtk!2653
2020-10-06 02:14:54 +00:00
Matthias Clasen
ac164d240b
Cosmetic
...
Don't call gtk_root_get_focus when we already have
the GtkWindowPrivate struct at hand. And use
gtk_window_set_focus to update the focus, like the
old code did.
2020-10-05 21:53:05 -04:00
Carlos Garnacho
38547120b2
gtkwindow: Ensure to revert focus to a parent on hide()
...
When a widget is hidden, check harder for the keyboard focus being
contained in that widget, in order to reset it. Portions of the
focus child hierarchy may be outdated at the time, so it is more
reliable to check GtkRoot::focus (i.e. the property we intend to
update here).
Fixes: https://gitlab.gnome.org/GNOME/gtk/-/issues/3214
2020-10-06 03:29:13 +02:00
Matthias Clasen
7f5deed2eb
Merge branch 'simple-resizing-fixes' into 'master'
...
Simple resizing fixes
Closes #3076
See merge request GNOME/gtk!2661
2020-10-06 01:25:25 +00:00
Matthias Clasen
ccdc10d9df
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
Closes #3196
See merge request GNOME/gtk!2662
2020-10-06 00:57:30 +00:00
Timm Bäder
982ebf1b69
gradient shaders: Reduce out values as well
...
We only do 6 color stops here now. Also works around a driver bug.
Fixes #3196
2020-10-05 20:35:34 -04:00
Matthias Clasen
20fb7812df
window: Fix window size snapping back
...
We were not updating the remembered size at all when
the window is interactively resized, causing it to
snap back to its default size the next time we call
gdk_toplevel_present().
This is a bandaid fix to prevent very broken resizing
behavior, until we have properly redone toplevel sizing.
Fixes : #3076
2020-10-05 20:24:19 -04:00
Matthias Clasen
082edd957e
wayland: Don't forget to reapply margins
...
When using the saved size because the compositor
told us to, we were forgetting to readd the margins.
The visible symptom of this was the window getting
smaller every time we went to tiled state and back.
2020-10-05 20:17:50 -04:00
Matthias Clasen
e5cd2568c8
wayland: Don't save size when tiled
...
Don't remember the surface size when we are in tiled
state either. This matches the 'fixed_size' condition
in gdk_wayland_surface_configure_toplevel.
This change fixes an issue where moving a window first
to tiled, then to maximized state and back would lead
to the unmaximized window having the tiled dimensions.
2020-10-05 20:15:33 -04:00
Matthias Clasen
d51608a2c9
wayland: Don't emit premature configure events
...
We should not emit configure events before we are realized - size
changes at this point are not relevant.
This gets rid of a mysterious emission of GdkSurface::size-changed
with a size of 52x52, that is happening when GtkWindow sets the
shadow_width before the window is mapped.
2020-10-05 17:18:14 -04:00
Matthias Clasen
67c6f0a08a
gtk-demo: Mention dataset size for Characters
2020-10-05 14:43:38 -04:00
Matthias Clasen
7311464c67
gl: Install the debug message callback for gl-debug
...
Always install the debug message callback when we can
and GDK_DEBUG=gl-debug is specified. Previously, we
were only installing the callback when the build was
a non-optimized debug build.
2020-10-05 14:43:31 -04:00
Matthias Clasen
aaab461c27
Merge branch 'fix-texture-cache' into 'master'
...
gl renderer: Fix up texture cache key
See merge request GNOME/gtk!2659
2020-10-05 14:58:20 +00:00
Matthias Clasen
6b0c65cc38
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
See merge request GNOME/gtk!2660
2020-10-05 14:23:08 +00:00
Matthias Clasen
74d99766e4
gtk-demo: Fix up the Characters demo
...
Move the Unicode names to a separate source file,
and only build the demo if we have harfbuzz (since
we use script names, and those are only available
with harfbuzz).
Also, fix a forgotten type name.
2020-10-05 09:56:04 -04:00
Alexander Larsson
24a27ba44f
gl renderer: Fix up texture cache key
...
The commit e14d2be1 forgot to actually set the parent_rect in the texture
key in the case it is necessary.
2020-10-05 15:43:04 +02:00
Matthias Clasen
6156c3583d
NEWS: Updates
...
Trying a new scheme - when updating NEWS outside of doing
a release, keep the version out, to make the it clear that
this is just about the tip of the branch, not a complete
release.
2020-10-05 08:18:56 -04:00
Matthias Clasen
2b03674464
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
See merge request GNOME/gtk!2658
2020-10-05 11:29:10 +00:00
Matthias Clasen
5d26d11868
gtk-demo: Add a column view demo
...
Make a column view that is showing some Unicode data.
2020-10-04 22:53:45 -04:00
Matthias Clasen
34f33b36f8
Prevent a crash with script names
...
We can't pass NULL to gettext().
2020-10-04 21:20:48 -04:00
Matthias Clasen
bea3bc5d27
Update the copy in gtk-demo too
2020-10-04 19:48:46 -04:00
Matthias Clasen
5d5625dec8
Update script names to Unicode 13
...
It would be better if this was provided elsewhere...
2020-10-04 16:15:09 -04:00
Matthias Clasen
cb833d52fb
Merge branch 'emoji-data-cldr' into 'master'
...
Update Emoji data
Closes #1511 and #950
See merge request GNOME/gtk!2656
2020-10-04 13:56:40 +00:00
Matthias Clasen
9007d153c8
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
See merge request GNOME/gtk!2657
2020-10-04 13:56:30 +00:00
Matthias Clasen
8ca612c966
scale: Make draw-value default to FALSE
...
This is rarely what you want, so lets turn it off
by default.
Update the one place in our demos where we want to
draw a value, add support for this to gtk-builder-tool,
add a test and mention this change in the migration
guide.
2020-10-04 08:26:44 -04:00
Matthias Clasen
452c909b64
Redo the handling of Emoji data
...
Use the data files from https://github.com/milesj/emojibase.git
as source for our Emoji data. Slightly change our data format by
adding a group to each item, in both the Emoji data and in the
setting for recent-emoji.
Install translated versions of the data as separate resource
bundles in $prefix/gtk-4.0/emoji, and load them when appropriate.
Currently, we have data for de, en, es, fr, zh, with data taken
from Unicode 13 and CLDR 13.
Fixes : #950 #1511
2020-10-04 01:14:42 -04:00
Matthias Clasen
7ef5921022
Emoji: Drop the shortname field from emoji.data
...
Match the name for Emoji completion, and display
it too. 'man worker' looks a lot more natural in
the UI than ':man_worker:'.
2020-10-03 20:06:31 -04:00
Matthias Clasen
1d9d5fcf39
Do case-folding and tokenization when creating emoji.data
...
We can avoid doing the extra work of case-folding and
tokenization whenever we filter in the Emoji chooser.
2020-10-03 19:46:46 -04:00
Matthias Clasen
ed724ebc35
emoji: Add keywords to the data
...
And use them for matching in the Emoji chooser.
2020-10-03 19:46:46 -04:00
Matthias Clasen
44448016e8
emoji: Some work on the conversion tool
...
Document the variant format, and write out json
format if asked to.
2020-10-03 19:46:46 -04:00
Matthias Clasen
a4284569c0
Fix Emoji completion
...
This is some late fallout from the container removal.
2020-10-03 19:42:19 -04:00
Matthias Clasen
9a2faf2197
widget-factory: Enable emoji completion somewhere
...
Without a quick way to test this, it is bound to
fall apart. As it has.
2020-10-03 19:41:26 -04:00
Matthias Clasen
6e594da5f2
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
Closes #506
See merge request GNOME/gtk!2655
2020-10-03 19:27:15 +00:00
Matthias Clasen
ac79c0e799
textbuffer: Improve some get_iter apis
...
Make these functions return FALSE if they did not
return the exact position that was requested.
Adapt tests.
Based on a patch by Sebastien Wilmet
Fixes : #506
2020-10-03 14:29:07 -04:00
Matthias Clasen
d0b7a4a4ec
testsuite: Add a test that checks for property accessors
...
Make sure that every object property in GTK has accessors for getting
its value (if the property is readable) or setting it (if it is
writable).
Since we are still missing accessors, the test is allowed to
fail for now. Sadly, mesons xfail support is busted, so we just
disable the test entirely :(
Based on initial work by Benjamin Otte.
Related: #2440
2020-10-03 14:28:37 -04:00
Matthias Clasen
60b1b4669e
spinbutton: Add some missing accessors
...
Add a setter and getter for the climb-rate property.
2020-10-03 13:11:20 -04:00
Matthias Clasen
9d0d4cef03
Cosmetics
2020-10-03 13:11:20 -04:00
Matthias Clasen
1b1bf6c90a
text: Add some missing setters and getters
...
Add getters and setters for the enable-emoji-completion,
propagate-text-width and truncate-multiline properties.
2020-10-03 13:11:20 -04:00
Matthias Clasen
38bd4439e8
directorylist: Drop the item-type property
...
No need for this to be a property.
This showed up in a test for missing accessors.
2020-10-03 13:11:20 -04:00
Matthias Clasen
9fdb71cbd2
icontheme: Add a missing getter
...
We want to have a get_display() method on every object
that is tied to the display, so add one here.
2020-10-03 13:11:20 -04:00
Matthias Clasen
ff7bcf738c
colorbutton: Properly override interface properties
...
This showed up in a test for missing property accessors.
2020-10-03 13:11:20 -04:00
Matthias Clasen
5640208f31
node-editor: Don't insert hyphens
...
This can be a bit confusing in multi-line strings.
2020-10-03 13:11:20 -04:00
Matthias Clasen
cef1cd19ff
gsk: Avoid long lines in serialized nodes
...
When encoding big blobs of data in base64, insert newlines.
Base64 allows it, CSS allows it, so not need to make GtkTextView
struggle with multi-megabyte lines.
Update nodeparser tests to reflect this change.
2020-10-03 13:10:55 -04:00
Matthias Clasen
279d3c08a9
gtk-demo: Rename the transition shader files
...
Easier to find them when their name matches the title
that we show in the UI.
2020-10-03 00:01:25 -04:00
Matthias Clasen
949f22b8b2
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
Closes #2261 and #1002
See merge request GNOME/gtk!2654
2020-10-03 03:55:32 +00:00
Matthias Clasen
19d760f9dd
gtk-demo: Fix a typo
2020-10-02 23:54:15 -04:00
Matthias Clasen
a9809b0f67
Allow inserting newlines in css strings
...
Rename _gtk_css_print_string to strip the _ and add
an insert_newlines argument to it. Update all callers,
and make the render node serializer insert newlines.
2020-10-02 23:40:16 -04:00
Matthias Clasen
9033336a23
css: Move _gtk_css_print_string around
...
Move this to a separate header, since it is not
parser functionality, and kill the duplicate
gtkcssparserprivate.h header.
2020-10-02 23:40:16 -04:00
Jakub Steiner
68ae8506d5
Merge branch 'stackswitcher-button-styling' into 'master'
...
Adwaita: Simplify stackswitcher button styling
See merge request GNOME/gtk!2498
2020-10-02 15:09:07 +00:00
Matthias Clasen
da8ee53e2d
emojichooser: Allow inserting multiple Emoji
...
Don't close the Emoji chooser when the Control
key is held while clicking. So you can insert
multiple Emoji without having to reopen the
chooser every time.
Fixes : #1002
2020-10-01 23:45:05 -04:00
Matthias Clasen
f6bd2f4d3f
Add a test for gsk_gl_shader_compile
...
This is not super useful, but at least we can
test that we get an error message including the
shader text.
2020-10-01 23:45:05 -04:00
Matthias Clasen
c9f3034e82
gdk: Remove an unused variable
2020-10-01 19:33:43 -04:00
Matthias Clasen
3cf8904d0b
Add GTK_INPUT_HINT_PRIVATE
...
Add a flag that requests that input methods should not
update personalized data (such as typing history).
Fixes : #2261
2020-10-01 17:14:58 -04:00
Matthias Clasen
c43d535aab
docs: Fix a copy-paste error
2020-10-01 17:07:53 -04:00
Matthias Clasen
f4bfa16136
Update the release script
...
If things go according to plan, we don't need to include
gtk-doc as a subproject in the next snapshot.
2020-10-01 15:14:33 -04:00
Matthias Clasen
4d90259b9b
Use gtk-doc from master
...
I've merged the relevant parts from the gtk-doc-for-gtk4
branch.
2020-10-01 15:11:37 -04:00
Matthias Clasen
ffb51b6888
Require gtk-doc 1.33
...
We'll hopefully get a gtk-doc release out with that
version number soon.
2020-10-01 15:09:26 -04:00
Matthias Clasen
dc3b140fd7
Cosmetics
2020-10-01 13:48:24 -04:00
Matthias Clasen
ce29545470
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
Closes #3220
See merge request GNOME/gtk!2652
2020-10-01 14:21:34 +00:00
Matthias Clasen
cbe3de9ce7
Merge branch 'master' into 'matthiasc/for-master'
...
# Conflicts:
# .gitlab-ci/test-msys2.sh
2020-10-01 13:56:37 +00:00
Matthias Clasen
6de7022458
Merge branch 'ci-win32-introspection-enabled' into 'master'
...
CI: Enable introspection again for the Windows build
See merge request GNOME/gtk!2651
2020-10-01 13:50:02 +00:00
Christoph Reiter
9601863569
CI: Enable introspection again for the Windows build
...
The underlying bug was fixed in glib and backported in MSYS2:
https://gitlab.gnome.org/GNOME/glib/-/merge_requests/1665
2020-10-01 15:16:18 +02:00
Matthias Clasen
c278261be0
Merge branch 'wip/jimmac/infosearch-close' into 'master'
...
Adwaita: close button for infobar, searchbar
Closes #3215
See merge request GNOME/gtk!2650
2020-10-01 12:01:23 +00:00
Matthias Clasen
028cd1e23a
Revert "Fix the build with cups < 2.3"
...
This reverts commit d761e3cf2c .
I am seeing PPD_CUSTOM_UNKNOWN in the cups headers in our
ci images, and that is cups 2.2.12. So this commit was
mistaken.
2020-10-01 07:59:30 -04:00
Matthias Clasen
6e7c0ce06b
ci: Give up on sysprof for now
...
Using sysprof and glib as subprojects of the same
project sadly does not work. Subprojects are not
as robust as they should be.
2020-10-01 07:37:44 -04:00
Jakub Steiner
81cfcba5ad
Adwaita: close button for infobar, searchbar
...
fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/3215
2020-10-01 13:14:25 +02:00
Matthias Clasen
9bac129707
ci: Try to get everything building again
...
It turns out that the sysprof meson setup does not
work with meson 0.54 :( So version 25 of our ci images
bumps the meson version to 0.55.3.
2020-09-30 23:43:03 -04:00
Matthias Clasen
91c8f6b7df
build: Try to fix docs+subprojects
...
Apparently, subprojects don't have pkgconfig variables :(
2020-09-30 16:21:39 -04:00
Matthias Clasen
103080c384
build: Remove an unneeded version check
...
We are requiring a newer meson than we were checking
for here.
2020-09-30 16:09:56 -04:00
Matthias Clasen
b936419125
ci: Remove --fatal-meson-warnings
...
meson adds features that then trigger warnings when we run
a newer meson over some of our subprojects. This is all too
fragile.
2020-09-30 15:53:15 -04:00
Matthias Clasen
72eb89eda7
gtk-demo: Add the shader paintable sources
...
This is currently not public GTK api, just part of
the demo. So we should show it here.
2020-09-30 15:41:05 -04:00
Matthias Clasen
b0da095944
gsk: Fix compiler warnings
...
We forgot to teach the broadway renderer about new enum
values, and our ci didn't catch it because werror didn't
actually work there until now.
2020-09-30 15:39:30 -04:00
Matthias Clasen
21c8bc2b47
build: Require meson 0.54
2020-09-30 15:26:20 -04:00
Matthias Clasen
7780b89e8a
ci: Really enable werror
...
We wanted to enable werror for gtk without enabling it
for all our subprojects. Sadly, we failed. Try again
2020-09-30 15:26:20 -04:00
Matthias Clasen
517a8406b0
ci: Use the v24 images
...
These images have meson 0.54.
2020-09-30 15:26:20 -04:00
Matthias Clasen
dfd16e3982
ci: Use a newer meson in images
...
We need meson 0.54.
2020-09-30 15:26:20 -04:00
Xavier Claessens
fd1e8afe9d
meson: Change introspection option to yielding feature
...
Yielding option means that if pango is built as a subproject, it will
take the value of that option from the parent project (e.g. gst-build).
For that to work it must be of the same type, which is "feature" instead
of "boolean" in all GStreamer modules.
2020-09-30 15:11:27 -04:00
Benjamin Otte
5829bc7c91
Use correct child widget when measuring
...
Fixes a copy/paste error.
Fixed #3220
2020-09-30 15:11:27 -04:00
Matthias Clasen
5a3aed8ade
Merge branch 'introspection' into 'master'
...
meson: Change introspection option to yielding feature
See merge request GNOME/gtk!2648
2020-09-30 17:50:21 +00:00
Benjamin Otte
5b89253fd9
Use correct child widget when measuring
...
Fixes a copy/paste error.
Fixed #3220
2020-09-30 17:48:24 +00:00
Matthias Clasen
fd631937f3
transition demo: Make buttons symbolic
...
It looks better.
2020-09-30 13:43:36 -04:00
Matthias Clasen
77ec961126
Merge branch 'ebassi/for-master' into 'master'
...
demo: Replace g_print with g_debug
See merge request GNOME/gtk!2645
2020-09-30 15:22:57 +00:00
Matthias Clasen
924e510512
gtk-demo: Update text for the transitions demo
...
The fire is gone, but we have wobbly widgets!
2020-09-30 11:19:12 -04:00
Matthias Clasen
97ffd94d20
Merge branch 'snazzy-demo' into 'master'
...
gtk-demo: Make gltransitions demo a bit snazzier
See merge request GNOME/gtk!2644
2020-09-30 15:00:58 +00:00
Alexander Larsson
d6648871b1
gtk-demo/gltransition: Replace fire background with more mellow blobs
2020-09-30 16:38:50 +02:00
Alexander Larsson
5d4a6940fa
gtk-demo: Use duck in transitions to get some alpha example
2020-09-30 16:25:30 +02:00
Xavier Claessens
0e5dac8c25
meson: Change introspection option to yielding feature
...
Yielding option means that if pango is built as a subproject, it will
take the value of that option from the parent project (e.g. gst-build).
For that to work it must be of the same type, which is "feature" instead
of "boolean" in all GStreamer modules.
2020-09-30 09:50:24 -04:00
Matthias Clasen
2dcf750198
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
See merge request GNOME/gtk!2647
2020-09-30 13:42:55 +00:00
Matthias Clasen
5fa765b284
Mention icon theme in the migration guide
...
This was requested in #3216 .
2020-09-30 08:55:39 -04:00
Matthias Clasen
9d701129cc
icontheme: Clarify the docs
...
Mention that icons directly in /$app_id/icons/ are treated
as unthemed icons.
See #3216
2020-09-30 08:55:39 -04:00
Alexander Larsson
e14d2be1e8
gl renderer: Fix render node texture cache
...
We're caching two things, either a node itself being rendered, or a
parent storing a cached version of a child as rendered to an offscreen
the size and location of the parent.
If both the parent and child uses the cache this will cause a conflict in
the cache as it is currently use keying of a node pointer which will have
the same value for the node-as-itself and the child-node-of-the-parent.
We fix this by adding another part to the key "pointer_is_child" which means
we can have the same node pointer twice in the cache.
Additionally, in the child-is-rendered-offscreen case the offscreen
result actually depends on the position and size of the parent viewport,
so we need to store the parent bounds in that case.
2020-09-30 14:53:13 +02:00
Emmanuele Bassi
b0a0f07bd7
demo: Replace g_print with g_debug
...
The GtkGears widget is a bit too chatty, especially when used inside
demos like the fishbowl. Let's use g_debug() instead of g_print() for
the GL debugging message.
2020-09-30 12:35:31 +01:00
Matthias Clasen
7defc3b759
Fix the release script some more
...
Still trying to master the tar commandline.
2020-09-30 06:51:46 -04:00
Alexander Larsson
e9885f9cde
gtk-demo: Make gltransitions demo a bit snazzier
...
This adds a bunch of snazz to the gltransitions demo. It is perhaps
a bit overloaded now, but it demos everything that we can do.
Changes:
* The fire shader is now not a bin, it just renders an animating
background with no textures involved.
* The stacks don't all start on the same page.
* The shaderbin passes the mouse coordinate to the shader.
* The shaderbin allows specifying a "border" so that you can
cause effects outside the bin child (something that is new to gtk4).
* All the buttons and the stacks are now in shader-bins that runs
a wobbly-widget effect based on the mouse position that
wobbles outside the child allocation.
2020-09-30 11:40:37 +02:00
Matthias Clasen
87393c7fb6
Merge branch 'small-cleanup' into 'master'
...
menubutton: Remove obsolete private method
See merge request GNOME/gtk!2643
2020-09-29 21:52:37 +00:00
Matthias Clasen
76d616909f
Merge branch 'ebassi/for-master' into 'master'
...
Ebassi/for master
See merge request GNOME/gtk!2642
2020-09-29 20:45:00 +00:00
Matthias Clasen
31069d5e96
release script: Fix doc tarball generation
...
Strip one level from the directories.
2020-09-29 15:07:13 -04:00
Florian Müllner
7ad42df727
menubutton: Remove obsolete private method
...
It was only added for the fallback app menu in headerbars, which
has been removed in the meantime.
2020-09-29 20:58:25 +02:00
Emmanuele Bassi
c6cedf608a
Add annotations for GtkBuildable virtual functions
...
Now that the functions that wrap them have gone away from the public
API, we need proper annotations for the virtual functions, otherwise
languages will not have enough information on nullable arguments and
ownership transfer.
2020-09-29 19:48:55 +01:00
Matthias Clasen
218b905a88
3.99.2
2020-09-29 14:44:31 -04:00
Matthias Clasen
00c6340777
gsk: Add some more shader docs
...
Do a pass over the docs and address minor inconsistencies,
cosmetics and formatting differences.
Mention GSK_DEBUG=shaders.
2020-09-29 14:44:31 -04:00
Matthias Clasen
687ed74d46
Merge branch 'snapshot-stack-optimize' into 'master'
...
Minor optimizations to GtkSnapshot state stack
See merge request GNOME/gtk!2641
2020-09-29 18:44:07 +00:00
Emmanuele Bassi
97276a5cd4
Remove gtk-doc stanzas from private GtkBuildable API
...
Various functions were moved to the private GtkBuildable header by
commit 2715b3ec31 , but the functions still
have gtk-doc stanzas.
2020-09-29 19:39:34 +01:00
Alexander Larsson
796e6ee306
snapshot: Preallocate and don't memset the state stack
...
Most of the time the snapshot is less than 16 levels deep (did some testing
in gtk-demo), so lets pre-allocate 16 levels of state stack to avoid the
extra allocation most of the time.
2020-09-29 16:03:06 +02:00
Alexander Larsson
18b8b499de
gdkarray: Add support for GDK_ARRAY_NO_MEMSET
...
If all your callers already initialize the array element as needed,
then we don't need to memset it to zero first.
This is pretty useful for the snapshot state stack, because due
to the per-node-type data area the elements on the stack are
quite large, but often a lot of it is not used.
2020-09-29 16:02:59 +02:00
Alexander Larsson
8a0dd452d2
gdkarray: Inline splice and reserve
...
This inlines the splice and reserver GdkArray calls. These are
typically only called from the gdk_array_(append/set_size) functions
anyway, and inlining the caller means we can constant propagate the
constant arguments in those calls. Its hard to get exact numbers, but
in fishbowl i noticed a significant decrease in the time spent in
the array code when pushing and poping states.
2020-09-29 15:57:33 +02:00
Matthias Clasen
4cfa9ee19f
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
See merge request GNOME/gtk!2639
2020-09-29 12:57:36 +00:00
Matthias Clasen
719c44a610
Merge branch 'glshader-track-uniform-state' into 'master'
...
gl: Track the current uniform state for custom programs
See merge request GNOME/gtk!2638
2020-09-29 12:49:22 +00:00
Matthias Clasen
4a2c817690
docs: Document various entry ::activate signals
2020-09-29 07:04:07 -04:00
Matthias Clasen
aac9414117
statusbar: Remove a misleading doc comment
2020-09-29 07:04:07 -04:00
Matthias Clasen
c897daf797
snapshot: Document radial gradient apis
2020-09-29 07:04:07 -04:00
Matthias Clasen
f1299410bf
docs: Fix a typo
2020-09-29 07:04:07 -04:00
Matthias Clasen
165768b6ad
wayland: Match header and doc arguments
...
gtk-doc doesn't take this lightly.
2020-09-29 07:04:07 -04:00
Matthias Clasen
07c338b487
gsk: Document radial gradient api
2020-09-29 07:04:07 -04:00
Matthias Clasen
3af249c046
Silence a compiler warning
...
These variables are not used anymore since
commit 11e4a46967 .
2020-09-29 07:04:07 -04:00
Matthias Clasen
91c3edba35
NEWS: Updates
2020-09-29 07:04:07 -04:00
Alexander Larsson
51ab56d33a
gl: Track the current uniform state for custom programs
...
This allows us to avoid updating uniforms if that is not necessary. This
in turn allows us to sometimes reuse the same draw op by just extending the
vertex array size we draw rather than doing a separate glDraw call.
For example, in the fishbowl demo, all the icons added at the same
time will have the same time and size, so we emit single draw calls
with 100s of triangles instead of 100s of draw calls with 2 triangles.
2020-09-29 11:52:39 +02:00
Alexander Larsson
2e5caa68bc
Merge branch 'glshader-node' into 'master'
...
Add support for GLShader nodes
See merge request GNOME/gtk!2594
2020-09-29 08:30:48 +00:00
Matthias Clasen
4e55220d76
Add some shader tests
...
These are just basic api usage tests, no rendering.
They found the issues fixed in the preceding commits.
2020-09-29 09:51:16 +02:00
Alexander Larsson
e76cb3e1e4
gtk-demo: Add a shader paintable to the fishbowl
...
This gets around 500 instances at 60fps on my system.
2020-09-29 09:51:16 +02:00
Alexander Larsson
8bcb031418
gtk-demo: Add GskGLShaderNode demo
...
Add adds a demo showing off GskGLShaderNode in various ways.
It has a transistion widget, using some examples from
gl-transitions.com, with child widgets being both images, a GL area
and real widgets (that let you edit the transition shaders
themselves.
It also has a fancy fire effect on hove on the buttons.
2020-09-29 09:51:16 +02:00
Alexander Larsson
4d697283ae
Support GLShaderNode in backends
...
For vulkan/broadway this just means to ignore it, but for the gl
backend we support (with up to 4 texture inputs, which is similar to
what shadertoy does, so should be widely supported).
2020-09-29 09:51:16 +02:00
Alexander Larsson
950cc41e15
GtkSnapshot: Add gtk_snapshot_push_glshader()
2020-09-29 09:51:16 +02:00
Alexander Larsson
7ea755e206
Add GskGLShaderNode and GskGLShader
...
A GskGLShader is an abstraction of a GLSL fragment shader that
can produce pixel values given inputs:
* N (currently max 4) textures
* Current arguments for the shader uniform
Uniform types are: float,(u)int,bool,vec234)
There is also a builder for the uniform arguments which are
passed around as immutable GBytes in the built form.
A GskGLShaderNode is a render node that renders a GskGLShader inside a
specified rectangular bounds. It renders its child nodes as textures
and passes those as texture arguments to the shader. You also pass it
a uniform arguments object.
2020-09-29 09:51:16 +02:00
Matthias Clasen
6e9b58b6f0
gsk: Add more shader debug spew
...
Print out the full assembled shader sources when
GSK_DEBUG=shaders is given. This is very verbose,
but may be useful to see what we actually pass
to the compiler.
2020-09-29 09:51:16 +02:00
Alexander Larsson
645fc6a9a5
GtkWindow: Create renderer before realizing child widgets
...
This way the child widgets can rely on the renderer (for example what
type it is) to decide details about how they render (such as if they
should use OpenGL shaders).
2020-09-29 09:51:16 +02:00
Matthias Clasen
a91b6b4786
css: Move the last parser api to the new header
...
This lets us use it from the render node parser
in gsk.
2020-09-29 09:51:16 +02:00
Alexander Larsson
16cdb33c6c
shadertoy demo: Fix GLSL on GLES
...
I was getting "assignment to varying fragColor" errors
2020-09-29 09:51:16 +02:00
Alexander Larsson
bacb3affb3
gl: Add some namespacing to the preamble symbols
...
This adds a gsk prefix to the stuff in the preamble, as we want to
avoid it conflicting with things in the main shader. Especially once
we start allow some customization of shaders.
2020-09-29 09:51:16 +02:00
Alexander Larsson
9460d0131f
gl backend: Add line numbers to source in glsl compilation errors
...
Almost always the source is created by combining various sources, which
means the line numbers in the error messages are hard to use. Adding
the line numbers to the source in the error message helps with this.
2020-09-29 09:51:16 +02:00
Alexander Larsson
7edcd1748c
gl: Properly report error if shader linking fails
...
In gsk_gl_shader_builder_create_program(), if linking fails we
need to return -1 to indicate error, rather than the old deleted
program id.
2020-09-29 09:51:16 +02:00
Alexander Larsson
6887d0ce24
glrenderer: Move ProgramState into Program
...
There is no real reason to have this on the side indexed via the
index, as it is stored next to each other anyway. Plus, storing them
together lets use use `Program` structures not in the array.
2020-09-29 09:51:10 +02:00
Matthias Clasen
e29c586b7c
Merge branch 'arnaudb/menubutton-direction' into 'master'
...
Make GtkMenuButton::direction more useful.
Closes #2811
See merge request GNOME/gtk!2636
2020-09-29 01:55:24 +00:00
Matthias Clasen
4f8a211c51
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
Closes #3202
See merge request GNOME/gtk!2637
2020-09-29 01:53:02 +00:00
Matthias Clasen
30b7545fb5
Add a reftest for flipping transforms
...
Verify that a scale of -1 does in fact cause a
gradient to go the other direction.
2020-09-28 21:07:51 -04:00
Matthias Clasen
a799c86edb
textbuffer: Elaborate docs
...
Explain a bit more what gtk_text_buffer_get_content_provider()
is for.
Fixes : #3202
2020-09-28 20:51:13 -04:00
Matthias Clasen
68bb532290
window: Don't get surfaces needlessly
...
There is a 1-1 correspondence between natives and
surfaces, so we can just compare the natives, no
need to get the surface for every single one.
2020-09-28 20:51:13 -04:00
Matthias Clasen
d2f0e3fa6b
doc: Document some apis as widget implementor only
...
A better solution for this would be nice. For the
time being, just add a sentence to the docs.
2020-09-28 20:51:13 -04:00
Arnaud Bonatti
4684082232
Make GtkMenuButton::direction more useful.
...
This property was only used until now when
there was neither an icon nor a label set,
for arrow direction and popover placement.
Starting with Gtk4, a GtkMenuButton with a
label shows an arrow at the right (in LTR)
of the label. Allow disabling the arrow or
changing its direction using the direction
property, to have a way to restore a Gtk3-
like look or to improve popover placement.
Fixes #2811 .
2020-09-29 02:26:13 +02:00
Matthias Clasen
5536a2ffe6
Merge branch 'wip/carlosg/for-master' into 'master'
...
gtkeventcontrollerscroll: Drop device type checks
Closes #3210
See merge request GNOME/gtk!2635
2020-09-28 22:03:36 +00:00
Carlos Garnacho
11e4a46967
gtkeventcontrollerscroll: Drop device type checks
...
Kinetic scrolling (and begin/end tracking) broke with commit cab1dcb696
since the pointing device used on X11 does not get as much GdkInputSource
granularity as the source device used to have in GTK3.
Actually this is kinda pointless, devices incapable of smooth scroll
should send discrete events, without those devices in the picture, we
want kinetic scroll to apply on every other device capable of smooth
scroll, so just do that.
Fixes: https://gitlab.gnome.org/GNOME/gtk/-/issues/3210
2020-09-28 23:35:36 +02:00
Yosef Or Boczko
01ddc181f9
Update Hebrew translation
...
(cherry picked from commit f6e3dfd73e )
2020-09-28 19:00:52 +00:00
Yosef Or Boczko
2b3c2962ab
Update Hebrew translation
...
(cherry picked from commit 02d1d9714e )
2020-09-28 18:59:32 +00:00
Matthias Clasen
27b3bb59eb
Merge branch 'another-attempt-to-fix-shadertoy' into 'master'
...
Flip GLArea textures
See merge request GNOME/gtk!2634
2020-09-28 16:16:51 +00:00
Matthias Clasen
ff61f35b77
Merge branch 'cloudproviders-ci' into 'master'
...
Cloudproviders ci
Closes #2480
See merge request GNOME/gtk!2632
2020-09-28 15:45:08 +00:00
Matthias Clasen
5206cfa837
Merge branch 'wip/otte/for-master' into 'master'
...
snapshot: Don't flip textures
See merge request GNOME/gtk!2633
2020-09-28 15:43:02 +00:00
Matthias Clasen
b711c12bbe
glarea: Flip our texture
...
The texture that produce is upside-down, compared to what
GSK expects, so flip things around with a transform.
This fixes the shadertoy demo being upside-down after a
recent fix to avoid downloading and reuploading the texture.
2020-09-28 11:34:23 -04:00
Matthias Clasen
431f144f37
gsk: Normalize when transforming bounds
...
Bounds are assumed to be normalized, and transforms
with negative scales or 3d rotations can make us get
negative sizes.
Fix by Benjamin Otte.
2020-09-28 11:34:16 -04:00
Benjamin Otte
651c92c0ed
snapshot: Don't flip textures
...
... or gradients or borders or shadows. Instead, ensure that affines
have non-negative scale factors. Otherwise add a transform node.
The only place where this check is not necessary is color nodes, but
special casing them seems not worth it.
2020-09-28 16:14:28 +02:00
Milo Casagrande
8487e82133
Update Italian translation
2020-09-28 07:41:47 +00:00
Aurimas Černius
15b635d7bd
Updated Lithuanian translation
2020-09-27 22:06:30 +03:00
Matthias Clasen
3aa2519c2b
ci: Use v23 images
...
I added libcloudproviders to the base image, but
now I see that we already enabled libcloudproviders
in the build anyway, so I'm a bit confused.
Fixes : #2480
2020-09-27 11:48:19 -04:00
Matthias Clasen
55bd6d08d4
ci: Add libcloudproviders to the image
...
Add libcloudproviders to fedora-base:v23 and fedora:v23.
This is so we can enable the cloud-providers feature in
our ci builds.
2020-09-27 11:41:04 -04:00
Matthias Clasen
536e1a1954
Merge branch 'patch-1' into 'master'
...
treestore: Document the fact that iter is modified by the function, in a machine-readable fashion.
See merge request GNOME/gtk!2613
2020-09-27 15:03:04 +00:00
Danny Milosavljevic
32baa0a549
Update gtktreestore.c: gtk_tree_store_remove didn't have the proper comment annotation
...
"inout" for the parameter ITER passed. This means that bindings would misjudge what
the function does. In the case of guile-gi, it would be misjudged for a predicate,
see gulie-gi bug 87.
2020-09-27 15:03:03 +00:00
Matthias Clasen
6f823cd0bd
Merge branch 'issue2627-gtk4' into 'master'
...
gdk/wayland: Replace gtk-primary-selection with primary-selection-unstable-v1
See merge request GNOME/gtk!2630
2020-09-27 14:51:23 +00:00
Matthias Clasen
97d052ef1b
Merge branch 'avoid-gl-texture-download' into 'master'
...
gsk: Avoid downloading GL textures when possible
See merge request GNOME/gtk!2628
2020-09-27 14:47:52 +00:00
Robert Mader
9ea0469ab0
gdk/wayland: Replace gtk-primary-selection with primary-selection-unstable-v1
...
The later is the public upstream version, while identical implementation wise.
https://gitlab.gnome.org/GNOME/gtk/-/issues/2591
2020-09-27 16:23:42 +02:00
Matthias Clasen
895c1681f0
Merge branch 'fontchooser-no-lang' into 'master'
...
fontchooser: Fix builds without PangoFT2
See merge request GNOME/gtk!2629
2020-09-27 12:42:42 +00:00
Matthias Clasen
9ca9f42452
gsk: Avoid downloading GL textures when possible
...
I found that the gears demo was spending 40% cpu
downloading a GL texture every frame, only to
upload it again to another context.
While the GSK rendering and the GtkGLArea use different
GL contexts, they are (usually) connected by sharing data
with the same global context, so we can just use the
texture without the download/upload dance. This brings
gears down to < 10% cpu.
2020-09-26 21:55:28 -04:00
Matthias Clasen
752270253f
fontchooser: Fix builds without PangoFT2
...
Currently, only if PangoFT2 is present and used it is supported
to retrieve the languages that are supported by a particular font.
If we don't have PangoFT2, remove the language filtering and the
sample text selection.
Based on earlier work by Chun-wei Fan, see
https://gitlab.gnome.org/GNOME/gtk/-/merge_requests/2614
2020-09-26 19:15:45 -04:00
Matthias Clasen
92e551f895
Merge branch 'BUG_gtktreeview_headers_focus_on_click_GTK4' into 'master'
...
GtkTreeviewColumn: don't focus-on-click header buttons
See merge request GNOME/gtk!1806
2020-09-26 22:50:23 +00:00
Matthias Clasen
593907f7b0
testupload: Test more formats
...
Copy the format conversion code from GdkMemoryTexture
so we can produce all formats, and test them all.
The upload fast paths assume that the stride is a
multiple of four, so some of the padding values cause
it to fail. Apart from that, things seem to work for
all combinations.
2020-09-26 17:26:12 -04:00
Matthias Clasen
34ec226852
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
See merge request GNOME/gtk!2626
2020-09-26 14:00:32 +00:00
Matthias Clasen
d56ad7c40c
Add a test for various texture uploads
...
Create textures with various characteristics (alpha, premultiplication,
stride) that trigger different code paths in the gl texture upload
function, and show the resulting images. If all goes well, they all
should look the same.
On my system, this tests texture upload for memory formats
GDK_MEMORY_B8G8R8A8_PREMULTIPLIED, GDK_MEMORY_R8G8B8A8, and
GDK_MEMORY_R8G8B8, and it works with both gl and gles.
2020-09-26 09:20:00 -04:00
Matthias Clasen
ae09e20e8a
NEWS: Updates
2020-09-26 09:04:42 -04:00
Matthias Clasen
54944c9cea
Merge branch 'fix-texture-upload-more' into 'master'
...
More texture upload fixes
Closes #3198
See merge request GNOME/gtk!2624
2020-09-26 12:52:25 +00:00
Matthias Clasen
fe8986f2d5
Merge branch 'matthiasc/for-master' into 'master'
...
gl: Make debug spew more complete
Closes #3197
See merge request GNOME/gtk!2623
2020-09-26 02:02:13 +00:00
Matthias Clasen
d6912a6791
More texture upload fixes
...
In some cases, with bpp == 3 and a rowstride
that is divisible by 4, we were passing invalid
parameters to GL.
Fixes : #3198
2020-09-25 21:59:33 -04:00
Matthias Clasen
db4b7e3d11
Merge branch 'add-child-clash' into 'master'
...
Make GtkBuildable vfunc accessor functions private
Closes #3191
See merge request GNOME/gtk!2619
2020-09-26 01:17:08 +00:00
Matthias Clasen
6cdbf1a352
popup: Fix up a doc blurb
...
The GdkPopup:autohide property was mis-documented.
Fixes : #3197
2020-09-25 20:43:01 -04:00
Matthias Clasen
3d881752bf
gl: Make debug spew more complete
...
List GL_EXT_unpack_subimage among the extensions
we check for.
2020-09-25 20:42:01 -04:00
Matthias Clasen
1b93108d10
Merge branch 'fix-rgb-upload' into 'master'
...
gl: Fix RGB uploads
Closes #3194
See merge request GNOME/gtk!2620
2020-09-26 00:30:31 +00:00
Florian Müllner
e4d4b50d6d
docs: Document GtkBuildable changes in migration guide
...
https://gitlab.gnome.org/GNOME/gtk/-/issues/3191
2020-09-26 02:16:57 +02:00
Florian Müllner
2715b3ec31
buildable: Make vfunc accessor functions private
...
With the exception of gtk_buildable_get_id(), those are only used
to construct objects from XML descriptions, which is functionality
internal to GTK.
The API is therefore unlikely to be missed, and keeping it internal
means they can no longer unintentionally shadow object methods in
bindings with less namespacing; for example it's currently ambiguous
whether `infoBar.add_child()` refers to gtk_info_bar_add_child() or
gtk_buildable_add_child().
https://gitlab.gnome.org/GNOME/gtk/-/issues/3191
2020-09-26 02:16:57 +02:00
Florian Müllner
12189bc10f
buildable: Rename set_name() to set_buildable_id()
...
GtkBuildable's get_name()/set_name() methods may shadow
GtkWidget's methods. Avoid that by renaming the API to
get_buildable_id()/set_buildable_id(), which also reflects
the name of the XML attribute the API refers to.
https://gitlab.gnome.org/GNOME/gtk/-/issues/3191
2020-09-26 02:16:05 +02:00
Matthias Clasen
3db217ab7a
gl: Reset GL_UNPACK_ALIGNMENT
...
Reset GL_UNPACK_ALIGNMENT to its initial value of 4 after
changing it for a glTexImage2D call.
2020-09-25 16:17:45 -04:00
Matthias Clasen
a9de1d702e
Merge branch 'matthiasc/for-master' into 'master'
...
columnview: Simplify column constructors
See merge request GNOME/gtk!2622
2020-09-25 18:25:09 +00:00
Matthias Clasen
0c3f42e06e
columnview: Simplify column constructors
...
Drop gtk_column_view_column_new_with_factory and
just make gtk_column_view_column_new accept a
nullable factory. This follows what we've been
doing elsewhere.
Update all callers.
2020-09-25 13:57:10 -04:00
Matthias Clasen
d4b740ce62
Merge branch 'wip/carlosg/for-master' into 'master'
...
Wip/carlosg/for master
Closes #3125 and #3121
See merge request GNOME/gtk!2621
2020-09-25 17:49:59 +00:00
Carlos Garnacho
d9d494826f
gtkbutton: Clean up priv->in_button
...
This is now only toggled around, may be cleaned up.
2020-09-25 19:20:27 +02:00
Carlos Garnacho
ea6e575901
gtkbutton: Check release coordinates on all release event types
...
The priv->in_button state that used to be relied upon for pointer
events has been reduced over time to a broken state, since the button
does not track crossing events anymore.
Make the coordinate-based checks apply for pointer events too, besides
touch events. This fixes GtkButton mistakenly emitting ::clicked with
pointer button releases outside the widget.
Fixes: https://gitlab.gnome.org/GNOME/gtk/-/issues/3121
2020-09-25 19:20:04 +02:00
Matthias Clasen
12f05e80aa
gl: Fix RGB uploads
...
I don't really know what to say, other than:
OpenGL is terrible
Fixes : #3194
2020-09-25 13:16:47 -04:00
Carlos Garnacho
0ccdbfd802
gtktextview: Avoid GtkGestureClick claiming on touch press
...
We still want the drag gesture (and text selection) to work. Avoid claiming
the gesture early, like it's done in the pointer case.
2020-09-25 19:02:26 +02:00
Carlos Garnacho
7d5accc69f
gtkscrolledwindow: Do not eagerly claim touch press event
...
Claiming early makes the contents unable to react to the touch press
event. Do this on GtkGestureDrag::update past a threshold, so the
child widget(s) can claim before the scrolledwindow does.
Fixes: https://gitlab.gnome.org/GNOME/gtk/-/issues/3125
2020-09-25 18:58:44 +02:00
Carlos Garnacho
b1606db839
gtkscrolledwindow: Drop gtk_scrolled_window_set_capture_button_press()
...
This API is kinda stuck in the GdkEvent days, we now negotiate ownership
of the input sequence via GtkGestures. Remove it as it reflects a way to
work that was not exactly accurate and it will turn plainly wrong soon.
2020-09-25 18:57:40 +02:00
Matthias Clasen
c9f6a9f7c5
Merge branch 'gles-texture-colors' into 'master'
...
Fix uploads of textures in GLES (and make texture uploads better)
See merge request GNOME/gtk!2616
2020-09-25 14:53:19 +00:00
Timm Bäder
09564a5798
Merge branch 'wip/baedert/for-master' into 'master'
...
Wip/baedert/for master
See merge request GNOME/gtk!2617
2020-09-25 13:35:20 +00:00
Alexander Larsson
a299bbfc58
Drop gdk_cairo_surface_upload_to_gl() helper
...
There is nothing really special about this code, its just a helper for
uploading pixel data to opengl, and we're not really in the business
of doing opengl-specific helper functions.
2020-09-25 15:00:07 +02:00
Alexander Larsson
90fc671ef8
gl backend: Avoid roundtripping via surface when updloading
...
Do custom uploads rather than using gdk_cairo_surface_upload_to_gl(),
because this way we avoids a roundtrip (memcpy and possibly conversion)
to the cairo image surface format.
2020-09-25 10:04:48 +02:00
Alexander Larsson
c71921a6be
gdk_gl_context_upload_texture() avoid conversion for pixbuf format
...
The gdk-pixbuf non-rgba format can be directly uploaded without
conversion.
The rgba format needs alpha premultiplication though, which is not
supported by GL during upload.
2020-09-25 09:31:43 +02:00
Alexander Larsson
1001995d49
Correctly upload textures for GLES
...
GLES doesn't support the GL_BGRA + GL_UNSIGNED_INT_24_8 hack that
we use on desktop OpenGL to upload textures directly in the cairo
pixel format. This adds the required conversions to all the places
that currently need it.
We also add a data_format to the internal gdk_gl_context_upload_texture()
function to make it clearer what the format are. Currently it is always
the cairo image surface format, but eventually we want to support other
formats so that we can avoid some of the unnecessary conversions we do.
Also, the current gdk_gl_context_upload_texture() code always converts
to a cairo format and uploads that like we did before. Later commits
will allow this to use other upload formats that gl supports to avoid
conversions.
2020-09-25 09:31:43 +02:00
Alexander Larsson
8e59cdabac
Add GDK_MEMORY_R8G8B8A8_PREMULTIPLIED
...
This is the default OpenGL format, and in fact the only pixel format
that GLES supports uploading as. Actually, the premultiplied part is
really just about how we use the textures, but all textures in GTK
are premultiplied.
2020-09-25 09:31:43 +02:00
Alexander Larsson
88b709d5ec
texture: Unvirtualize download_surface
...
We only have one implementation, so why do all this vfunc work?
2020-09-25 09:31:43 +02:00
Matthias Clasen
e6d5a3c4e8
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
Closes #3180 , #3178 , and #3179
See merge request GNOME/gtk!2618
2020-09-24 18:50:26 +00:00
Matthias Clasen
e70ed905d1
columview: Don't overdraw
...
Just always tell the title and cell widgets to
clip their children to the right size. Otherwise
we risk things getting out of sync and unintended
overdraw.
Fixes : #3179
2020-09-24 14:30:40 -04:00
Matthias Clasen
7eb0ae39c5
columview: Fix column resizing
...
We were not handling the fixed_width quite right,
and that was causing screaming from the GTK size
allocation machinery.
Fixes : #3178
2020-09-24 14:18:38 -04:00
Timm Bäder
2f93287473
cssimagefallback: Whitespace
2020-09-24 19:08:22 +02:00
Timm Bäder
484dcc043b
cssimagefallback: Avoid allocating GPtrArray for colors
...
If we just parse a color, like image(#FFF), avoid allocating the
GPtrArray to store images. This happens in Adwaita for background images
of backdrop buttons. We save around 70 GPtrArrays this way.
2020-09-24 19:08:22 +02:00
Timm Bäder
716b5afe6a
Adwaita: Fix calendar header button backdrop bg color
2020-09-24 19:08:22 +02:00
Timm Bäder
fd728ea8bc
gl renderer: Lower maximum gradient stop count
...
6 is still plenty according to my market research.
Should help with #2624
2020-09-24 19:08:22 +02:00
Timm Bäder
8d7b3bade3
gl renderer: Fall back to cairo if gradients use too many stops
2020-09-24 19:08:22 +02:00
Timm Bäder
12cc178756
textbuffer: Don't try to inset NULL text from clipboard
...
That used to generate a critical error message.
Also free() the data.
2020-09-24 19:08:22 +02:00
Timm Bäder
9eaa8bd1e7
gl renderer: Only return error if creating programs failed
2020-09-24 19:08:22 +02:00
Timm Bäder
15994db74d
gl renderer: Use scale_x/y when rendering clipped nodes
2020-09-24 19:08:22 +02:00
Timm Bäder
467be0b7dc
gl renderer: Don't use ops_get_scale() when rendering clip nodes
...
Differentiate between scale_x and scale_y. This works better for e.g.
transform nodes using scaleX().
2020-09-24 19:08:22 +02:00
Timm Bäder
84d2a33c10
gl renderer: Support scaleX/Y better when rendering radial gradients
...
We should do this everywhere, but this is a start.
2020-09-24 19:08:22 +02:00
Matthias Clasen
9fde0137a0
listview: Avoid a critical when reordering
...
When sorting a cell into the place its already at,
we were triggering criticals. Avoid that.
Fixes : #3180
2020-09-23 22:53:21 -04:00
Matthias Clasen
9dab51e7be
Merge branch 'matthiasc/for-master' into 'master'
...
Matthiasc/for master
Closes #3188
See merge request GNOME/gtk!2612
2020-09-23 22:44:22 +00:00
Matthias Clasen
810218b2f5
fontchooser: Don't center the list
...
The centered layout of the font previews don't look appealing
and make it harder to judge the relative width and weight of
the individual styles.
Fixes : #3188
2020-09-23 16:32:48 -04:00
Balázs Úr
7acbbd6bdd
Update Hungarian translation
2020-09-23 15:25:12 +00:00
Balázs Úr
a364ab1efb
Update Hungarian translation
2020-09-23 14:39:40 +00:00
Thomas Holder
4325c20013
gtktreeview: Fix child access after TEST_EXPAND_ROW
...
In gtk_tree_view_build_tree with recurse=TRUE, the TEST_EXPAND_ROW
signal might invalidate the child iterator. Getting the iterator after
the signal (instead of before) fixes the issue.
Fixes https://gitlab.com/inkscape/inkscape/-/issues/1879
2020-09-23 07:53:33 -04:00
Matthias Clasen
7bae48335f
Merge branch 'wip/jimmac/osd-spinbutton' into 'master'
...
Adwaita: osd spinbutton specificity bump
Closes #2769
See merge request GNOME/gtk!2610
2020-09-23 11:47:01 +00:00
Matthias Clasen
571f15cac6
Merge branch 'make-claiming-button-release-work' into 'master'
...
gestures: Make claiming button release work
See merge request GNOME/gtk!2576
2020-09-23 11:35:59 +00:00
Jakub Steiner
78236bfdbe
Adwaita: osd spinbutton specificity bump
...
- mimic the peculiar selector from the normal style onto osd to
override.
Fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/2769
2020-09-23 10:16:55 +02:00
Matthias Clasen
53dddf163d
gestures: Make claiming button release work
...
When claiming a sequence in a gesture signal handler,
the expected result is that GtkGesture::handle-event
returns TRUE, causing the event to not be propagated
further.
This doesn't work for button release events, since
gtk_gesture_handle_event does the following:
add point
emit ::update
remove point
check claimed status
The ::update signal is where the application code
claims the sequence. But removing the point purges
the sequence from the gestures memory, so checking
the claimed status returns FALSE.
This patch fixes things to behave as expected, by
checking the claimed status before removing the point.
2020-09-14 08:35:44 -04:00
nana-4
68379c3ff7
Adwaita: Simplify stackswitcher button styling
...
Simply use negative margins against the padding.
Also remove the indicator only when the .needs-attention style class is
removed.
2020-08-28 22:06:44 +09:00
Nelson Benítez León
ba9b4f418d
GtkTreeviewColumn: don't focus-on-click header buttons
...
currently when mouse clicking on a column header
to sort it it is grabbing keyboard focus, this
should not happen, keyboard focus should remain
where it was before. This can be seen on the
GtkFileChooser widget, when having the keyboard
focus on the file list items and clicking on a
column header to sort it the keyboard focus is
now on the header.
2020-04-30 22:59:08 -04:00
Sean Farley
99dfdfcd5e
Allow LPR backend to print PDF and PS file formats
...
At least from GTK v3.22.30, the code disallows attempts to print PDF and
PS files using the LPR backend. Although it is not easy or possible for
GTK to determine if the printer can print these formats by querying lpr,
the print backend should allow lpr to try.
There are two uses cases:
- A filter is being used by lpr, specified in the printcap file, to process the
files prior to printing them.
- The printer can print PDF and PS files directly. There are many printers that
can print these formats, so GTK should allow for the possibility.
2018-11-17 13:04:35 -05:00