Update Printer application to the new style GUI

This commit is contained in:
Arjen Hiemstra 2015-02-06 18:00:52 +01:00
parent 8e1e37e2eb
commit 1c1371489b
5 changed files with 571 additions and 13 deletions

45
OutputGCodeButton.qml Normal file
View file

@ -0,0 +1,45 @@
import QtQuick 2.2
import QtQuick.Controls 1.1
import QtQuick.Controls.Styles 1.1
import QtQuick.Layouts 1.1
import UM 1.0 as UM
Button {
id: saveButton;
text: "Save";
iconSource: UM.Resources.getIcon('save.png');
onClicked: saveDialog.open();
style: ButtonStyle {
background: Rectangle {
color: UM.Theme.primaryColor;
border.width: 1;
border.color: UM.Theme.borderColor;
}
label: Item {
Label {
anchors.verticalCenter: parent.verticalCenter;
anchors.left: parent.left;
anchors.right: icon.left;
text: control.text;
horizontalAlignment: Text.AlignHCenter;
font.pointSize: UM.Theme.largeTextSize;
}
Rectangle {
id: icon;
anchors.right: parent.right;
anchors.verticalCenter: parent.verticalCenter;
width: control.height;
height: control.height;
UM.RecolorImage { anchors.centerIn: parent; source: control.iconSource; color: "#f00"; }
}
}
}
}