From fd09a1959b35505b3c4118d14236be2150dff397 Mon Sep 17 00:00:00 2001 From: fieldOfView Date: Sun, 2 Apr 2017 15:54:06 +0200 Subject: [PATCH] Simplify margins and make them DPI aware --- plugins/3MFReader/WorkspaceDialog.qml | 15 ++++----------- resources/qml/WorkspaceSummaryDialog.qml | 11 ++--------- 2 files changed, 6 insertions(+), 20 deletions(-) diff --git a/plugins/3MFReader/WorkspaceDialog.qml b/plugins/3MFReader/WorkspaceDialog.qml index 2cf8f21012..1a8ace464d 100644 --- a/plugins/3MFReader/WorkspaceDialog.qml +++ b/plugins/3MFReader/WorkspaceDialog.qml @@ -19,8 +19,8 @@ UM.Dialog height: 400 * Screen.devicePixelRatio minimumHeight: 400 * Screen.devicePixelRatio maximumHeight: minimumHeight - property int comboboxHeight: 15 - property int spacerHeight: 10 + property int comboboxHeight: 15 * Screen.devicePixelRatio + property int spacerHeight: 10 * Screen.devicePixelRatio onClosing: manager.notifyClosed() onVisibleChanged: { @@ -33,15 +33,8 @@ UM.Dialog } Item { - anchors.top: parent.top - anchors.bottom: parent.bottom - anchors.left: parent.left - anchors.right: parent.right - - anchors.topMargin: 20 - anchors.bottomMargin: 20 - anchors.leftMargin:20 - anchors.rightMargin: 20 + anchors.fille: parent + anchors.margins: 20 * Screen.devicePixelRatio UM.I18nCatalog { diff --git a/resources/qml/WorkspaceSummaryDialog.qml b/resources/qml/WorkspaceSummaryDialog.qml index 964bbf9872..7da8495da0 100644 --- a/resources/qml/WorkspaceSummaryDialog.qml +++ b/resources/qml/WorkspaceSummaryDialog.qml @@ -41,15 +41,8 @@ UM.Dialog Item { - anchors.top: parent.top - anchors.bottom: parent.bottom - anchors.left: parent.left - anchors.right: parent.right - - anchors.topMargin: 20 - anchors.bottomMargin: 20 - anchors.leftMargin:20 - anchors.rightMargin: 20 + anchors.fill: parent + anchors.margins: 20 * Screen.devicePixelRatio UM.SettingDefinitionsModel {