summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--doc/global/includes/module-use.qdocinc37
1 files changed, 36 insertions, 1 deletions
diff --git a/doc/global/includes/module-use.qdocinc b/doc/global/includes/module-use.qdocinc
index 8f00e1dcaa..12dbffe8bc 100644
--- a/doc/global/includes/module-use.qdocinc
+++ b/doc/global/includes/module-use.qdocinc
@@ -1,6 +1,6 @@
/****************************************************************************
**
-** Copyright (C) 2019 The Qt Company Ltd.
+** Copyright (C) 2022 The Qt Company Ltd.
** Contact: https://www.qt.io/licensing/
**
** This file is part of the documentation of the Qt Toolkit.
@@ -41,6 +41,20 @@
//! [using qt module]
+//! [using the c++ api]
+ Using a Qt module requires linking against the module library, either
+ directly or through other dependencies. Several build tools have dedicated
+ support for this, including \l{CMake Documentation}{CMake} and \l{qmake}.
+//! [using the c++ api]
+
+//! [using the qml api]
+ The QML types of the module are available through the \c \1 import. To use
+ the types, add the following import statement to your .qml file:
+
+ \qml
+ import \1
+ \endqml
+//! [using the qml api]
//! [building with qmake]
@@ -50,3 +64,24 @@
of the \c QT variable in the project's .pro file:
//! [building with qmake]
+
+//! [building_with_qmake]
+ To configure the module for building with qmake, add the module as a value
+ of the \c QT variable in the project's .pro file:
+
+ \code
+ QT += \1
+ \endcode
+//! [building_with_qmake]
+
+//! [building with cmake]
+ Use the \c {find_package()} command to locate the needed module component
+ in the \c {Qt6} package:
+
+ \code
+ find_package(Qt6 REQUIRED COMPONENTS \1)
+ target_link_libraries(mytarget PRIVATE Qt6::\1)
+ \endcode
+
+ For more details, see the \l {Build with CMake} overview.
+//! [building with cmake]