このページでは

QtShell QML Type

Qt Wayland Compositor 上で動作するQtアプリケーション向けのシェル拡張機能を提供します。詳細...

Import Statement: import QtWayland.Compositor.QtShell
Since: Qt 6.3

シグナル

詳細な説明

QtShell拡張機能は、QtShellSurface を通常のWaylandサーフェスに関連付ける手段を提供します。 QtShell拡張機能は、Qtがサポートするウィンドウ管理機能をサポートするために作成されています。これは、コンポジターとクライアントアプリケーションの両方がQtで記述されており、手動でのウィンドウ配置や「最前面表示」などの機能が不正に使用されないことが保証されているプラットフォームに適している可能性があります。

その他のユースケースについては、代わりにIviApplication またはXdgShell の使用を検討してください。

import QtWayland.Compositor.QtShell

WaylandCompositor {
    property ListModel shellSurfaces: ListModel {}
    QtShell {
        onQtShellSurfaceCreated: {
             shellSurfaces.append({shellSurface: qtShellSurface})
        }
    }
}

シグナルに関するドキュメント

void qtShellSurfaceCreated(QtShellSurface *qtShellSurface)

このシグナルは、QtShellSurface が作成されたときに発火します。引数として渡されるqtShellSurface は、ShellSurfaceItem のインスタンス化に最もよく使用されます。

注: 対応するハンドラは onQtShellSurfaceCreated です。

void qtShellSurfaceRequested(WaylandSurface surface, WaylandResource resource)

このシグナルは、クライアントが `QtShellSurface ` を `surface` に関連付けるよう要求した際に発火します。このシグナルのハンドラは、シグナル発火の範囲内で、`resource ` 用の `QtShellSurface ` を作成し、初期化することが期待されます。もし `QtShellSurface ` が作成されない場合、代わりにデフォルトのものが作成されます。

注: 対応するハンドラは onQtShellSurfaceRequested です。

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