本页内容

Qt Wayland Compositor C++ Classes

提供用于编写自定义 Wayland 显示服务器的 C++ 类。更多内容...

类

QWaylandBufferRef

保存对表面缓冲区的引用

QWaylandClient

表示连接到 QWaylandCompositor 的客户端

QWaylandCompositor

管理 Wayland 显示服务器

QWaylandCompositorExtension

合成器扩展的基类

QWaylandCompositorExtensionTemplate

用于继承 QWaylandCompositorExtension 的便利类

QWaylandIdleInhibitManagerV1

提供了一个扩展,用于禁用合成器的空闲行为

QWaylandIviApplication

用于嵌入式风格用户界面的扩展

QWaylandIviSurface

识别和调整画布大小的简便方法

QWaylandKeyboard

表示键盘设备

QWaylandObject

可包含 Wayland 扩展的对象的基类

QWaylandOutput

表示由合成器管理的可视区域

QWaylandOutputMode

保存输出设备的分辨率和刷新率

QWaylandPointer

表示一个指针设备

QWaylandQtTextInputMethodManager

提供对合成器中输入方法的访问

QWaylandQuickItem

Qt Quick 表示 Wayland 客户端表面的项

QWaylandQuickShellIntegration

为 shell 表面与 QtQuick 的集成提供支持

QWaylandQuickShellSurfaceItem

Qt Quick 表示 QWaylandShellSurface 的项

QWaylandResource

wl_resource 的容器

QWaylandSeat

访问键盘、鼠标和触控输入

QWaylandShell

用于实现 Wayland 壳层的抽象类

QWaylandShellSurface

用于 shell 扩展所指定表面角色的通用接口

QWaylandShellSurfaceTemplate

用于创建自定义 shell 表面类的便捷类

QWaylandSurface

表示输出设备上的矩形区域

QWaylandSurfaceGrabber

允许读取 QWaylandSurface 的内容

QWaylandSurfaceRole

表示 wl_surface 上下文中表面所扮演的角色

QWaylandTextInputManager

提供对合成器中输入方法的访问

QWaylandTouch

访问触摸设备

QWaylandView

表示输出设备上表面的一处视图

QWaylandViewporter

提供用于表面调整大小和裁剪的扩展

QWaylandWlShell

用于桌面风格用户界面的扩展

QWaylandWlShellSurface

面向画面的桌面风格合成器特定功能

QWaylandXdgDecorationManagerV1

提供用于协商服务器端和客户端窗口装饰的扩展

QWaylandXdgOutputManagerV1

提供了一种以桌面为导向描述输出的扩展

QWaylandXdgOutputV1

表示合成器中的显示

QWaylandXdgPopup

表示 xdg 表面中与弹出窗口相关的特定部分

QWaylandXdgShell

用于桌面风格用户界面的扩展

QWaylandXdgSurface

面向 XDG 表面的桌面风格合成器特定功能

QWaylandXdgToplevel

表示 xdg 表面的顶级窗口相关部分

详细描述

使用该模块

要使用 Qt 模块的 C++ API,需要将模块库链接到项目中,可以是直接链接,也可以通过其他依赖项间接链接。包括CMake和qmake 在内的多种构建工具都为此提供了专门的支持。

使用 CMake 构建

使用find_package() 命令在Qt6 软件包中定位所需的模块组件:

find_package(Qt6 REQUIRED COMPONENTS WaylandCompositor)
target_link_libraries(mytarget PRIVATE Qt6::WaylandCompositor)

更多详细信息,请参阅《使用 CMake 构建》概述。

使用 qmake 构建

要配置模块以便使用 qmake 进行构建,请在项目的 .pro 文件中将该模块作为QT 变量的值添加:

QT += waylandcompositor

有关在应用程序中使用这些类的更多信息,请参阅 Qt Wayland Compositor 文档。

© 2026 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.