Commit Graph

80230 Commits

Author SHA1 Message Date
Matthias Clasen
cda4ec48b2 Merge branch 'doc-fixes' into 'main'
gskpathbuilder: Fix doc typo

See merge request GNOME/gtk!7200
2024-04-29 03:52:04 +00:00
Matthias Clasen
d9582c123e inspector: Cosmetics
We've been using title capitalization and spelled out names
in the node details pane, so be consistent.
2024-04-28 23:44:18 -04:00
Matthias Clasen
4d30aacb0c Reencode all our symbolic pngs
This adds the only-foreground information and will let us use
these symbolics more efficiently.
2024-04-28 23:42:02 -04:00
Matthias Clasen
4862c3f779 Add 'only foreground' to texture utility api
Add an 'only_fg' argument to all our internal texture utility
api, so GtkIconTheme can find out if a symbolic png or svg uses
colors beyond the foreground or not.

This information is used in gtk_symbolic_paintable_snapshot_symbolic
to optimize rendering of such symbolic icons.
2024-04-28 23:42:02 -04:00
Matthias Clasen
08d1353cde loaders: Make it possible to load png options
We want to store some metadata in our symbolic pngs, so make it
possible to get options when loading a png, along with the texture.

Update all callers.
2024-04-28 23:42:02 -04:00
Matthias Clasen
585dadf575 Small optimization
Avoid copying a potentially large blob more than necessary.
2024-04-28 23:42:02 -04:00
Joshua Lee
d069eb173a path builder: Fix doc typo 2024-04-28 22:24:38 +01:00
Matthias Clasen
6015560b63 Merge branch 'wip/otte/for-main' into 'main'
various fixes

Closes #6668 and #6656

See merge request GNOME/gtk!7194
2024-04-28 19:44:58 +00:00
Benjamin Otte
5a776389d7 reftests: Use longer words when testing wrapping
"Hello" might be shorter than "Hi Ho" in some fonts and then that one
gets wrapped, too.

So choose perfectly cromulent words for this purpose instead.
2024-04-28 13:51:42 +02:00
Benjamin Otte
6c2dfed5a5 inspector: Add details for textures
In particular, add all the dmabuf texture details.

I originally wanted this just to see if a texture was the type I
expected it to be while debugging, but then I thought "why not add the
rest, too?"

I did not add GL-internal texture details (like GL format,
internalformat etc), because that would require a make_current().
2024-04-28 13:51:42 +02:00
Benjamin Otte
7dec24c2cc inspector: Make add_text_row() be a printf-style function
There's a few cases where I had to add "%s" as the format string, but
most changes got rid of printf() + free() combinations.
2024-04-28 13:51:42 +02:00
Benjamin Otte
c20e7a0c5d glcontext: Split dmabuf import codepaths
Use different codepaths for known formats vs unknown formats.

Be more careful with unknown formats and always import them as
GL_TEXTURE_EXTERNAL_OES when possible (GL can't do EXTERNAL) to avoid
problems.

This is a more defensive approach towards older drivers that don't
support modifiers.

This fixes importing YUV textures on AMD Gen8.

Another approach would be to check for YUV and never try
GL_TEXTURE_2D with them, but I decided to go this way first.

Fixes #6668
2024-04-28 13:51:42 +02:00
Benjamin Otte
719021e1f4 gpu: Handle tiny offscreens
Due to rounding errors, it is possible after intersecting a lot of
rectangles to end up with a tiny size for an offscreen. And because we
allow an epsilon before ceil()ing to an integer (see commit afc7b46264
for details) it is now possible that we end up with a size of 0.

Avoid that by always enforcing a minimum size of 1px.

Test included

The test uses a different codepath to arrive at the same problem - it
specifies the small size instead of triggering it via rounding errors
and clipping like the original bug (and most likely the more common case
to encounter this problem.

Fixes #6656
2024-04-28 13:51:42 +02:00
Benjamin Otte
4856e115a9 path: document enum 2024-04-28 08:33:03 +02:00
Matthias Clasen
bfb5bbe862 Merge branch 'matthiasc/for-main' into 'main'
wayland: Break out dmabuf feedback code

See merge request GNOME/gtk!7193
2024-04-27 23:09:20 +00:00
Matthias Clasen
b98c86fb7b wayland: Break out dmabuf feedback code
This will need to be used in surfaces as well, in the future.
Prepare for that by moving this code into its own file and struct.
2024-04-27 11:47:26 -04:00
Matthias Clasen
e01c3f581e Merge branch 'fix-profiler-mark' into 'main'
gsk: Fix a profiler mark

See merge request GNOME/gtk!7192
2024-04-27 15:47:01 +00:00
Matthias Clasen
c45199e388 gsk: Fix a profiler mark
I messed this up in f26efd9adf.
2024-04-27 10:23:45 -04:00
Matthias Clasen
27fb9917d8 Merge branch 'matthiasc/for-main' into 'main'
atcontext: Add a few missing values

Closes #6575

See merge request GNOME/gtk!7190
2024-04-26 23:16:31 +00:00
Matthias Clasen
b5d6613a3f atcontext: Add a few missing values
Add a missing value to the naming array, and sort the recent additions
alphabetically.

Fixes: #6575
2024-04-26 18:46:00 -04:00
Matthias Clasen
5dc77edbe3 Merge branch 'matthiasc/for-main' into 'main'
linkbutton: Report errors

Closes #6446

See merge request GNOME/gtk!7189
2024-04-26 22:26:14 +00:00
Matthias Clasen
a3d63b3579 label: Report errors
Print a warning when launching a handler fails.
2024-04-26 17:25:27 -04:00
Matthias Clasen
57c12a8661 linkbutton: Report errors
Print a warning when launching a handler fails.

Fixes: #6446
2024-04-26 17:25:13 -04:00
Matthias Clasen
f1ccb9b81a Merge branch 'vulkan-gl-texture-warning' into 'main'
vulkan: Add a warning about GL textures

See merge request GNOME/gtk!7184
2024-04-26 20:16:27 +00:00
Matthias Clasen
2711cb8dcd Merge branch 'wip/xdg-activation-token' into 'main'
Improve xdg-activation-token handling for non-dbus activation

See merge request GNOME/gtk!7118
2024-04-26 18:32:08 +00:00
Matthias Clasen
c79925bd4a Merge branch 'listview-oversights' into 'main'
listview: Fix some oversights

See merge request GNOME/gtk!7187
2024-04-26 18:27:49 +00:00
Matthias Clasen
05d5860dc0 listview: Fix some oversights
The list factory widget was notifying the wrong properties.
2024-04-26 11:19:59 -04:00
Matthias Clasen
a1fdf06d80 gsk: Add a warning for inefficient texture import
With GSK_DEBUG=fallback, warn if a non-memory texture has to be
downloaded for importing it into Vulkan or GL.
2024-04-26 11:04:47 -04:00
Matthias Clasen
36d7ca058e Cosmetics 2024-04-26 10:59:21 -04:00
Matthias Clasen
2e08db91ca Merge branch 'offload-snapshot-no-child' into 'main'
Don't crash if snapshotting a GtkGraphicsOffload without child

See merge request GNOME/gtk!7183
2024-04-25 20:46:31 +00:00
Sebastian Dröge
2c9b47ff3c Don't crash if snapshotting a GtkGraphicsOffload without child 2024-04-25 22:46:35 +03:00
Matthias Clasen
62ad1a61dc Merge branch 'matthiasc/for-main' into 'main'
offload: Make logging more compact

See merge request GNOME/gtk!7181
2024-04-25 03:01:44 +00:00
Matthias Clasen
3fc9de7539 offload: Make logging more compact
Use a format of

[XXX] SYMBOL DETAILS

where SYMBOL indicates the offloading status:
 🗙 - no offload
 ▲ - offload above, with background
 △ - offload above, no background
 ▼ - offload below, with background
 ▽ - offload below, no background
2024-04-24 22:01:56 -04:00
Matthias Clasen
1c9a55d185 Merge branch 'vulkan-msvc' into 'main'
gskvulkandescriptors.c: Don't return value from void-rettype function

See merge request GNOME/gtk!7175
2024-04-25 01:37:49 +00:00
Matthias Clasen
492940205e Merge branch 'amolenaar/macos-fix-nsapp-shortcuts' into 'main'
macos: fix in-app native shortcuts (regression)

See merge request GNOME/gtk!7178
2024-04-25 01:35:59 +00:00
Arjan Molenaar
985e4906c8 macos: Add some docs for the different NSEvent getters 2024-04-24 23:49:37 +02:00
Benjamin Otte
e9dcf8167c Merge branch 'gbsneto/vulkan-dmabuf-general' into 'main'
vulkan/image: Use GENERAL for initial layout of DMA-BUF textures

See merge request GNOME/gtk!7179
2024-04-24 20:55:51 +00:00
Georges Basile Stavracas Neto
3aa6c27c26 vulkan/image: Use GENERAL for initial layout of DMA-BUF textures
The VK_IMAGE_LAYOUT_UNDEFINED layout means that the data hold by the
texture can be discarded, and we don't want to discard it. Because the
Vulkan spec is unclear (see [1] for a discussion), err on the side of
caution and use VK_IMAGE_LAYOUT_GENERAL.

Fixes import failures with WebKit.

[1] https://github.com/ValveSoftware/gamescope/issues/356
2024-04-24 17:21:51 -03:00
Emmanuele Bassi
f537a55b71 Coding style fixes 2024-04-24 11:57:00 +01:00
Emmanuele Bassi
7075e6be89 Merge branch 'gst-backend-msvc' into 'main'
GStreamer media backend: Fix building on Visual Studio

See merge request GNOME/gtk!7174
2024-04-24 10:04:11 +00:00
Chun-wei Fan
016354b6dd gskvulkandescriptors.c: Don't return value from void-rettype function
Fixes builds on Visual Studio with Vulkan enabled, as later GLib releases
consider this as an error on Visual Studio builds.
2024-04-24 16:19:43 +08:00
Chun-wei Fan
1dfc6d65df GStreamer media backend: Fix building and running on Windows
Visual Studio (and possibly other non-GCC compilers) do not like
uses of #-preprocessor directives in macro usage (warning C5101: use of
preprocessor directive in function-like macro argument list is undefined
behavior is also shown), so fix the build by defining another macro
accordingly.
2024-04-24 16:15:32 +08:00
Matthias Clasen
b7d0295481 Merge branch 'macos-default-settings' into 'main'
macos: Respect the default-settings debug key

See merge request GNOME/gtk!7173
2024-04-23 16:38:00 +00:00
Matthias Clasen
a2854af325 macos: Respect the default-settings debug key
This makes our behavior more consistent across platforms.
The suggestion came up in discussion in #6545.
2024-04-23 07:52:25 -04:00
Changwoo Ryu
320496b039 Update Korean translation
(cherry picked from commit e1dafd7a5d)
2024-04-23 11:33:48 +00:00
Lukáš Tyrychtr
b0450d4b1b Do not perform a changed help-text check twice 2024-04-23 11:40:51 +02:00
Lukáš Tyrychtr
91ff8bf336 The new member needs a separate docblock 2024-04-23 11:40:51 +02:00
Emmanuele Bassi
7b145f72dc Apply review feedback fixes 2024-04-23 11:40:51 +02:00
Lukáš Tyrychtr
0dcc21b605 4.14 did not cut it 2024-04-23 11:40:51 +02:00
Lukáš Tyrychtr
bd43a9e868 Document the new property 2024-04-23 11:40:51 +02:00