The QWaylandWlShellSurface class provides desktop-style compositor-specific features to a surface. 更多...
| 头: | #include <QWaylandWlShellSurface> |
| CMake: |
find_package(Qt6 COMPONENTS Waylandcompositor REQUIRED)
target_link_libraries(mytarget PRIVATE Qt6::Waylandcompositor) |
| qmake: | QT += waylandcompositor |
| Since: | Qt 5.8 |
| 实例化: | WlShellSurface |
| 继承: | QWaylandShellSurfaceTemplate |
| enum | ResizeEdge { NoneEdge, TopEdge, BottomEdge, LeftEdge, TopLeftEdge, …, BottomRightEdge } |
| QWaylandWlShellSurface (QWaylandWlShell * shell , QWaylandSurface * surface , const QWaylandResource & res ) | |
| QWaylandWlShellSurface () | |
| QString | className () const |
| void | initialize (QWaylandWlShell * shell , QWaylandSurface * surface , const QWaylandResource & resource ) |
| void | sendConfigure (const QSize & size , QWaylandWlShellSurface::ResizeEdge edges ) |
| void | sendPopupDone () |
| QWaylandWlShell * | shell () const |
| QWaylandSurface * | surface () const |
| QString | title () const |
| void | ping () |
| void | classNameChanged () |
| void | shellChanged () |
| void | surfaceChanged () |
| void | titleChanged () |
| QWaylandWlShellSurface * | fromResource (wl_resource * resource ) |
此类属于 QWaylandWlShell extension and provides a way to extend the functionality of an existing QWaylandSurface with features specific to desktop-style compositors, such as resizing and moving the surface.
It corresponds to the Wayland interface
wl_shell_surface
.
This enum type provides a way to specify an edge or corner of the surface.
| 常量 | 值 | 描述 |
|---|---|---|
QWaylandWlShellSurface::NoneEdge
|
0
|
No edge. |
QWaylandWlShellSurface::TopEdge
|
1
|
The top edge. |
QWaylandWlShellSurface::BottomEdge
|
2
|
The bottom edge. |
QWaylandWlShellSurface::LeftEdge
|
4
|
The left edge. |
QWaylandWlShellSurface::TopLeftEdge
|
5
|
The top left corner. |
QWaylandWlShellSurface::BottomLeftEdge
|
6
|
The bottom left corner. |
QWaylandWlShellSurface::RightEdge
|
8
|
The right edge. |
QWaylandWlShellSurface::TopRightEdge
|
9
|
The top right corner. |
QWaylandWlShellSurface::BottomRightEdge
|
10
|
The bottom right corner. |
[read-only]
className
: const
QString
This property holds the class name of the QWaylandWlShellSurface .
访问函数:
| QString | className () const |
通知程序信号:
| void | classNameChanged () |
[read-only]
shell
:
QWaylandWlShell
* const
This property holds the shell associated with this QWaylandWlShellSurface .
访问函数:
| QWaylandWlShell * | shell () const |
通知程序信号:
| void | shellChanged () |
[read-only]
surface
:
QWaylandSurface
* const
This property holds the surface associated with this QWaylandWlShellSurface .
访问函数:
| QWaylandSurface * | surface () const |
通知程序信号:
| void | surfaceChanged () |
[read-only]
title
: const
QString
This property holds the title of the QWaylandWlShellSurface .
访问函数:
| QString | title () const |
通知程序信号:
| void | titleChanged () |
Constructs a QWaylandWlShellSurface for surface and initializes it with the given shell and resource res .
Constructs a QWaylandWlShellSurface.
[slot]
void
QWaylandWlShellSurface::
ping
()
Sends a ping event to the client. If the client replies to the event the pong signal will be emitted.
[static]
QWaylandWlShellSurface
*QWaylandWlShellSurface::
fromResource
(
wl_resource
*
resource
)
返回 QWaylandWlShellSurface object associated with the given resource , or null if no such object exists.
[invokable]
void
QWaylandWlShellSurface::
initialize
(
QWaylandWlShell
*
shell
,
QWaylandSurface
*
surface
, const
QWaylandResource
&
resource
)
初始化 QWaylandWlShellSurface and associates it with the given shell , surface ,和 resource .
注意: 此函数可以被援引,通过元对象系统和从 QML。见 Q_INVOKABLE .
[invokable]
void
QWaylandWlShellSurface::
sendConfigure
(const
QSize
&
size
,
QWaylandWlShellSurface::ResizeEdge
edges
)
Sends a configure event to the client, suggesting that it resize its surface to the provided size 。 edges provide a hint about how the surface was resized.
注意: 此函数可以被援引,通过元对象系统和从 QML。见 Q_INVOKABLE .
[invokable]
void
QWaylandWlShellSurface::
sendPopupDone
()
Sends a popup_done event to the client to indicate that the user has clicked somewhere outside the client's surfaces.
注意: 此函数可以被援引,通过元对象系统和从 QML。见 Q_INVOKABLE .