From 58c5f54f0b772a424c60a8e5184eaf698e744c9a Mon Sep 17 00:00:00 2001 From: Venu Date: Thu, 6 Mar 2014 16:53:40 +0100 Subject: Doc: Added images and missing snippets Task-number: QTBUG-33799 Change-Id: I582518a73276d47cf63cf31411b5176a90acab6f Reviewed-by: J-P Nurmi --- src/controls/SplitView.qml | 55 +++++++++++++++++++++++++++++----------------- 1 file changed, 35 insertions(+), 20 deletions(-) (limited to 'src/controls/SplitView.qml') diff --git a/src/controls/SplitView.qml b/src/controls/SplitView.qml index dadff0494..e9f9dddc7 100644 --- a/src/controls/SplitView.qml +++ b/src/controls/SplitView.qml @@ -51,6 +51,8 @@ import QtQuick.Window 2.1 \ingroup views \brief Lays out items with a draggable splitter between each item. + \image splitview.png + SplitView is a control that lays out items horizontally or vertically with a draggable splitter between each item. @@ -92,26 +94,39 @@ import QtQuick.Window 2.1 could do the following: \qml - SplitView { - anchors.fill: parent - orientation: Qt.Horizontal - - Rectangle { - width: 200 - Layout.maximumWidth: 400 - color: "gray" - } - Rectangle { - id: centerItem - Layout.minimumWidth: 50 - Layout.fillWidth: true - color: "darkgray" - } - Rectangle { - width: 200 - color: "gray" - } - } + SplitView { + anchors.fill: parent + orientation: Qt.Horizontal + + Rectangle { + width: 200 + Layout.maximumWidth: 400 + color: "lightblue" + Text { + text: "View 1" + anchors.centerIn: parent + } + } + Rectangle { + id: centerItem + Layout.minimumWidth: 50 + Layout.fillWidth: true + color: "lightgray" + Text { + text: "View 2" + anchors.centerIn: parent + } + } + Rectangle { + width: 200 + color: "lightgreen" + Text { + text: "View 3" + anchors.centerIn: parent + } + } + } + \endqml */ -- cgit v1.2.3