aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMitch Curtis <mitch.curtis@qt.io>2019-04-08 14:18:28 +0200
committerMitch Curtis <mitch.curtis@qt.io>2019-04-08 13:53:42 +0000
commitf5f36b0db64e77822ef3053245c993ed14949192 (patch)
tree3f1f31efc0175a00597677373fe2f1fe25100bed
parent8349cf8335ca16c7ecc85e877d9f4ec24bad49cd (diff)
Doc: expand upon Pane's Content Sizing section
Mention what happens if its contentItem has no implicit size and only one child item. Change-Id: I646ca2baad89ac195836268b14108b43beaec2bf Fixes: QTBUG-69096 Reviewed-by: Paul Wicking <paul.wicking@qt.io>
-rw-r--r--src/quicktemplates2/qquickpane.cpp16
1 files changed, 16 insertions, 0 deletions
diff --git a/src/quicktemplates2/qquickpane.cpp b/src/quicktemplates2/qquickpane.cpp
index 3edbce9d..fd9d2cf0 100644
--- a/src/quicktemplates2/qquickpane.cpp
+++ b/src/quicktemplates2/qquickpane.cpp
@@ -103,6 +103,22 @@ QT_BEGIN_NAMESPACE
}
\endcode
+ If the \l contentItem has no implicit size and only one child, Pane will
+ use the implicit size of that child. For example, in the following code,
+ the Pane will assume the size of the Rectangle:
+
+ \code
+ Pane {
+ Item {
+ Rectangle {
+ implicitWidth: 200
+ implicitHeight: 200
+ color: "salmon"
+ }
+ }
+ }
+ \endcode
+
\sa {Customizing Pane}, {Container Controls},
{Focus Management in Qt Quick Controls 2}, {Event Handling}
*/