continue layer slider labels - CURA-4412

This commit is contained in:
ChrisTerBeke 2017-10-09 14:19:21 +02:00
parent ee0dabd837
commit 5740af04bb
2 changed files with 77 additions and 86 deletions

View file

@ -186,8 +186,8 @@ Item {
height: sliderRoot.handleSize + UM.Theme.getSize("default_margin").height
// width is calculated automatically from the input field width
x: (sliderRoot.width / 2 - (parent.width / 2)) - width
y: Math.floor(parent.y + parent.height / 2 - height / 2)
x: parent.x - width // align with slider handle
y: parent.anchors.top - height // align with slider? handle
target: Qt.point(sliderRoot.width, parent.y + parent.height / 2)
visible: sliderRoot.layersVisible

View file

@ -9,7 +9,7 @@ import QtQuick.Controls.Styles 1.1
import UM 1.0 as UM
import Cura 1.0 as Cura
Item {
UM.PointingRectangle {
id: sliderLabelRoot
// custom properties
@ -19,24 +19,16 @@ Item {
property var setValue // Function
property bool busy: false
x: parent.x
y: parent.y
height: parent.height
visible: true
UM.PointingRectangle {
x: sliderLabelRoot.x
y: sliderLabelRoot.y
target: sliderLabelRoot.target
arrowSize: UM.Theme.getSize("default_arrow").width
height: sliderLabelRoot.height
height: parent.height
width: valueLabel.width + UM.Theme.getSize("default_margin").width
color: UM.Theme.getColor("tool_panel_background")
borderColor: UM.Theme.getColor("lining")
borderWidth: UM.Theme.getSize("default_lining").width
visible: sliderLabelRoot.visible
visible: true
Behavior on height {
NumberAnimation {
@ -107,4 +99,3 @@ Item {
running: sliderLabelRoot.busy
}
}
}