Index: sources/gui/qml/components/RangeSlider.qml =================================================================== diff -u -r9ac163d4aeadc39a1bcd1d8110991f32e37fc806 -raac9d5d70abbd8d75c6e3782722e5daaf7355153 --- sources/gui/qml/components/RangeSlider.qml (.../RangeSlider.qml) (revision 9ac163d4aeadc39a1bcd1d8110991f32e37fc806) +++ sources/gui/qml/components/RangeSlider.qml (.../RangeSlider.qml) (revision aac9d5d70abbd8d75c6e3782722e5daaf7355153) @@ -67,8 +67,10 @@ property bool maxAdjusted : false ///< first time user adjustment happens property bool hasAdjust : false ///< if set to true then component is grayed out until both min and max are adjusted - property bool showTickmarks : true ///< Indicate whether tickMarks should be shown - property bool isTickMarksRound : true ///< Indicate whether the tickmakrs are round + property bool showTickmarks : true ///< Indicate whether tickMarks should be shown + property bool isTickMarksRound : true ///< Indicate whether the tickmarks are round + property bool isTickMarksCentered : false ///< Indicate whether the tickmarks are centered in the slider body + property int tickMarkYDisplacement : (-diameter + Variables.progressbarHandlerBorderWidth*2) ///< The amount of y displacement if the TickMarks are not centered property bool isRoundedEnds : true property bool hasBorder : true @@ -254,11 +256,11 @@ minText { visible: false - anchors.topMargin: -40 + anchors.topMargin: -60 } maxText { visible: false - anchors.topMargin: -40 + anchors.topMargin: -60 } // propagation is not working on drag ! @@ -297,8 +299,14 @@ textColor : _root.color lineTickMarkHeight: _rangeRect.height isTickMarkRound : _root.isTickMarksRound - yDisplacement : _root.border.width/2 - 1 // had to subtract 1 to center on the _rangeRect - showEndMarks : false + yDisplacement : { + if ( _root.isTickMarksCentered ) { + return (_root.border.width/2 - 1) // had to subtract 1 to center on the _rangeRect + } else { + return _root.tickMarkYDisplacement + } + } + showEndMarks : true color: _root.isActive ? Colors.borderButton : Colors.borderDisableButton } } @@ -336,7 +344,7 @@ /// Left most handler Rectangle { id: _handlerLeft - property real diameter : _root.diameter + property real diameter : _root.diameter anchors.verticalCenter : parent.verticalCenter anchors.horizontalCenter: _rangeRect.left @@ -346,7 +354,7 @@ radius : diameter color : Colors.highlightProgressBar border { - width : 4 + width : Variables.progressbarHandlerBorderWidth color : Colors.textMain } MouseArea { id: _leftHandleMouseArea @@ -376,7 +384,7 @@ radius : diameter color : Colors.highlightProgressBar border { - width : 4 + width : Variables.progressbarHandlerBorderWidth color : Colors.textMain } MouseArea { id: _rightHandlerMouseArea