diff options
author | Jerome Pasion <jerome.pasion@qt.io> | 2020-11-20 14:30:21 +0100 |
---|---|---|
committer | Jerome Pasion <jerome.pasion@qt.io> | 2020-11-24 22:37:46 +0100 |
commit | 370fe537badd2b98c2da7f8918a15411d5aa67ad (patch) | |
tree | 948eaeffcca6005aebeef0c56251edfed0ffff72 /src | |
parent | 34e089f86cb92a62dd628808511f95c54d84bb6c (diff) |
Doc: Remove version numbers for import statement
-recommend using the import statement without versions for Qt 6.0
-update use of \qml
Task-number: QTBUG-87155
Pick-to: 6.0 6.0.0
Change-Id: I555d582a13006c5abb6dc1e0266d2987ba79c6d8
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
Diffstat (limited to 'src')
-rw-r--r-- | src/imports/folderlistmodel/qquickfolderlistmodel.cpp | 8 | ||||
-rw-r--r-- | src/imports/labsanimation/plugin.cpp | 2 | ||||
-rw-r--r-- | src/imports/labsmodels/plugin.cpp | 2 | ||||
-rw-r--r-- | src/imports/localstorage/qquicklocalstorage.cpp | 6 | ||||
-rw-r--r-- | src/imports/models/plugin.cpp | 4 | ||||
-rw-r--r-- | src/imports/qtqml/plugin.cpp | 2 | ||||
-rw-r--r-- | src/imports/settings/qqmlsettings.cpp | 10 | ||||
-rw-r--r-- | src/imports/sharedimage/plugin.cpp | 2 | ||||
-rw-r--r-- | src/imports/wavefrontmesh/qwavefrontmesh.cpp | 2 | ||||
-rw-r--r-- | src/imports/workerscript/plugin.cpp | 2 | ||||
-rw-r--r-- | src/qml/doc/src/qmltypereference.qdoc | 4 | ||||
-rw-r--r-- | src/qmltest/doc/src/qtquicktest-qmltypes.qdoc | 2 | ||||
-rw-r--r-- | src/quick/doc/src/concepts/effects/particles.qdoc | 2 | ||||
-rw-r--r-- | src/quick/doc/src/concepts/layouts/qtquicklayouts-index.qdoc | 11 | ||||
-rw-r--r-- | src/quick/doc/src/concepts/layouts/qtquicklayouts-overview.qdoc | 6 | ||||
-rw-r--r-- | src/quick/doc/src/concepts/layouts/qtquicklayouts.qdoc | 4 | ||||
-rw-r--r-- | src/quick/doc/src/qmltypereference.qdoc | 2 | ||||
-rw-r--r-- | src/quickshapes/qquickshape.cpp | 2 |
18 files changed, 40 insertions, 33 deletions
diff --git a/src/imports/folderlistmodel/qquickfolderlistmodel.cpp b/src/imports/folderlistmodel/qquickfolderlistmodel.cpp index 44f0a49d76..342fc77aaa 100644 --- a/src/imports/folderlistmodel/qquickfolderlistmodel.cpp +++ b/src/imports/folderlistmodel/qquickfolderlistmodel.cpp @@ -225,7 +225,7 @@ QString QQuickFolderListModelPrivate::resolvePath(const QUrl &path) To use this module, import the module with the following line: \qml \QtMinorVersion - import Qt.labs.folderlistmodel 2.\1 + import Qt.labs.folderlistmodel \endqml */ @@ -245,7 +245,7 @@ QString QQuickFolderListModelPrivate::resolvePath(const QUrl &path) in future versions.} \qml \QtMinorVersion - import Qt.labs.folderlistmodel 2.\1 + import Qt.labs.folderlistmodel \endqml The \l folder property specifies the folder to access. Information about the @@ -292,8 +292,8 @@ QString QQuickFolderListModelPrivate::resolvePath(const QUrl &path) of QML files in a \l ListView: \qml \QtMinorVersion - import QtQuick 2.\1 - import Qt.labs.folderlistmodel 2.\1 + import QtQuick + import Qt.labs.folderlistmodel ListView { width: 200; height: 400 diff --git a/src/imports/labsanimation/plugin.cpp b/src/imports/labsanimation/plugin.cpp index 9c985f0dcf..ea1c03a56f 100644 --- a/src/imports/labsanimation/plugin.cpp +++ b/src/imports/labsanimation/plugin.cpp @@ -58,7 +58,7 @@ QT_BEGIN_NAMESPACE To use the types in this module, import the module with the following line: \code - import Qt.labs.animation 1.0 + import Qt.labs.animation \endcode */ diff --git a/src/imports/labsmodels/plugin.cpp b/src/imports/labsmodels/plugin.cpp index ab5e0023a6..be26e5c8da 100644 --- a/src/imports/labsmodels/plugin.cpp +++ b/src/imports/labsmodels/plugin.cpp @@ -66,7 +66,7 @@ QT_BEGIN_NAMESPACE To use the types in this module, import the module with the following line: \code - import Qt.labs.qmlmodels 1.0 + import Qt.labs.qmlmodels \endcode */ diff --git a/src/imports/localstorage/qquicklocalstorage.cpp b/src/imports/localstorage/qquicklocalstorage.cpp index 62f19eed63..0a66126fa9 100644 --- a/src/imports/localstorage/qquicklocalstorage.cpp +++ b/src/imports/localstorage/qquicklocalstorage.cpp @@ -546,8 +546,8 @@ through the data. relevant functions using the \c LocalStorage type: \qml \QtMinorVersion - import QtQuick 2.\1 - import QtQuick.LocalStorage 2.\1 + import QtQuick + import QtQuick.LocalStorage Item { Component.onCompleted: { @@ -576,7 +576,7 @@ using the Offline Storage API. \section3 Open or Create a Database \qml \QtMinorVersion -import QtQuick.LocalStorage 2.\1 as Sql +import QtQuick.LocalStorage as Sql db = Sql.openDatabaseSync(identifier, version, description, estimated_size, callback(db)) \endqml diff --git a/src/imports/models/plugin.cpp b/src/imports/models/plugin.cpp index c15866cf05..9a25fd3ad1 100644 --- a/src/imports/models/plugin.cpp +++ b/src/imports/models/plugin.cpp @@ -54,7 +54,7 @@ QT_BEGIN_NAMESPACE To use the types in this module, import the module with the following line: \qml \QtMinorVersion - import QtQml.Models 2.\1 + import QtQml.Models \endqml \note QtQml.Models module started at version 2.1 to match the version @@ -64,7 +64,7 @@ QT_BEGIN_NAMESPACE To use these experimental types, import the module with the following line: \qml - import Qt.labs.qmlmodels 1.0 + import Qt.labs.qmlmodels \endqml \section1 QML Types diff --git a/src/imports/qtqml/plugin.cpp b/src/imports/qtqml/plugin.cpp index a32d86eeb1..5b9dcd9ec9 100644 --- a/src/imports/qtqml/plugin.cpp +++ b/src/imports/qtqml/plugin.cpp @@ -54,7 +54,7 @@ QT_BEGIN_NAMESPACE To use the types in this module, import the module with the following line: \qml \QtMinorVersion - import QtQml 2.\1 + import QtQml \endqml */ diff --git a/src/imports/settings/qqmlsettings.cpp b/src/imports/settings/qqmlsettings.cpp index 50308b30a9..ff8ec5e065 100644 --- a/src/imports/settings/qqmlsettings.cpp +++ b/src/imports/settings/qqmlsettings.cpp @@ -59,7 +59,7 @@ QT_BEGIN_NAMESPACE To use this module, import the module with the following line: \code - import Qt.labs.settings 1.0 + import Qt.labs.settings \endcode */ @@ -87,8 +87,8 @@ QT_BEGIN_NAMESPACE how to use Settings to store and restore the geometry of a window. \qml - import QtQuick.Window 2.1 - import Qt.labs.settings 1.0 + import QtQuick.Window + import Qt.labs.settings Window { id: window @@ -119,8 +119,8 @@ QT_BEGIN_NAMESPACE a setting on component destruction. \qml - import QtQuick 2.1 - import Qt.labs.settings 1.0 + import QtQuick + import Qt.labs.settings Item { id: page diff --git a/src/imports/sharedimage/plugin.cpp b/src/imports/sharedimage/plugin.cpp index d7c2ef8d17..3245635b2d 100644 --- a/src/imports/sharedimage/plugin.cpp +++ b/src/imports/sharedimage/plugin.cpp @@ -62,7 +62,7 @@ To use this module, import it like this: \code - import Qt.labs.sharedimage 1.0 + import Qt.labs.sharedimage \endcode The sharing functionality is provided through a QQuickImageProvider. Use diff --git a/src/imports/wavefrontmesh/qwavefrontmesh.cpp b/src/imports/wavefrontmesh/qwavefrontmesh.cpp index 36cc4d4079..4523e30790 100644 --- a/src/imports/wavefrontmesh/qwavefrontmesh.cpp +++ b/src/imports/wavefrontmesh/qwavefrontmesh.cpp @@ -92,7 +92,7 @@ public: To use this module, import the module with the following line: \qml \QtMinorVersion - import Qt.labs.wavefrontmesh 1.\1 + import Qt.labs.wavefrontmesh \endqml */ diff --git a/src/imports/workerscript/plugin.cpp b/src/imports/workerscript/plugin.cpp index 1323b17ef4..28577d9768 100644 --- a/src/imports/workerscript/plugin.cpp +++ b/src/imports/workerscript/plugin.cpp @@ -54,7 +54,7 @@ QT_BEGIN_NAMESPACE To use the types in this module, import the module with the following line: \qml \QtMinorVersion - import QtQml.WorkerScript 2.\1 + import QtQml.WorkerScript \endqml */ diff --git a/src/qml/doc/src/qmltypereference.qdoc b/src/qml/doc/src/qmltypereference.qdoc index ae36ebbcc9..b28d6ac16c 100644 --- a/src/qml/doc/src/qmltypereference.qdoc +++ b/src/qml/doc/src/qmltypereference.qdoc @@ -47,7 +47,7 @@ The current version of the \c QtQml module is version 2.\QtMinorVersion, and thus it may be imported via the following statement: \qml \QtMinorVersion -import QtQml 2.\1 +import QtQml \endqml Most clients will never need to use the \c QtQml import, as all of the types @@ -55,7 +55,7 @@ are also provided by the \c QtQuick namespace which may be imported as follows: \qml \QtMinorVersion -import QtQuick 2.\1 +import QtQuick \endqml See the \l{Qt Quick} module documentation for more information about the \c diff --git a/src/qmltest/doc/src/qtquicktest-qmltypes.qdoc b/src/qmltest/doc/src/qtquicktest-qmltypes.qdoc index 0ed8c6faa0..c41d34a8d3 100644 --- a/src/qmltest/doc/src/qtquicktest-qmltypes.qdoc +++ b/src/qmltest/doc/src/qtquicktest-qmltypes.qdoc @@ -34,7 +34,7 @@ You can import this module using the following statement: \qml \QtMinorVersion - import QtTest 1.\1 + import QtTest \endqml \section1 QML Types diff --git a/src/quick/doc/src/concepts/effects/particles.qdoc b/src/quick/doc/src/concepts/effects/particles.qdoc index 1cee633b75..d0d86e9167 100644 --- a/src/quick/doc/src/concepts/effects/particles.qdoc +++ b/src/quick/doc/src/concepts/effects/particles.qdoc @@ -34,7 +34,7 @@ This QML module contains a particle system for Qt Quick. To use these types, import the module with the following line: \qml \QtMinorVersion - import QtQuick.Particles 2.\1 + import QtQuick.Particles \endqml For a simple overview of how the system can be used, see \l{Using the Qt Quick Particle System}. diff --git a/src/quick/doc/src/concepts/layouts/qtquicklayouts-index.qdoc b/src/quick/doc/src/concepts/layouts/qtquicklayouts-index.qdoc index a45ed4b45c..15b8394ebf 100644 --- a/src/quick/doc/src/concepts/layouts/qtquicklayouts-index.qdoc +++ b/src/quick/doc/src/concepts/layouts/qtquicklayouts-index.qdoc @@ -35,10 +35,17 @@ them well suited for resizable user interfaces. Since layouts are items they can consequently be nested. - The module is new in Qt 5.1 and requires \l{Qt Quick} 2.1. - Visit the \l{Qt Quick Layouts Overview} page to get started. + \section1 Using the Module + + The QML types can be imported into your application by adding the following + import statement in your \c {.qml} file. + + \qml + import QtQuick.Layouts + \endqml + \section1 Licenses Qt Quick Layouts is available under commercial licenses from \l{The Qt Company}. diff --git a/src/quick/doc/src/concepts/layouts/qtquicklayouts-overview.qdoc b/src/quick/doc/src/concepts/layouts/qtquicklayouts-overview.qdoc index a5f93b972a..369c2f4444 100644 --- a/src/quick/doc/src/concepts/layouts/qtquicklayouts-overview.qdoc +++ b/src/quick/doc/src/concepts/layouts/qtquicklayouts-overview.qdoc @@ -37,9 +37,9 @@ The QML types can be imported into your application using the following import statement in your \c {.qml} file. - \code - import QtQuick.Layouts 1.11 - \endcode + \qml + import QtQuick.Layouts + \endqml \section1 Key Features diff --git a/src/quick/doc/src/concepts/layouts/qtquicklayouts.qdoc b/src/quick/doc/src/concepts/layouts/qtquicklayouts.qdoc index c33fc0cfa3..9ea8759318 100644 --- a/src/quick/doc/src/concepts/layouts/qtquicklayouts.qdoc +++ b/src/quick/doc/src/concepts/layouts/qtquicklayouts.qdoc @@ -39,8 +39,8 @@ The QML types can be imported into your application using the following import statement in your .qml file. - \qml \QtMinorVersion - import QtQuick.Layouts 1.\1 + \qml + import QtQuick.Layouts \endqml */ diff --git a/src/quick/doc/src/qmltypereference.qdoc b/src/quick/doc/src/qmltypereference.qdoc index af46c5dcc3..45677ce386 100644 --- a/src/quick/doc/src/qmltypereference.qdoc +++ b/src/quick/doc/src/qmltypereference.qdoc @@ -38,7 +38,7 @@ The current version of the \c QtQuick module is version \QtMinorVersion, and thus it may be imported via the following statement: \qml \QtMinorVersion -import QtQuick 2.\1 +import QtQuick \endqml Visit the \l {Qt Quick} module documentation for more diff --git a/src/quickshapes/qquickshape.cpp b/src/quickshapes/qquickshape.cpp index db51a33a47..e16911de49 100644 --- a/src/quickshapes/qquickshape.cpp +++ b/src/quickshapes/qquickshape.cpp @@ -68,7 +68,7 @@ Q_LOGGING_CATEGORY(QQSHAPE_LOG_TIME_DIRTY_SYNC, "qt.shape.time.sync") To use the types in this module, import the module with the following line: \qml \QtMinorVersion - import QtQuick.Shapes 1.\1 + import QtQuick.Shapes \endqml */ |