Qt
Internal/Contributor docs for the Qt SDK. <b>Note:</b> These are NOT official API docs; those are found <a href='https://doc.qt.io/'>here</a>.
Loading...
Searching...
No Matches
qtp0004.qdoc
Go to the documentation of this file.
1// Copyright (C) 2024 The Qt Company Ltd.
2// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GFDL-1.3-no-invariants-only
3
4/*!
5\page qt-cmake-policy-qtp0004.html
6\ingroup qt-cmake-policies
7
8\title QTP0004
9\keyword qt_cmake_policy_qtp0004
10
11\summary {Extra directories with QML files in a QML module need extra qmldir files.}
12
13This policy was introduced in Qt 6.8. It causes the build system to generate
14an extra qmldir file for each additional directory that contains QML files in
15a QML module.
16
17Enabling this policy ensures that the implicit import of each of the QML
18components in your module is the same as the module itself. This means that
19all the components can see each other without explicitly importing the module.
20
21The \c OLD behavior of this policy is that a qmldir file is only generated for
22the root directory of a module.
23
24The \c NEW behavior of this policy is that for each directory with QML files in
25a module a separate qmldir file is generated.
26
27Qt 6.8 issues warnings if you do not explicitly set the policy.
28
29\qtpolicydeprecatedbehavior
30
31\sa qt_policy, {qt6_standard_project_setup}{qt_standard_project_setup()},
32 qt_cmake_policies, qt_add_qml_module
33
34*/