summaryrefslogtreecommitdiff
path: root/src/controls/GroupBox.qml
diff options
context:
space:
mode:
authorVenu <venugopal.shivashankar@digia.com>2014-03-06 16:53:40 +0100
committerVenugopal Shivashankar <venugopal.shivashankar@digia.com>2014-06-27 12:30:40 +0200
commit58c5f54f0b772a424c60a8e5184eaf698e744c9a (patch)
tree78dd541ef330ca522b34684f8530037f68a71bea /src/controls/GroupBox.qml
parentc76b9478be9c6aab13bcd8e237db12dec080841e (diff)
downloadqtquickcontrols-58c5f54f0b772a424c60a8e5184eaf698e744c9a.tar.gz
Doc: Added images and missing snippets
Task-number: QTBUG-33799 Change-Id: I582518a73276d47cf63cf31411b5176a90acab6f Reviewed-by: J-P Nurmi <jpnurmi@digia.com>
Diffstat (limited to 'src/controls/GroupBox.qml')
-rw-r--r--src/controls/GroupBox.qml35
1 files changed, 21 insertions, 14 deletions
diff --git a/src/controls/GroupBox.qml b/src/controls/GroupBox.qml
index 9ed90fa5..d17d8cb8 100644
--- a/src/controls/GroupBox.qml
+++ b/src/controls/GroupBox.qml
@@ -51,6 +51,8 @@ import QtQuick.Layouts 1.0
\ingroup controls
\brief GroupBox provides a group box frame with a title.
+ \image groupbox.png
+
A group box provides a frame, a title on top and displays various other controls inside itself. Group boxes can also be checkable.
Child controls in checkable group boxes are enabled or disabled depending on whether or not the group box is checked.
@@ -63,24 +65,29 @@ import QtQuick.Layouts 1.0
The implicit size of the GroupBox is calculated based on the size of its content. If you want to anchor
items inside the group box, you must specify an explicit width and height on the GroupBox itself.
- The following example shows how we use a GroupBox with a column:
+ The following example shows how we use a GroupBox:
\qml
- GroupBox {
- title: qsTr("Package selection")
- Column {
- spacing: 2
- CheckBox {
- text: qsTr("Update system")
- }
- CheckBox {
- text: qsTr("Update applications")
- }
- CheckBox {
- text: qsTr("Update documentation")
- }
+ GroupBox {
+ title: "Joining for?"
+
+ Column {
+ spacing: 10
+
+ CheckBox {
+ text: "Breakfast"
+ checked: true
+ }
+ CheckBox {
+ text: "Lunch"
+ checked: false
+ }
+ CheckBox {
+ text: "Dinner"
+ checked: true
}
}
+ }
\endqml
\sa CheckBox, RadioButton, Layout