Commit Graph

65121 Commits

Author SHA1 Message Date
Matthias Clasen
8c66e2ff66 widget: Drop unnecessary includes
We don't need to include gobjectnotifyqueue.c anymore,
since style properties are gone. This should fix the
build with -Werror.
2020-07-31 10:34:37 -04:00
Florentina Mușat
360ffb8e87 Update Romanian translation 2020-07-31 13:42:35 +00:00
Yuri Chornoivan
731b672875 Update Ukrainian translation 2020-07-31 12:52:54 +00:00
Daniel Mustieles
d5a31daa41 Updated Spanish translation 2020-07-31 13:48:24 +02:00
Matthias Clasen
554954d126 3.99.0 2020-07-30 22:16:31 -04:00
Matthias Clasen
73477b5abf testsuite: Use Wayland by default
I'm tired of xwayland crashing and killing my shell.
2020-07-30 22:16:31 -04:00
Matthias Clasen
62803c19f5 Merge branch 'focus-active' into 'master'
Focus active

Closes #2390

See merge request GNOME/gtk!2324
2020-07-30 17:50:54 +00:00
Matthias Clasen
643d873f47 eventcontrollerkey: Update im focus when active window changes
Use the new GTK_CROSSING_ACTIVE crossing events to update
the im context focus when the window becomes active or
inactive. IBus requires this, since it has only a single,
global focus location.

Fixes: #2390
2020-07-30 13:23:45 -04:00
Matthias Clasen
b0d40403e1 window: Emit GTK_CROSSING_ACTIVE crossing events
Emit crossing events when the active window changes.
We don't want to emit GTK_CROSSING_FOCUS events, since
every window has its own focus location (focus does not
jump from window to window), so we use the new
GTK_CROSSING_ACTIVE type of crossing event for this.
2020-07-30 13:22:26 -04:00
Matthias Clasen
12170acf46 Define GTK_CROSSING_ACTIVE
Document the different crossing event kinds that we use,
and add GTK_CROSSING_ACTIVE. We are going to use it in
the future when the active window changes.
2020-07-30 13:21:28 -04:00
Matthias Clasen
38648855b0 Merge branch 'wip/carlosg/more-device-api-cleanup' into 'master'
More device API cleanup

See merge request GNOME/gtk!2323
2020-07-30 17:01:15 +00:00
Carlos Garnacho
96452a2e46 gdk: Rename gdk_seat_get_physical_devices() to gdk_seat_get_devices()
We don't want to tell what they are, and the distinction is now less
clear. Remove the adjective from the function name.
2020-07-30 18:44:40 +02:00
Carlos Garnacho
46eb054337 gdk: Drop gdk_device_get_device_type()
There is no longer a hierarchy of devices, or none that is seen
on the outside.
2020-07-30 18:44:40 +02:00
Carlos Garnacho
4a2050e220 gdk/x11: Make device type a X11 detail
The only legit uses of device types are here in gdk/x11, move the
concept of device type to X11, so we can drop it from public API.
2020-07-30 18:30:13 +02:00
Carlos Garnacho
3c68db8e47 gdk: Make gdk_device_list_physical_devices() private
Physical devices should probably be accounted internally in gdk/x11,
make this out of private API so at least the implementation details
don't leak.
2020-07-30 18:30:13 +02:00
Carlos Garnacho
9912c80d70 gdk: Drop gdk_device_get_associated_device()
Devices are no longer associated like this, the seat should be used
to resolve queries on other devices.
2020-07-30 18:30:13 +02:00
Carlos Garnacho
2f792396d7 gtkimcontext: Avoid gdk_device_get_associated_device()
Query the seat for that.
2020-07-30 18:30:13 +02:00
Carlos Garnacho
6730b26b43 gtktextview: Avoid gdk_device_get_associated_device()
Query the seat for that.
2020-07-30 18:30:13 +02:00
Carlos Garnacho
6e83d1f54e gtkwindowhandle: Avoid gdk_device_get_associated_device()
Query the seat for that.
2020-07-30 18:19:44 +02:00
Carlos Garnacho
fb9db7fede gtkdragsource: Avoid gdk_device_get_associated_device()
Query the seat for that.
2020-07-30 18:19:44 +02:00
Carlos Garnacho
7991032aeb gdk/x11: Avoid gdk_device_get_associated_device()
Query the seat for that.
2020-07-30 18:19:44 +02:00
Carlos Garnacho
0cbc857ea4 gdk/win32: Avoid gdk_device_get_associated_device()
Query the seat for that.
2020-07-30 18:17:42 +02:00
Carlos Garnacho
398c1d1ad7 gdk/macos: Avoid gdk_device_get_associated_device()
Query the seat for that.
2020-07-30 18:17:42 +02:00
Carlos Garnacho
94982dbab7 gdk: Avoid gdk_device_get_associated_device()
Query the seat for that.
2020-07-30 18:17:42 +02:00
Benjamin Otte
4dc2ab61c9 Merge branch 'wip/otte/geometry' into 'master'
Some GdkGeometry cleanups

See merge request GNOME/gtk!2322
2020-07-30 15:31:27 +00:00
Benjamin Otte
13d3afa56e Remove unused GDK_HINT_POS 2020-07-30 17:06:15 +02:00
Benjamin Otte
3dd0e6d0b1 Remove gravity from GdkGeometry
It's always northwest
2020-07-30 17:06:15 +02:00
Benjamin Otte
11db6ad574 Remove aspect ratio from GdkGeometry
It's unused.
2020-07-30 17:06:15 +02:00
Benjamin Otte
ebcef256ab gdk: Remove unused flags 2020-07-30 17:06:15 +02:00
Benjamin Otte
b12b06e917 gdk: Remove base_size and increment from GdkGeometry
It's unused.
2020-07-30 16:55:45 +02:00
Matthias Clasen
0ee3370afc Merge branch 'wip/master.win.egl' into 'master'
Add an EGL (OpenGL/ES 3) renderer for GTK+-4.x (using Google's ANGLE project) for Windows

Closes #105

See merge request GNOME/gtk!215
2020-07-30 12:18:02 +00:00
Rico Tzschichholz
c2b5997437 Merge branch 'ricotz/for-master' into 'master'
a11y: Fix typo in GtkATContext::state-changed docs

See merge request GNOME/gtk!2320
2020-07-30 07:35:48 +00:00
Rico Tzschichholz
f02a17805e a11y: Fix typo in GtkATContext::state-changed docs 2020-07-30 09:06:49 +02:00
Chun-wei Fan
a481733b40 GDK/Win32: Force GLES if running on ARM64
If GLES support is enabled on Windows, force GLES mode if we are running
on a ARM64 version of Windows (i.e. Windows 10 for ARM).

This is required as ARM64 versions of Windows only provide a software
implementation of OpenGL 1.1/1.2, which is not enough for our purposes.
Thus, we could make instead use the GLES support provided via Google's
libANGLE (which emulates OpenGL/ES 3 with Direct3D 9/11), so that we
can run GtkGLArea programs under OpenGL/ES in ARM64 versions of Windows.

Note that eventually we could update the libepoxy build files for Windows
to not check nor enable WGL when building for ARM64 Windows, as the WGL
items do not work, although they do build.
2020-07-30 14:30:13 +08:00
Chun-wei Fan
cf0175ffce OpenGL/ES: Fix 'R' and 'B' bits inverted on Windows
We need to use GL_BGRA instead of GL_RGBA when doing glReadPixels() on
EGL on Windows (ANGLE) so that the red and blue bits won't be displayed
inverted.

Also fix the logic where we determine whether to bit blit or redraw
everything.
2020-07-30 14:30:13 +08:00
Chun-wei Fan
e5600ab99b demos: Fix glarea demo on OpenGL/ES
Some implementations of the ES 1.00 shader (such as Google's ANGLE) do
not like the 'f' suffix for floats, so just drop it, as it should be
harmless to drop.
2020-07-30 14:26:33 +08:00
Chun-wei Fan
257fd990d1 Add a EGL renderer (via ANGLE) for Windows
This is for adding a EGL-based renderer which is done via the ANGLE
project, which translate EGL calls to Direct3D 9/11.  This is done as a
possible solution to issue #105, especially for cases where the needed
full GL extensions to map OpenGL to Direct3D is unavailable or
unreliable, or when the OpenGL implementation from the graphics drivers
are problematic.

To enable this, do the following:
-Build ANGLE and ensure the ANGLE libEGL.dll and libGLESv2.dll are
 available.  A sufficiently-recent ANGLE is needed for things to
 work correctly--note that the copy of ANGLE that is included in
 qtbase-5.10.1 is sufficient.  ANGLE is licensed under a BSD 3-clause
 license.
-Build libepoxy on Windows with EGL support enabled.
-Currently, prior to running GTK+ programs, the GDK_DEBUG envvar needs
 to be set with gl-gles as at least one of the flags.

Known issues:
-Only OpenGL ES 3 is supported, ANGLE's ES 2 does not support the needed
 extensions, notably GL_OES_vertex_array_object, but its ES 3 support is
 sufficient.
-There is no autodetection or fallback mechanism to enable using
 EGL/Angle automatically yet.  There are no plans to do this in this
 commit.
2020-07-30 14:26:33 +08:00
Chun-wei Fan
12a23162b3 build: Check for EGL support in libepoxy on Windows
...EGL support needs to be explicitly enabled during the build of
libepoxy on Windows as it is not enabled by default on Windows.

With this, we can add an EGL renderer for Windows that make use of
Google's libANGLE, which is a library that translates OpenGL/ES calls
to Direct3D 9/11, which will provide better hardware compatibility
on Windows and would act as one of the foundations to resolve issue #105.
2020-07-30 14:26:33 +08:00
Matthias Clasen
0b11e78064 Merge branch 'display-cleanup' into 'master'
Display cleanup

See merge request GNOME/gtk!2319
2020-07-30 03:55:23 +00:00
Matthias Clasen
e8026e29b6 Merge branch 'surface-cleanup' into 'master'
Surface cleanup

See merge request GNOME/gtk!2317
2020-07-30 03:43:30 +00:00
Matthias Clasen
ee1a868913 Merge branch 'a11y-work' into 'master'
A11y work

See merge request GNOME/gtk!2318
2020-07-30 03:28:02 +00:00
Matthias Clasen
488722e7c4 docs: Don't refer to nonexisting functions
gdk_surface_input_shape_combine_mask() no longer
exists.
2020-07-29 23:00:57 -04:00
Matthias Clasen
7df070d681 gdk: Move default group api to the X11 backend
This is the only place where it is implemented.
2020-07-29 22:58:37 -04:00
Matthias Clasen
abf8cbeaea a11y: Set an accessible role for GtkLevelBar
Use the 'meter' role for GtkLevelBar, and set the
appropriate properties.

Update the docs and add a test.
2020-07-29 22:46:00 -04:00
Matthias Clasen
c0de580d46 a11y: Set an accessible role for GtkExpander
Use the button accessible role for GtkExpander
and set attributes as appropriate.

Update the documentation and add a test.
2020-07-29 22:46:00 -04:00
Matthias Clasen
144114bf40 a11y: Set accessible role for GtkLinkButton
Set the accessible role for GtkLinkButton to button.
We don't use the 'link' role since ARIA says "if it
behaves like a button, use 'button'".

Update docs and add a test.

This changes should not be neccessary, since
GtkLinkButton derives from GtkButton, see #2965.
2020-07-29 22:46:00 -04:00
Matthias Clasen
c68fe1053a a11y: Set an accessible role for GtkTextView
Use the text-box accessible role for GtkTextView
and set properties as appropriate.

Update the documentation and add a test.
2020-07-29 22:46:00 -04:00
Matthias Clasen
4d012a6d95 Rename gdk_surface_queue_expose
We don't have expose events anymore; instead, there
is a ::render signal. So rename queue_expose to
queue_render to match.

Update all callers.
2020-07-29 22:40:01 -04:00
Matthias Clasen
c1eedf6845 gdk: Stop exporting gdk_surface_freeze_updates
The only legitimate use for freezing the frame clock
is in GDK backends. Exporting this function for
applications makes no sense.
2020-07-29 22:30:44 -04:00
Matthias Clasen
9722bb4d9e iconbrowser: Add screenshots to appdata
appstream validation is picky and insists we have
at least on screenshot.
2020-07-29 20:23:46 -04:00