From: Kevin Krammer Date: Wed, 17 Oct 2012 17:29:38 +0000 (+0200) Subject: Move test widget into a tab widget X-Git-Url: http://git.silmor.de/gitweb/?a=commitdiff_plain;h=fd5845f50ebeea342f8db7ca70f267bdfa12bb68;p=konrad%2FDeclarativeWidgets.git Move test widget into a tab widget --- diff --git a/layouts.qml b/layouts.qml index 6fce9c9..9f40194 100644 --- a/layouts.qml +++ b/layouts.qml @@ -1,61 +1,65 @@ import QtGui 1.0 -Widget { - VBoxLayout { - Widget { - HBoxLayout { - PushButton { - HBoxLayout.stretch: 1 - text: "1" - } - PushButton { - HBoxLayout.stretch: 1 - text: "1" - } - PushButton { - HBoxLayout.stretch: 2 - text: "2" +TabWidget { + Widget { + TabWidget.label: "Box Layouts" + + VBoxLayout { + Widget { + HBoxLayout { + PushButton { + HBoxLayout.stretch: 1 + text: "1" + } + PushButton { + HBoxLayout.stretch: 1 + text: "1" + } + PushButton { + HBoxLayout.stretch: 2 + text: "2" + } } } - } - Widget { - HBoxLayout { - Label { - HBoxLayout.alignment: Qt.AlignRight - text: "Top" - } - Label { - HBoxLayout.alignment: Qt.AlignVCenter - text: "VCenter" - } - Label { - HBoxLayout.alignment: Qt.AlignBottom - text: "Bottom" + Widget { + HBoxLayout { + Label { + HBoxLayout.alignment: Qt.AlignRight + text: "Top" + } + Label { + HBoxLayout.alignment: Qt.AlignVCenter + text: "VCenter" + } + Label { + HBoxLayout.alignment: Qt.AlignBottom + text: "Bottom" + } } } - } - HBoxLayout { - VBoxLayout { - Label { - VBoxLayout.alignment: Qt.AlignLeft - text: "Left" - } - Label { - VBoxLayout.alignment: Qt.AlignHCenter - text: "HCenter" - } - Label { - VBoxLayout.alignment: Qt.AlignRight - text: "Right" - } - } - VBoxLayout { - TextEdit { - VBoxLayout.stretch: 1 + HBoxLayout { + VBoxLayout { + Label { + VBoxLayout.alignment: Qt.AlignLeft + text: "Left" + } + Label { + VBoxLayout.alignment: Qt.AlignHCenter + text: "HCenter" + } + Label { + VBoxLayout.alignment: Qt.AlignRight + text: "Right" + } } - TextEdit { - VBoxLayout.stretch: 2 + VBoxLayout { + TextEdit { + VBoxLayout.stretch: 1 + } + TextEdit { + VBoxLayout.stretch: 2 + } } } }