aboutsummaryrefslogtreecommitdiffstats
path: root/src/qml/types
diff options
context:
space:
mode:
authorTopi Reinio <topi.reinio@qt.io>2018-11-02 12:35:57 +0100
committerJani Heikkinen <jani.heikkinen@qt.io>2018-11-02 16:43:47 +0000
commitf20839aed0f2e4fe9134a239adda4853d7bd204a (patch)
treec8edd991ac1bc190e767e105176dcbe078054da2 /src/qml/types
parent6746417e719cee389a37513f830d5cff1b4b9c25 (diff)
Doc: Qt QML: Fix documentation warnings
Add \namespace for for namespace QtQml, as it has logging functions that previously saw no generated documentation. Fix \qmltype name of DelegateChooser, as well as a number of related typos and linking problems. Task-number: QTBUG-71502 Change-Id: I5a9c635853ef73c99a1b1f55cd1c0a1a87fdf6ec Reviewed-by: Martin Smith <martin.smith@qt.io>
Diffstat (limited to 'src/qml/types')
-rw-r--r--src/qml/types/qqmldelegatecomponent.cpp22
-rw-r--r--src/qml/types/qqmldelegatemodel.cpp2
-rw-r--r--src/qml/types/qqmlitemselectionmodel.qdoc4
3 files changed, 14 insertions, 14 deletions
diff --git a/src/qml/types/qqmldelegatecomponent.cpp b/src/qml/types/qqmldelegatecomponent.cpp
index 007e8e2ec6..470f6cab6a 100644
--- a/src/qml/types/qqmldelegatecomponent.cpp
+++ b/src/qml/types/qqmldelegatecomponent.cpp
@@ -66,9 +66,9 @@ QVariant QQmlAbstractDelegateComponent::value(QQmlAdaptorModel *adaptorModel, in
To use this module, import the module with the following line:
- \code
+ \qml
import Qt.labs.qmlmodels 1.0
- \endcode
+ \endqml
*/
/*!
@@ -79,6 +79,7 @@ QVariant QQmlAbstractDelegateComponent::value(QQmlAdaptorModel *adaptorModel, in
The DelegateChoice type wraps a delegate and defines the circumstances
in which it should be chosen.
+
DelegateChoices can be nested inside a DelegateChooser.
\sa DelegateChooser
@@ -86,7 +87,7 @@ QVariant QQmlAbstractDelegateComponent::value(QQmlAdaptorModel *adaptorModel, in
/*!
\qmlproperty string QtQml.Models::DelegateChoice::roleValue
- This property holds the value used to match the role data for the role provided by \l DefaultDelegateChooser::role.
+ This property holds the value used to match the role data for the role provided by \l DelegateChooser::role.
*/
QVariant QQmlDelegateChoice::roleValue() const
{
@@ -106,20 +107,20 @@ void QQmlDelegateChoice::setRoleValue(const QVariant &value)
\qmlproperty index QtQml.Models::DelegateChoice::row
This property holds the value used to match the row value of model elements.
With models that have only the index property (and thus only one column), this property
- should be intended as index, and set to the desired index value.
+ should be intended as an index, and set to the desired index value.
\note Setting both row and index has undefined behavior. The two are equivalent and only
one should be used.
- \sa QtQml.Models::DelegateChoice::index
+ \sa index
*/
/*!
\qmlproperty index QtQml.Models::DelegateChoice::index
This property holds the value used to match the index value of model elements.
- This is effectively an alias for \l QtQml.Models::DelegateChoice::row
+ This is effectively an alias for \l row.
- \sa QtQml.Models::DelegateChoice::row
+ \sa row
*/
int QQmlDelegateChoice::row() const
{
@@ -190,14 +191,14 @@ bool QQmlDelegateChoice::match(int row, int column, const QVariant &value) const
}
/*!
- \qmltype QQmlDelegateChooser
+ \qmltype DelegateChooser
\instantiates QQmlDelegateChooser
\inqmlmodule Qt.labs.qmlmodels
\brief Allows a view to use different delegates for different types of items in the model.
The DelegateChooser is a special \l Component type intended for those scenarios where a Component is required
by a view and used as a delegate.
- DelegateChooser encapsulates a set of \l DelegateChoices.
+ DelegateChooser encapsulates a set of \l {DelegateChoice}s.
These choices are used determine the delegate that will be instantiated for each
item in the model.
The selection of the choice is performed based on the value that a model item has for \l role,
@@ -227,13 +228,14 @@ void QQmlDelegateChooser::setRole(const QString &role)
/*!
\qmlproperty list<DelegateChoice> QtQml.Models::DelegateChooser::choices
\default
+
The list of DelegateChoices for the chooser.
The list is treated as an ordered list, where the first DelegateChoice to match
will be used be a view.
It should not generally be necessary to refer to the \c choices property,
- as it is the default property for DefaultDelegateChooser and thus all child items are
+ as it is the default property for DelegateChooser and thus all child items are
automatically assigned to this property.
*/
diff --git a/src/qml/types/qqmldelegatemodel.cpp b/src/qml/types/qqmldelegatemodel.cpp
index 243a7ce749..8a0d60a092 100644
--- a/src/qml/types/qqmldelegatemodel.cpp
+++ b/src/qml/types/qqmldelegatemodel.cpp
@@ -437,8 +437,6 @@ void QQmlDelegateModel::setModel(const QVariant &model)
The delegate provides a template defining each item instantiated by a view.
The index is exposed as an accessible \c index property. Properties of the
model are also available depending upon the type of \l {qml-data-models}{Data Model}.
-
- \sa DelegateComponent
*/
QQmlComponent *QQmlDelegateModel::delegate() const
{
diff --git a/src/qml/types/qqmlitemselectionmodel.qdoc b/src/qml/types/qqmlitemselectionmodel.qdoc
index 7ddfd79217..43da4f7a55 100644
--- a/src/qml/types/qqmlitemselectionmodel.qdoc
+++ b/src/qml/types/qqmlitemselectionmodel.qdoc
@@ -52,7 +52,7 @@
It will trigger property binding updates every time \l selectionChanged()
is emitted, even though its value hasn't changed.
- \sa selection(), selectedIndexes, select(), selectionChanged()
+ \sa selection, selectedIndexes, select(), selectionChanged()
*/
/*!
@@ -235,5 +235,5 @@
Note that this signal will not be emitted when the item model is reset.
- \sa currentIndex(), setCurrentIndex(), selectionChanged()
+ \sa currentIndex, setCurrentIndex(), selectionChanged()
*/