diff options
-rw-r--r-- | src/controls/doc/qtquickcontrols.qdocconf | 2 | ||||
-rw-r--r-- | src/controls/doc/src/qtquickcontrols-index.qdoc | 74 | ||||
-rw-r--r-- | src/controls/doc/src/qtquickcontrols-overview.qdoc | 79 | ||||
-rw-r--r-- | src/controls/qquickstack.cpp | 1 | ||||
-rw-r--r-- | src/layouts/doc/qtquicklayouts.qdocconf | 5 | ||||
-rw-r--r-- | src/layouts/doc/src/qtquicklayouts-index.qdoc | 19 | ||||
-rw-r--r-- | src/layouts/doc/src/qtquicklayouts-overview.qdoc | 7 | ||||
-rw-r--r-- | src/layouts/qquicklinearlayout.cpp | 6 | ||||
-rw-r--r-- | src/styles/Base/TableViewStyle.qml | 2 | ||||
-rw-r--r-- | src/styles/doc/qtquickcontrolsstyles.qdocconf | 2 | ||||
-rw-r--r-- | src/styles/doc/src/qtquickcontrolsstyles-index.qdoc | 3 |
11 files changed, 105 insertions, 95 deletions
diff --git a/src/controls/doc/qtquickcontrols.qdocconf b/src/controls/doc/qtquickcontrols.qdocconf index ab321a74..44fd86ca 100644 --- a/src/controls/doc/qtquickcontrols.qdocconf +++ b/src/controls/doc/qtquickcontrols.qdocconf @@ -14,7 +14,7 @@ qhp.QtQuickControls.indexTitle = Qt Quick Controls qhp.QtQuickControls.indexRoot = #qhp.QtQuickControls.extraFiles = style/qtquickcontrols.css -qhp.QtQuickControls.filterAttributes = qtcontrols $QT_VERSION qtrefdoc +qhp.QtQuickControls.filterAttributes = qtquickcontrols $QT_VERSION qtrefdoc qhp.QtQuickControls.customFilters.Qt.name = QtQuickControls $QT_VERSION qhp.QtQuickControls.customFilters.Qt.filterAttributes = qtquickcontrols $QT_VERSION diff --git a/src/controls/doc/src/qtquickcontrols-index.qdoc b/src/controls/doc/src/qtquickcontrols-index.qdoc index 5c22276e..96f2a670 100644 --- a/src/controls/doc/src/qtquickcontrols-index.qdoc +++ b/src/controls/doc/src/qtquickcontrols-index.qdoc @@ -36,56 +36,7 @@ The module is new in Qt 5.1 and requires \l{Qt Quick} 2.1. - \image qtquickcontrols-example-gallery.png - - \section1 Getting Started - - The QML types can be imported into your application using the following import statement in your \c {.qml} file. - - \code - import QtQuick.Controls 1.0 - \endcode - - A basic example of a QML file that makes use of controls is shown here: - - \code - import QtQuick.Controls 1.0 - - ApplicationWindow { - title: "My Application" - - Button { - text: "Push Me" - anchors.centerIn: parent - } - } - \endcode - - \section2 Setting Up Controls from C++ - - While we traditionally have used a QQuickView window to display QML files - in a C++ application, doing this means you can only set window properties from C++. - - With Qt Quick Controls, declare an ApplicationWindow as the root item of your application and launch it by using the - QQmlApplicationEngine instead. This ensures that you can control top level window properties from QML. - - A basic example of a source file that makes use of controls is shown here: - - \code - #include <QApplication> - #include <QQmlApplicationEngine> - - int main(int argc, char *argv[]) - { - QApplication app(argc, argv); - QQmlApplicationEngine engine("main.qml"); - return app.exec(); - } - \endcode - - \note We are using QApplication and not QGuiApplication in this example. - Though you can use QGuiApplication instead, doing this will eliminate platform-dependent styling. - This is because it is relying on the widget module to provide the native look and feel. + Visit the \l{Qt Quick Controls Overview} page to get started. \section1 Application Window Components used to describe the basic window properties of an application. @@ -105,29 +56,12 @@ \section1 Related information - \section2 Guides \list + \li \l{Qt Quick} \li \l{Qt Quick Controls Overview} - \endlist - - \section2 Reference - \list \li \l{Qt Quick Controls QML Types}{Qt Quick Controls QML Types} - \endlist - - \section2 Examples - \list \li \l{Qt Quick Controls Examples} + \li \l{Qt Quick Controls Styles} + \li \l{Qt Quick Layouts} \endlist - - \section2 Styles - \list - \li \l {Qt Quick Controls Styles} - \endlist - - \section2 Layouts - \list - \li \l {Qt Quick Layouts} - \endlist - */ diff --git a/src/controls/doc/src/qtquickcontrols-overview.qdoc b/src/controls/doc/src/qtquickcontrols-overview.qdoc index 82da0b22..4eb6892f 100644 --- a/src/controls/doc/src/qtquickcontrols-overview.qdoc +++ b/src/controls/doc/src/qtquickcontrols-overview.qdoc @@ -28,5 +28,82 @@ /*! \page qtquickcontrols-overview.html \title Qt Quick Controls Overview - \brief A set of APIs for working with ... + \brief A set of UI controls to create user interfaces in Qt Quick + + The Qt Quick Controls provide a set of UI controls to create user interfaces + in Qt Quick. + + \section1 Getting Started + + The QML types can be imported into your application using the following import statement in your \c {.qml} file. + + \code + import QtQuick.Controls 1.0 + \endcode + + \section1 Creating a basic example + + A basic example of a QML file that makes use of controls is shown here: + + \code + import QtQuick.Controls 1.0 + + ApplicationWindow { + title: "My Application" + + Button { + text: "Push Me" + anchors.centerIn: parent + } + } + \endcode + + For an overview of the controls provided by \l{Qt Quick Controls}, you can look at + the \l{Qt Quick Controls - Gallery}{Gallery} example. + + \image qtquickcontrols-example-gallery.png + + \section1 Setting Up Controls from C++ + + Although we have traditionally used a QQuickView window to display QML files + in a C++ application, doing this means you can only set window properties from C++. + + With Qt Quick Controls, declare an ApplicationWindow as the root item of your application and launch it by using the + QQmlApplicationEngine instead. This ensures that you can control top level window properties from QML. + + A basic example of a source file that makes use of controls is shown here: + + \code + #include <QApplication> + #include <QQmlApplicationEngine> + + int main(int argc, char *argv[]) + { + QApplication app(argc, argv); + QQmlApplicationEngine engine("main.qml"); + return app.exec(); + } + \endcode + + \note We are using QApplication and not QGuiApplication in this example. + Though you can use QGuiApplication instead, doing this will eliminate platform-dependent styling. + This is because it is relying on the widget module to provide the native look and feel. + + \section2 Using C++ Data From QML + + If you need to register a C++ class to use from QML, you can call, for example, + qmlRegisterType() before declaring your QQmlApplicationEngine. You can find the list + of all registering functions \l{QQmlEngine}{here}. + + If you need to expose data to QML components, you need to set them + to the context of the current QML engine. See QQmlContext for more + information. + + \section1 Related information + + \list + \li \l{Qt Quick} + \li \l{Qt Quick Controls} + \li \l{Qt Quick Controls Examples} + \endlist */ diff --git a/src/controls/qquickstack.cpp b/src/controls/qquickstack.cpp index ecf873d7..c949ffeb 100644 --- a/src/controls/qquickstack.cpp +++ b/src/controls/qquickstack.cpp @@ -47,7 +47,6 @@ QT_BEGIN_NAMESPACE \qmltype Stack \instantiates QQuickStack \inqmlmodule QtQuick.Controls 1.0 - \ingroup views \brief Provides attached properties for items pushed onto a StackView. The Stack type provides attached properties for items pushed onto a \l StackView. diff --git a/src/layouts/doc/qtquicklayouts.qdocconf b/src/layouts/doc/qtquicklayouts.qdocconf index a13066b8..85cb0a57 100644 --- a/src/layouts/doc/qtquicklayouts.qdocconf +++ b/src/layouts/doc/qtquicklayouts.qdocconf @@ -19,10 +19,9 @@ qhp.QtQuickLayouts.customFilters.Qt.filterAttributes = qtquicklayouts $QT_VERSIO qhp.QtQuickLayouts.subprojects = qtquicklayoutsqmltypes qhp.QtQuickLayouts.subprojects.qtquicklayoutsqmltypes.title = QML Types -qhp.QtQuickLayouts.subprojects.qtquicklayoutsqmltypes.indexTitle = Qt Quick Layouts -qhp.QtQuickLayouts.subprojects.qtquicklayoutsqmltypes.selectors = class fake:qmlClass +qhp.QtQuickLayouts.subprojects.qtquicklayoutsqmltypes.indexTitle = Qt Quick Layouts QML Types +qhp.QtQuickLayouts.subprojects.qtquicklayoutsqmltypes.selectors = class fake:qmlclass qhp.QtQuickLayouts.subprojects.qtquicklayoutsqmltypes.sortPages = true -qhp.QtQuickLayouts.subprojects.qtquicklayoutsqmltypes.type = manual depends = qtqml qtquick qtwidgets qtdoc qtquickcontrols diff --git a/src/layouts/doc/src/qtquicklayouts-index.qdoc b/src/layouts/doc/src/qtquicklayouts-index.qdoc index fb9c3898..58d7fb8c 100644 --- a/src/layouts/doc/src/qtquicklayouts-index.qdoc +++ b/src/layouts/doc/src/qtquicklayouts-index.qdoc @@ -38,13 +38,7 @@ The module is new in Qt 5.1 and requires \l{Qt Quick} 2.1. - \section1 Getting started - - The QML types can be imported into your application using the following import statement in your \c {.qml} file. - - \code - import QtQuick.Layouts 1.0 - \endcode + Visit the \l{Qt Quick Layouts Overview} page to get started. \section1 Layouts @@ -52,18 +46,11 @@ \section1 Related information - \section2 Guides \list + \li \l{Qt Quick} + \li \l{Qt Quick Controls} \li \l{Qt Quick Layouts Overview} - \endlist - - \section2 Examples - \list \li \l{Qt Quick Controls - Basic Layouts Example} - \endlist - - \section2 Reference - \list \li \l{Qt Quick Layouts QML Types}{Qt Quick Layouts QML Types} \endlist */ diff --git a/src/layouts/doc/src/qtquicklayouts-overview.qdoc b/src/layouts/doc/src/qtquicklayouts-overview.qdoc index b7302dad..3eeb98d2 100644 --- a/src/layouts/doc/src/qtquicklayouts-overview.qdoc +++ b/src/layouts/doc/src/qtquicklayouts-overview.qdoc @@ -33,6 +33,13 @@ Qt Quick Layouts are items that are used to arrange items in a user interface. Since Qt Quick Layouts also resize their items, they are well suited for resizable user interfaces. + \section1 Getting started + + The QML types can be imported into your application using the following import statement in your \c {.qml} file. + + \code + import QtQuick.Layouts 1.0 + \endcode \section1 Key Features diff --git a/src/layouts/qquicklinearlayout.cpp b/src/layouts/qquicklinearlayout.cpp index 7c48248b..931bfed5 100644 --- a/src/layouts/qquicklinearlayout.cpp +++ b/src/layouts/qquicklinearlayout.cpp @@ -67,6 +67,8 @@ \li \l{Layout::fillHeight}{Layout.fillHeight} \li \l{Layout::alignment}{Layout.alignment} \endlist + + Read more about attached properties \l{QML Object Attributes}{here}. \sa ColumnLayout \sa GridLayout \sa Row @@ -95,6 +97,8 @@ \li \l{Layout::alignment}{Layout.alignment} \endlist + Read more about attached properties \l{QML Object Attributes}{here}. + \sa RowLayout \sa GridLayout \sa Column @@ -160,6 +164,8 @@ \li \l{Layout::alignment}{Layout.alignment} \endlist + Read more about attached properties \l{QML Object Attributes}{here}. + \sa RowLayout \sa ColumnLayout \sa Grid diff --git a/src/styles/Base/TableViewStyle.qml b/src/styles/Base/TableViewStyle.qml index 1a0605dc..ff7237b0 100644 --- a/src/styles/Base/TableViewStyle.qml +++ b/src/styles/Base/TableViewStyle.qml @@ -131,7 +131,7 @@ ScrollViewStyle { } } - /*! \qmlproperty Component TableViewStyle::rowDelegate + /*! \qmlproperty Component TableViewStyle::itemDelegate Delegate for item. This delegate is described in \l {TableView::itemDelegate} */ property Component itemDelegate: Item { diff --git a/src/styles/doc/qtquickcontrolsstyles.qdocconf b/src/styles/doc/qtquickcontrolsstyles.qdocconf index e559dcc4..6c1e51b1 100644 --- a/src/styles/doc/qtquickcontrolsstyles.qdocconf +++ b/src/styles/doc/qtquickcontrolsstyles.qdocconf @@ -14,7 +14,7 @@ qhp.QtQuickControlsStyles.indexTitle = Qt Quick Controls Styles qhp.QtQuickControlsStyles.indexRoot = #qhp.QtQuickControlsStyles.extraFiles = style/qtquickcontrolsstyles.css -qhp.QtQuickControlsStyles.filterAttributes = qtcontrolsstyles $QT_VERSION qtrefdoc +qhp.QtQuickControlsStyles.filterAttributes = qtquickcontrolsstyles $QT_VERSION qtrefdoc qhp.QtQuickControlsStyles.customFilters.Qt.name = QtQuickControlsStyles $QT_VERSION qhp.QtQuickControlsStyles.customFilters.Qt.filterAttributes = qtquickcontrolsstyles $QT_VERSION diff --git a/src/styles/doc/src/qtquickcontrolsstyles-index.qdoc b/src/styles/doc/src/qtquickcontrolsstyles-index.qdoc index b2205bfc..ed4a0082 100644 --- a/src/styles/doc/src/qtquickcontrolsstyles-index.qdoc +++ b/src/styles/doc/src/qtquickcontrolsstyles-index.qdoc @@ -75,8 +75,9 @@ \section1 Related information - \section2 QML Types \list + \li \l{Qt Quick} + \li \l{Qt Quick Controls} \li \l{Qt Quick Controls Styles QML Types} \endlist |