summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSafiyyah Moosa <safiyyah.moosa@qt.io>2023-04-26 14:27:38 +0200
committerSafiyyah Moosa <safiyyah.moosa@qt.io>2023-05-02 19:29:25 +0200
commit961d11e55f3eb1ac2e33eefd80adede01cc62622 (patch)
tree1a291a588d45726a88a6e7aa9d6b20fd8c265646
parentbefaf0cd6964131dba95d248b818207cc8acabed (diff)
downloadqtdeclarative-961d11e55f3eb1ac2e33eefd80adede01cc62622.tar.gz
Docs: Fix "Can't link to" example warnings
Task-number: QTBUG-113160 Pick-to: 6.5 Change-Id: I49de891c36d778df5d2727f2f0703d534421e2d5 Reviewed-by: Topi Reiniƶ <topi.reinio@qt.io>
-rw-r--r--src/qml/doc/src/qmllanguageref/syntax/objectattributes.qdoc20
-rw-r--r--src/quick/doc/src/examples.qdoc1
2 files changed, 16 insertions, 5 deletions
diff --git a/src/qml/doc/src/qmllanguageref/syntax/objectattributes.qdoc b/src/qml/doc/src/qmllanguageref/syntax/objectattributes.qdoc
index d442b4f8de..4d52842e48 100644
--- a/src/qml/doc/src/qmllanguageref/syntax/objectattributes.qdoc
+++ b/src/qml/doc/src/qmllanguageref/syntax/objectattributes.qdoc
@@ -621,10 +621,22 @@ This is because the default property of \l Item is its \c data property, and
any items added to this list for an \l Item are automatically added to its
list of \l {Item::children}{children}.
-Default properties can be useful for reassigning the children of an item. See
-the \l{TabWidget Example}, which uses a default property to
-automatically reassign children of the TabWidget as children of an inner
-ListView. See also \l {Extending QML}.
+Default properties can be useful for reassigning the children of an item.
+For example:
+
+\qml
+Item {
+ default property alias content: inner.children
+
+ Item {
+ id: inner
+ }
+}
+\endqml
+
+By setting the default property \e alias to \c {inner.children}, any object
+assigned as a child of the outer item is automatically reassigned as a child
+of the inner item.
\section3 Required Properties
diff --git a/src/quick/doc/src/examples.qdoc b/src/quick/doc/src/examples.qdoc
index 8fe736da54..01ed822f2c 100644
--- a/src/quick/doc/src/examples.qdoc
+++ b/src/quick/doc/src/examples.qdoc
@@ -102,7 +102,6 @@ Creator.
\li \l{Calendar Example}
\li \l{tableview/gameoflife}{TableView}
\li \l{Qt Quick Examples - Text}{Text and Fonts}
- \li \l{Qt Quick Examples - Toggle Switch}{Custom Toggle Switch}
\endlist
\enddiv
\div {class="doc-column"}