From 4a5b2d552d3c47c2130b7f3827ebdbef505fabea Mon Sep 17 00:00:00 2001 From: Samuel Fadel Date: Thu, 24 Sep 2015 16:34:42 -0300 Subject: Improved & changed layout for future changes. --- main_view.qml | 74 ++++++++++++++++++++++++++++++++++------------------------- 1 file changed, 43 insertions(+), 31 deletions(-) diff --git a/main_view.qml b/main_view.qml index c84aa6c..092e952 100644 --- a/main_view.qml +++ b/main_view.qml @@ -1,7 +1,8 @@ -import QtQuick 2.0 +import QtQuick 2.5 import QtQuick.Controls 1.3 import QtQuick.Dialogs 1.2 import QtQuick.Extras 1.4 +import QtQuick.Layouts 1.2 import PM 1.0 ApplicationWindow { @@ -39,41 +40,52 @@ ApplicationWindow { } } - Item { + ColumnLayout { + spacing: 10 anchors.fill: parent + anchors.margins: this.spacing + + RowLayout { + spacing: 10 + Layout.fillWidth: true + Layout.fillHeight: true + + Rectangle { + Layout.fillWidth: true + Layout.fillHeight: true + border.width: 1 + border.color: "#cccccc" + z: 0 + + Scatterplot { + id: subsamplePlot + objectName: "subsamplePlot" + anchors.fill: parent + z: 1 + } + } - Rectangle { - anchors.fill: subsamplePlot - border.width: 1 - border.color: "#cccccc" - z: 0 - } - - Rectangle { - anchors.fill: plot - border.width: 1 - border.color: "#cccccc" - z: 0 + Rectangle { + Layout.fillWidth: true + Layout.fillHeight: true + border.width: 1 + border.color: "#cccccc" + z: 0 + + Scatterplot { + id: plot + objectName: "plot" + anchors.fill: parent + z: 1 + } + } } - Scatterplot { - id: subsamplePlot - objectName: "subsamplePlot" - anchors.top: parent.top - anchors.bottom: parent.bottom - anchors.left: parent.left - width: 0.5 * parent.width - z: 1 - } + ScrollView { + Layout.fillWidth: true + Layout.minimumHeight: 150 - Scatterplot { - id: plot - objectName: "plot" - anchors.top: parent.top - anchors.bottom: parent.bottom - anchors.right: parent.right - width: 0.5 * parent.width - z: 1 + // ... } } -- cgit v1.2.3