diff --git a/examples/basiclayouts/main.qml b/examples/basiclayouts/main.qml index 2e338a81b5ac16d5dd8c3c0b040c344235e1ed42..a5ef9416ef4220d312918a91508f4682398fa325 100644 --- a/examples/basiclayouts/main.qml +++ b/examples/basiclayouts/main.qml @@ -62,11 +62,14 @@ ApplicationWindow { GroupBox { id: rowBox title: "Row layout" - + contentWidth: rowLayout.implicitWidth + contentHeight: rowLayout.implicitHeight Layout.fillWidth: true + RowLayout { id: rowLayout spacing: 6 + anchors.fill: parent Button { text: "Button 1" } @@ -79,17 +82,24 @@ ApplicationWindow { Button { text: "Button 4" } + Item { + Layout.fillWidth: true + } } } GroupBox { id: gridBox title: "Grid layout" + contentWidth: gridLayout.implicitWidth + contentHeight: gridLayout.implicitHeight Layout.fillWidth: true + GridLayout { id: gridLayout rowSpacing: 6 columnSpacing: 6 + anchors.fill: parent Label { text: "Line 1" Layout.row: 0