Rearrange Toolbar

Reposition MessageStack
This commit is contained in:
fieldOfView 2015-11-25 13:08:29 +01:00
parent 9c7ee751d5
commit ab02aef6cd
2 changed files with 10 additions and 7 deletions

View file

@ -326,9 +326,8 @@ UM.MainWindow
anchors
{
horizontalCenter: parent.horizontalCenter
horizontalCenterOffset: -(UM.Theme.sizes.logo.width/ 2)
top: parent.verticalCenter;
bottom: parent.bottom;
horizontalCenterOffset: -(UM.Theme.sizes.sidebar.width/ 2)
verticalCenter: parent.verticalCenter;
}
}
@ -432,9 +431,9 @@ UM.MainWindow
id: toolbar;
anchors {
left: parent.left
left: openFileButton.right
leftMargin: UM.Theme.sizes.window_margin.width
top: parent.top
topMargin: UM.Theme.sizes.window_margin.height + UM.Theme.sizes.button.height
//horizontalCenter: parent.horizontalCenter
//horizontalCenterOffset: -(UM.Theme.sizes.sidebar.width / 2)
//top: parent.top;

View file

@ -15,7 +15,7 @@ Item {
height: buttons.height
property int activeY
ColumnLayout {
RowLayout {
id: buttons;
anchors.bottom: parent.bottom;
@ -35,12 +35,14 @@ Item {
checked: model.active;
enabled: UM.Selection.hasSelection;
property bool verticalTooltip: true;
style: UM.Theme.styles.tool_button;
//Workaround since using ToolButton"s onClicked would break the binding of the checked property, instead
//just catch the click so we do not trigger that behaviour.
MouseArea {
anchors.fill: parent;
cursorShape: Qt.PointingHandCursor
onClicked: {
parent.checked ? UM.Controller.setActiveTool(null) : UM.Controller.setActiveTool(model.id);
base.activeY = parent.y
@ -62,7 +64,9 @@ Item {
Rectangle {
id: panelBackground;
anchors.left: parent.right;
anchors.left: parent.left;
anchors.top: parent.bottom;
anchors.topMargin: UM.Theme.sizes.default_margin.width;
y: base.activeY
width: {