GTK_ACCESSIBLE_ROLE_GENERIC is for
"a nameless container that has no semantic meaning of its own",
for which AT-SPI role ATSPI_ROLE_PANEL [1]
("A generic container that is often used to group
objects.") fits better than ATSPI_ROLE_FILLER
("A object that fills up space in a user interface."),
so map to this one.
With this in place, widgets like GtkBox are again
reported with the panel role on AT-SPI level after
commit a86923de94
("a11y: Change the role for many containers"),
whose commit message suggests that the change
on the AT-SPI level was unintended.
For GTK_ACCESSIBLE_ROLE_GROUP, use the corresponding
ATSPI_ROLE_GROUPING ("A group of related widgets.
This group typically has a label.").
[1] https://docs.gtk.org/atspi2/enum.Role.html
In order for the size change check to make sense, vk_pipeline_cache_size
needs to correspond to the size of the cache we last wrote to disk.
We were forgetting to update it after saving the cache, so the
check was ineffective.
If the svg doesn't use the symbolic style classes, we can avoid
loading it multiple times.
This brought the time for loading system-run-symbolic at 256@2
from 6.8ms down to 2ms.
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.
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.
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().
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
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