Shell Extensions - Qt Wayland Compositor | Qt Wayland Compositor | Qt 6.11.2

- Qt 6.11
- Qt Wayland Compositor
- Shell Extensions - Qt Wayland Compositor
- Qt Wayland Compositor | Commercial or GPLv3

Upgrading from Qt 5

# Shell Extensions - Qt Wayland Compositor

In Wayland, shells are extensions which provide surface semantics. This means that they provide ways for the server and client to communicate about surfaces. Surfaces, in this context, are often also referred to as "windows", which is typically the representation of the surface in the compositor.

Shell extensions provide tools for the client and server to communicate about certain things:

- They can provide a way for the client to inform the server about the purpose of a surface: Is it a tool-tip, a pop-up menu, or a regular application window, for instance? Based on this, the server can decide on the geometry of the window and how the user can interact with it.
- They can also provide protocols for manipulating the surface, such as resizing, moving, and hiding them.

Like other extensions, support for shells is added to a compositor by instantiating them as direct children of the WaylandCompositor top-level object. The shell extensions supported by Qt are: WlShell, XdgShell and IviApplication.

- XdgShell is an appropriate shell for desktop-style systems, where any number of applications can connect and where windows can be manually resized and repositioned by the user.
- IviApplication is a minimalistic protocol, originally intended for In-vehicle Infotainment systems. It is useful for embedded systems, where a pre-defined set of applications can run, often with pre-assigned screen real estate. For some more details on this protocol, see the IVI Compositor example.
- QtShell is a specialized shell for Qt applications which supports the window management features available in Qt. It may be suitable on a platform where both the compositor and client applications are written with Qt, and where applications are trusted not to abuse features such as manual window positioning and "bring-to-front".
- WlShell is mostly useful for compatibility with third-party applications. This is also a desktop-style shell, but it has been deprecated and replaced by XdgShell.

When designing an embedded system from the bottom up, there are no rules determining which shell extension to use. It will typically be either XdgShell or IviApplication. The decision should be influenced by what features the system will need, and whether there are applications involved which are not written in Qt and which have their own requirements.

A Qt Wayland Compositor can also support multiple shell extensions at once. See the Minimal QML example for an example where all three shell extensions listed above are supported.

Upgrading from Qt 5