WIP: Cleanup and unify MachineAction styles

This commit is contained in:
Lipu Fei 2019-03-19 14:47:21 +01:00
parent 8d68db9ff0
commit 3911c3d73d
16 changed files with 82 additions and 93 deletions

View file

@ -1,32 +1,24 @@
// Copyright (c) 2016 Ultimaker B.V.
// Copyright (c) 2019 Ultimaker B.V.
// Cura is released under the terms of the LGPLv3 or higher.
import QtQuick 2.2
import QtQuick.Controls 1.1
import QtQuick.Layouts 1.1
import QtQuick.Window 2.1
import QtQuick 2.10
import QtQuick.Controls 2.3
import UM 1.2 as UM
import Cura 1.0 as Cura
import UM 1.3 as UM
import Cura 1.1 as Cura
Cura.MachineAction
{
anchors.fill: parent;
UM.I18nCatalog { id: catalog; name: "cura"; }
anchors.fill: parent
Item
{
id: upgradeSelectionMachineAction
anchors.fill: parent
Label
{
id: pageTitle
width: parent.width
text: catalog.i18nc("@title", "Select Printer Upgrades")
wrapMode: Text.WordWrap
font.pointSize: 18;
}
anchors.topMargin: UM.Theme.getSize("default_margin").width * 5
anchors.leftMargin: UM.Theme.getSize("default_margin").width * 4
Label
{
@ -35,15 +27,19 @@ Cura.MachineAction
anchors.topMargin: UM.Theme.getSize("default_margin").height
width: parent.width
wrapMode: Text.WordWrap
text: catalog.i18nc("@label","Please select any upgrades made to this Ultimaker 2.");
text: catalog.i18nc("@label","Please select any upgrades made to this Ultimaker 2.")
font: UM.Theme.getFont("medium")
renderType: Text.NativeRendering
}
CheckBox
Cura.CheckBox
{
id: olssonBlockCheckBox
anchors.top: pageDescription.bottom
anchors.topMargin: UM.Theme.getSize("default_margin").height
height: UM.Theme.getSize("setting_control").height
text: catalog.i18nc("@label", "Olsson Block")
checked: manager.hasVariants
onClicked: manager.hasVariants = checked
@ -54,7 +50,5 @@ Cura.MachineAction
onHasVariantsChanged: olssonBlockCheckBox.checked = manager.hasVariants
}
}
UM.I18nCatalog { id: catalog; name: "cura"; }
}
}
}