QT_HARMONYOS_能力・志向

HarmonyOSアビリティの画面向きに関するポリシー。

このプロパティは Qt 6.12 で導入されました。

注:この プロパティはテクノロジープレビュー段階にあり、将来のリリースで変更される可能性があります。

注:この プロパティは、HarmonyOSプラットフォームを対象とする場合にのみ使用されます。

アプリケーションの機能における画面の向きに関するポリシーを指定します。この値は、HAPパッケージのビルド時にentry/src/main/module.json5 に書き込まれます。有効な値は、HarmonyOSのmodule.json5 スキーマで定義されている向きを表す文字列であり、auto_rotation 、auto_rotation_restricted 、landscape 、portrait 、auto_rotation_landscape 、auto_rotation_portrait 、およびlocked が含まれます。認識されない値は、HAPのビルド時に警告が表示され、無視されます。

このプロパティが設定されていない場合、そのフィールドはマニフェストから省略され、システムのデフォルト値が適用されます。

set_target_properties(myapp PROPERTIES
    QT_HARMONYOS_ABILITY_ORIENTATION "landscape"
)

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