After four months of development, a stable release of the Wayland 1.26 protocol, inter-process communication mechanism, and libraries is presented. The 1.26 branch is backwards compatible at the API and ABI level with the 1.x releases and mainly contains bug fixes and minor protocol updates. The project's developments are licensed under the MIT license. The reference compositor server Weston, which provides code and working examples for using Wayland in desktop environments and embedded solutions, is developed within a separate development cycle.
Key changes in the protocol:
- The wl_pointer.warp event has been added, allowing notifications of a new pointer position to be received without handling the wl_pointer.motion event generated by user activity.
- The wl_fixes.ack_global_remove request has been added, intended to send to the compositing manager confirmation that the client has ceased processing the event to prevent race conditions when removing global events. After receiving confirmation from all clients, the compositing manager can remove the associated event handler on its side.
- The function wl_display_remove_socket_fd() has been added to remove sockets previously added through the wl_display_add_socket_fd() call.
- In debug mode, WAYLAND_DEBUG provides time logging in the format "HH:MM:ss.xxxxxx", simplifying log analysis and comparison.
Protocols added after the previous Wayland release, complementing the basic Wayland protocol and delivered in a separate set of Wayland-Protocols:
- xx-fractional-scale — for scaling the system of logical coordinates, where values are specified as integers, to improve positioning accuracy and increase the resolution of logical coordinates to individual pixels. This capability addresses the issue of limited resolution in the logical coordinate system, which is insufficient for positioning at the level of individual pixels necessary for full implementation of fractional scaling.
- xx-cutouts — for obtaining information about cutouts on the screen (for example, areas under the front camera on a smartphone screen).
- xx-zones — for creating and adding top-level windows into "zones" — environments with their own coordinate space. The protocol allows for logical window arrangement, where each window is positioned relative to another window.
- xx-keyboard-filter — for intercepting client-chosen keyboard events, modifying input events or blocking the transmission of certain events to the Wayland surface that currently has input focus.
- The "staging" category has been updated with the xdg-session-management protocol, which provides features for restoring the state and position of windows in interrupted sessions in environments based on the Wayland protocol, such as after a crash of the compositor. server or applications.
- Support for operation on systems with multiple GPUs has been added to the linux-dmabuf protocol. On such systems, a client can negotiate with the compositors proxy server which GPU should be used.
- The color-management-v1 protocol has been updated to support image metadata in the BT.2100 format for use in composite server specific handlers that correctly display HDR content created for Windows.
The most notable events related to Wayland that have occurred since the last release include:
- Cinnamon has implemented full support for Wayland.
- Support for Wayland has been added to the ANGLE library used in Chrome and Android.
- KDE has implemented session restoration support when using Wayland and has introduced the Wayland protocol xx-fractional-scale-v2 for fractional scaling.
- A port of the X.Org Synaptics driver for Wayland-based environments has been created.
- An evaluation of the readiness of VFX and animation platforms for the replacement of X11 with Wayland has been initiated.
- Testing of the Xfwl4 compositor server from the Xfce project has begun.
- A user shell similar to Unity has been recreated based on Wayfire and Libadwaita.
- Compositor servers and desktop environments have been updated: COSMIC 1.3.0, Weston 16, Phosh 0.56, Nourish 1.0.0, miracle-wm 0.10, KDE Plasma 6.7, labwc 0.20, Sway 1.2, Wayland Maker 0.8, Hyprland 0.55, Niri 26.04, LXQt 2.4.0, Cage 0.3.
Wayland is a protocol for the interaction between the compositor server and the applications working with it. Clients perform rendering of their windows in a separate buffer, passing update information to the compositor. server, which combines the content of each application's buffers to form the final output, accounting for nuances such as window overlaps and transparency. In other words, the compositor does not provide an API for rendering individual elements but operates only with already formed windows, which eliminates double buffering when using high-level libraries like GTK and Qt that handle the layout of window content.
Wayland addresses many security issues with X11 in the X.Org Server, as it isolates input and output for each window, prevents clients from accessing the content of other clients' windows, and does not allow interception of input events related to other windows (in XLibre XServer, there is an X11 extension Xnamespace that provides client isolation through namespace division). Direct support for working with Wayland has been implemented for most commonly used graphical libraries in Linux, including GTK, Qt, SDL, FLTK, wxWidgets, Clutter, and EFL (Enlightenment Foundation Library).
Interaction with hardware in Wayland/Weston, such as performing initialization, switching video modes (drm modesetting), and managing memory (GEM for i915 and TTM for radeon and nouveau) of graphics cards, can be done directly through a module operating at the kernel level, allowing for operation without superuser privileges. To run standard X11 applications in a Wayland-based environment, the DDX component XWayland (Device-Dependent X) is used, which operates similarly to Xwin and Xquartz for Win32 and macOS platforms.
Source: opennet.ru
