QWaylandClient Class
QWaylandClient 类表示连接到QWaylandCompositor的客户端。
头文件: | #include <QWaylandClient> |
CMake: | find_package(Qt6 REQUIRED COMPONENTS WaylandCompositor) target_link_libraries(mytarget PRIVATE Qt6::WaylandCompositor) |
qmake: | QT += waylandcompositor |
在 QML 中: | WaylandClient |
继承: | QObject |
公共类型
flags | TextInputProtocols |
属性
- compositor : QWaylandCompositor* const
- groupId : const qint64
- processId : const qint64
- userId : const qint64
公共功能
virtual | ~QWaylandClient() override |
wl_client * | client() const |
QWaylandCompositor * | compositor() const |
qint64 | groupId() const |
void | kill(int signal = SIGTERM) |
qint64 | processId() const |
qint64 | userId() const |
公共插槽
void | close() |
静态公共成员
QWaylandClient * | fromWlClient(QWaylandCompositor *compositor, wl_client *wlClient) |
属性文档
[read-only]
compositor : QWaylandCompositor* const
此属性保存此QWaylandClient 的合成器。
访问功能:
QWaylandCompositor * | compositor() const |
[read-only]
groupId : const qint64
此属性保存此QWaylandClient 的组 ID。
访问功能:
qint64 | groupId() const |
[read-only]
processId : const qint64
此属性保存此QWaylandClient 的进程 ID。
访问功能:
qint64 | processId() const |
[read-only]
userId : const qint64
此属性保存此QWaylandClient 的用户 ID。
访问函数:
qint64 | userId() const |
成员函数文档
[override virtual noexcept]
QWaylandClient::~QWaylandClient()
wl_client *QWaylandClient::client() const
返回QWaylandClient 的 Wayland 客户端。
[slot]
void QWaylandClient::close()
关闭客户端。
[static]
QWaylandClient *QWaylandClient::fromWlClient(QWaylandCompositor *compositor, wl_client *wlClient)
返回与 Wayland 客户端wlClient 和compositor 对应的QWaylandClient 。如果尚未为客户端创建QWaylandClient ,则会创建并返回。
[invokable]
void QWaylandClient::kill(int signal = SIGTERM)
使用指定的signal 关闭客户端。
注: 可通过元对象系统和 QML 调用该函数。请参阅Q_INVOKABLE 。
© 2025 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.