本页内容

XdgSurface QML Type

XdgSurface 为 xdg 表面提供了桌面风格的、针对合成器的特定功能。更多内容...

Import Statement: import QtWayland.Compositor.XdgShell
In C++: QWaylandXdgSurface

属性

方法

  • void initialize(object xdgShell, object surface, object client, int id)

详细说明

该类型是XdgShell 扩展的一部分,提供了一种方法,可通过添加桌面风格合成器特有的功能(例如调整画布大小和移动画布)来扩展现有WaylandSurface 的功能。

它对应于 Wayland 接口xdg_surface 。

属性文档

该属性包含XdgSurface 弹出窗口特有的属性和方法。

另请参阅 toplevel 和XdgShell::popupCreated 。

shell : XdgShell [read-only]

该属性保存了与该XdgSurface 相关的shell。

surface : WaylandSurface [read-only]

该属性保存了与该XdgSurface 关联的表面。

toplevel : XdgToplevel [read-only]

该属性包含顶层XdgSurface 特有的属性与方法。

另请参阅 popup 和XdgShell::toplevelCreated 。

windowGeometry : rect [read-only]

该属性保存了此XdgSurface 的窗口几何信息。窗口几何信息描述了从用户视角看窗口的可见边界。该几何信息包括由客户端绘制的标题栏和边框,但不包括阴影。该属性旨在用于对齐和平铺窗口。

windowType : enum [read-only]

该属性存储XdgSurface 的窗口类型。

方法文档

void initialize(object xdgShell, object surface, object client, int id)

初始化XdgSurface ,并将其与给定的xdgShell 、surface 、client 和id 关联起来。

© 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.