Index: denali.pro.user =================================================================== diff -u -race4047d1007962c136fa32d0531102e22073f32 -r9a0581274e4dc51af6d6f3e4dd932581e8dce445 --- denali.pro.user (.../denali.pro.user) (revision ace4047d1007962c136fa32d0531102e22073f32) +++ denali.pro.user (.../denali.pro.user) (revision 9a0581274e4dc51af6d6f3e4dd932581e8dce445) @@ -1,6 +1,6 @@ - + EnvironmentId @@ -1187,7 +1187,7 @@ Qt 5.12.5 (iMX8) Qt 5.12.5 (iMX8) {5d6458ef-f917-4aef-a092-c77bbe106149} - 0 + 1 0 0 Index: denali.qrc =================================================================== diff -u -race4047d1007962c136fa32d0531102e22073f32 -r9a0581274e4dc51af6d6f3e4dd932581e8dce445 --- denali.qrc (.../denali.qrc) (revision ace4047d1007962c136fa32d0531102e22073f32) +++ denali.qrc (.../denali.qrc) (revision 9a0581274e4dc51af6d6f3e4dd932581e8dce445) @@ -106,5 +106,6 @@ sources/gui/qml/pages/treatment/adjustments/TreatmentAdjustmentUltrafiltrationPaused.qml sources/gui/qml/pages/treatment/adjustments/TreatmentAdjustmentUltrafiltrationEdit.qml sources/gui/qml/pages/treatment/adjustments/TreatmentAdjustmentUltrafiltrationConfirm.qml + sources/gui/qml/pages/treatment/adjustments/TreatmentAdjustmentPressures.qml Index: sources/gui/qml/components/RangeBar.qml =================================================================== diff -u -race4047d1007962c136fa32d0531102e22073f32 -r9a0581274e4dc51af6d6f3e4dd932581e8dce445 --- sources/gui/qml/components/RangeBar.qml (.../RangeBar.qml) (revision ace4047d1007962c136fa32d0531102e22073f32) +++ sources/gui/qml/components/RangeBar.qml (.../RangeBar.qml) (revision 9a0581274e4dc51af6d6f3e4dd932581e8dce445) @@ -33,14 +33,16 @@ property alias rangebar : _rangeRect property int markerHeight: Variables.rangeMarkerHeightMidle - property color markerColor : Colors.rangeMarker + property color markerColor : markerOutRangeNotify ? (value > lowerBound && value < upperBound ? Colors.rangeMarker : Colors.red) : Colors.rangeMarker + property bool markerOutRangeNotify: false property bool markerVisible : true property int markerBoundHeight : Variables.rangeMarkerHeightShort property color markerBoundColor : Colors.rangeMarkerShort + property int markerFontSize : Fonts.fontPixelRangeMarker - property bool minTextHorizontalCenter: true - property bool maxTextHorizontalCenter: true + property bool lowerTextHorizontalCenter: true + property bool upperTextHorizontalCenter: true RangeRect { id: _rangeRect color: "red" @@ -55,9 +57,10 @@ minText.visible: true maxText.visible: true - minText.anchors.leftMargin : minTextHorizontalCenter ? -minText.width / 2 : 0 - maxText.anchors.rightMargin : maxTextHorizontalCenter ? -maxText.width / 2 : 0 + minText.anchors.leftMargin : lowerTextHorizontalCenter ? -minText.width / 2 : 0 + maxText.anchors.rightMargin : upperTextHorizontalCenter ? -maxText.width / 2 : 0 + RangeMarker { id: _rangeMarkerLowerBound decimal : _root.decimal text.visible: false @@ -73,6 +76,7 @@ color : markerBoundColor anchors.left: parent.right } + onClicked: _root.clicked(vMouseEvent) } RangeMarker { id: _rangeMarkerValue @@ -81,6 +85,7 @@ value : parent.value x : ((parent.width * (parent.value - minimum)) / (maximum - minimum)) text.visible: true + text.font.pixelSize: _root.markerFontSize hasHandle : true height : markerHeight color : markerColor Index: sources/gui/qml/components/RangeRect.qml =================================================================== diff -u -r605815f54dfac948ada786080f55d1b6e7a0d47b -r9a0581274e4dc51af6d6f3e4dd932581e8dce445 --- sources/gui/qml/components/RangeRect.qml (.../RangeRect.qml) (revision 605815f54dfac948ada786080f55d1b6e7a0d47b) +++ sources/gui/qml/components/RangeRect.qml (.../RangeRect.qml) (revision 9a0581274e4dc51af6d6f3e4dd932581e8dce445) @@ -35,6 +35,9 @@ property alias minText : _textMinimum property alias maxText : _textMaximum + property bool minTextHorizontalCenter: false + property bool maxTextHorizontalCenter: false + property string unit : "" property real touchMargin: 0 @@ -58,6 +61,7 @@ left : parent.left top : parent.bottom topMargin : Variables.rangeRectTextMargin + leftMargin : minTextHorizontalCenter ? -minText.width / 2 : 0 } } @@ -74,6 +78,7 @@ right : parent.right top : parent.bottom topMargin : Variables.rangeRectTextMargin + rightMargin : maxTextHorizontalCenter ? -maxText.width / 2 : 0 } } Index: sources/gui/qml/components/RangeSlider.qml =================================================================== diff -u -r605815f54dfac948ada786080f55d1b6e7a0d47b -r9a0581274e4dc51af6d6f3e4dd932581e8dce445 --- sources/gui/qml/components/RangeSlider.qml (.../RangeSlider.qml) (revision 605815f54dfac948ada786080f55d1b6e7a0d47b) +++ sources/gui/qml/components/RangeSlider.qml (.../RangeSlider.qml) (revision 9a0581274e4dc51af6d6f3e4dd932581e8dce445) @@ -34,10 +34,14 @@ Max } + property alias lowerText : _rangeRect.minText + property alias upperText : _rangeRect.maxText + property alias minValue : _rangeRect.lowerBound ///< value of the minimum slider handler property alias maxValue : _rangeRect.upperBound ///< value of the maximum slider handler property int curHandler : RangeSlider.HandlerOption.None ///< current active slider handler + property int diameter : Variables.progressbarHandler ///< handlers diameter property real step : 1 ///< each step difference property bool stepSnap : false ///< values within steps are not selectable if true @@ -95,6 +99,10 @@ return ( x * ( maximum - minimum ) ) / width + minimum } + function getXOfValue(vValue) { + return ((vValue - minimum) * width)/( maximum - minimum ) + } + /// /// \brief calculate the value by position x of the handler /// \details calculates the current value withing the range of minimum and maximum regarding the x cordinate of the active slider. @@ -164,10 +172,13 @@ decimal: _root.decimal minText { - visible: true - anchors.topMargin: -25 + visible: false + anchors.topMargin: -40 } - maxText.visible: true + maxText { + visible: false + anchors.topMargin: -40 + } // propagation is not working on drag ! // so it has to be implemented here as well @@ -226,7 +237,7 @@ /// Left most handler Rectangle { id: _handlerLeft - property real diameter : Variables.progressbarHandler + property real diameter : _root.diameter anchors.verticalCenter : parent.verticalCenter anchors.horizontalCenter: _rangeRect.left @@ -243,7 +254,7 @@ /// Right most handler Rectangle { id: _handlerRight - property real diameter : Variables.progressbarHandler + property real diameter : _root.diameter anchors.verticalCenter : parent.verticalCenter anchors.horizontalCenter : _rangeRect.right Index: sources/gui/qml/globals/Colors.qml =================================================================== diff -u -r605815f54dfac948ada786080f55d1b6e7a0d47b -r9a0581274e4dc51af6d6f3e4dd932581e8dce445 --- sources/gui/qml/globals/Colors.qml (.../Colors.qml) (revision 605815f54dfac948ada786080f55d1b6e7a0d47b) +++ sources/gui/qml/globals/Colors.qml (.../Colors.qml) (revision 9a0581274e4dc51af6d6f3e4dd932581e8dce445) @@ -23,8 +23,12 @@ * whcih is going to be used in the project */ QtObject { + readonly property color red : "#c53b33" // red + readonly property color white : "white" // white + readonly property color transparent : "Transparent" // No Color + readonly property color backgroundMain : "#1A344D" - readonly property color backgroundButtonNormal : "Transparent" + readonly property color backgroundButtonNormal : transparent readonly property color backgroundButtonSelect : "#438FEB" readonly property color backgroundDialog : "#254670" readonly property color backgroundMenu : "#14314C" @@ -35,62 +39,61 @@ readonly property color backgroundUltrafiltrationButton : "#31568F" readonly property color textValueUltrafiltrationButtonFg: "#98aec2" - readonly property color backgroundRangeRect : "#3e546e" readonly property color highlightProgressBar : "#3d8eef" readonly property color highlightMedProgressBar : "#1b2b3e" readonly property color textProgressBar : "#88a3c5" - readonly property color textRangeMarker : "white" - readonly property color rangeMarker : "white" + readonly property color textRangeMarker : white + readonly property color rangeMarker : white readonly property color rangeMarkerShort : "#9fb6d1" readonly property color textMain : "#FCFCFC" - readonly property color textButton : "#FCFCFC" //"#E8E8E8" + readonly property color textButton : "#FCFCFC" //"#E8E8E8" readonly property color textDisableButton : "#607A91" readonly property color textTickMark : "#438FEB" - readonly property color borderButton : "#4290EC" //K:D //"#438FEB" + readonly property color borderButton : "#4290EC" //K:D //"#438FEB" readonly property color borderDisableButton : "#607A91" readonly property color boderSeparatorLine : "#476982" - readonly property color borderDialog : "transparent" // "#D01A344D" // "#D00F0F0F" //"#F51A344D" + readonly property color borderDialog : transparent // "#D01A344D" // "#D00F0F0F" //"#F51A344D" readonly property color touchTextAreaTitle : "#a0b6d0" - readonly property color textTextRectTitle : "#ffffff" + readonly property color textTextRectTitle : white readonly property color textTextRectLabel : "#e8e8e8" readonly property color textTextRectExtra : "#708795" readonly property color line : "#094266" - readonly property color pressuresText : "white" + readonly property color pressuresText : white readonly property color pressuresArterialBar : "#31bcdb" readonly property color pressuresVenousBar : "#c568ed" - readonly property color pressuresOutOfRaneBg : "#c53b33" + readonly property color pressuresOutOfRaneBg : red - readonly property color fluidText : "white" - readonly property color fluidValue : "white" + readonly property color fluidText : white + readonly property color fluidValue : white readonly property color fluidUnit : "#708795" - readonly property color textNotificationNoneBg : "white" + readonly property color textNotificationNoneBg : white readonly property color textNotificationNoneFg : "#1b2b3e" - readonly property color textNotificationLowBg : "#f5a623" // ? - readonly property color textNotificationLowFg : "white" // ? + readonly property color textNotificationLowBg : "#f5a623" // ? + readonly property color textNotificationLowFg : white // ? - readonly property color textNotificationMedBg : "#f5a623" // ? - readonly property color textNotificationMedFg : "white" // ? + readonly property color textNotificationMedBg : "#f5a623" // ? + readonly property color textNotificationMedFg : white // ? - readonly property color textNotificationHighBg : "#c53b33" // red - readonly property color textNotificationHighFg : "white" + readonly property color textNotificationHighBg : red + readonly property color textNotificationHighFg : white readonly property color alarmTopBarHighBg : "#831913" - readonly property color alarmTopBarHighFg : "white" + readonly property color alarmTopBarHighFg : white readonly property color alarmTopBarMedBg : "#db8f00" - readonly property color alarmTopBarMedFg : "white" + readonly property color alarmTopBarMedFg : white readonly property color alarmTopBarLowBg : "#db8f00" - readonly property color alarmTopBarLowFg : "white" + readonly property color alarmTopBarLowFg : white } Index: sources/gui/qml/globals/Fonts.qml =================================================================== diff -u -r72fe36cdaa95eb8b68ba8a3714f8a92df65b4486 -r9a0581274e4dc51af6d6f3e4dd932581e8dce445 --- sources/gui/qml/globals/Fonts.qml (.../Fonts.qml) (revision 72fe36cdaa95eb8b68ba8a3714f8a92df65b4486) +++ sources/gui/qml/globals/Fonts.qml (.../Fonts.qml) (revision 9a0581274e4dc51af6d6f3e4dd932581e8dce445) @@ -39,6 +39,7 @@ readonly property int fontPixelRangeRectText : 14 readonly property int fontPixelPresseuresText : 22 + readonly property int fontPixelPresseuresLabel : 34 readonly property int fontPixelFluidText : 22 readonly property int fontPixelFluidValue : 32 Index: sources/gui/qml/globals/Variables.qml =================================================================== diff -u -r56e378f7504701b9e9a9dccaf205aef2fd52c58e -r9a0581274e4dc51af6d6f3e4dd932581e8dce445 --- sources/gui/qml/globals/Variables.qml (.../Variables.qml) (revision 56e378f7504701b9e9a9dccaf205aef2fd52c58e) +++ sources/gui/qml/globals/Variables.qml (.../Variables.qml) (revision 9a0581274e4dc51af6d6f3e4dd932581e8dce445) @@ -80,6 +80,8 @@ readonly property int pauseIconDiameter : 60 + readonly property int pressuresProgressbarWidth : 725 + readonly property int ultrafiltrationProgressbarWidth : 880 readonly property int ultrafiltrationAdjustmtenOptionWidth : 520 readonly property int ultrafiltrationAdjustmtenOptionHeight : 275 Index: sources/gui/qml/pages/treatment/TreatmentHome.qml =================================================================== diff -u -r605815f54dfac948ada786080f55d1b6e7a0d47b -r9a0581274e4dc51af6d6f3e4dd932581e8dce445 --- sources/gui/qml/pages/treatment/TreatmentHome.qml (.../TreatmentHome.qml) (revision 605815f54dfac948ada786080f55d1b6e7a0d47b) +++ sources/gui/qml/pages/treatment/TreatmentHome.qml (.../TreatmentHome.qml) (revision 9a0581274e4dc51af6d6f3e4dd932581e8dce445) @@ -58,32 +58,6 @@ } } - RangeSlider { id : _testSlider - y : 600 - x : (parent.width - width) / 2 - width : 700 - height : 5 - decimal : 1 - bgColor : Colors.pressuresOutOfRaneBg - minValue: 2 - maxValue: 3 - minText { - text : qsTr("LOW") - font.bold: true - color: "white" - } - maxText { - text : qsTr("HIGH") - font.bold: true - color: "white" - } - minimum : 0 // Variables.bloodFlowMin - maximum : 5 // Variables.bloodFlowMax - unit : Variables.unitTextFlowRate - step : 0.50 // Variables.bloodFlowResolution - ticks : true - } - onVisibleChanged: { if (visible) { _mainMenu.hidden = false Index: sources/gui/qml/pages/treatment/TreatmentStack.qml =================================================================== diff -u -r56e378f7504701b9e9a9dccaf205aef2fd52c58e -r9a0581274e4dc51af6d6f3e4dd932581e8dce445 --- sources/gui/qml/pages/treatment/TreatmentStack.qml (.../TreatmentStack.qml) (revision 56e378f7504701b9e9a9dccaf205aef2fd52c58e) +++ sources/gui/qml/pages/treatment/TreatmentStack.qml (.../TreatmentStack.qml) (revision 9a0581274e4dc51af6d6f3e4dd932581e8dce445) @@ -68,6 +68,12 @@ onSectionFlowClicked : { _treatmentAdjustmentFlow.open() } + onSectionVitalsClicked: { + // no page yet + } + onSectionPressuresClicked: { + _treatmentAdjustmentPressures.open() + } onSectionTimeClicked : { _treatmentAdjustmentDuration.durationValue = vTreatmentTime.time_Total / 60 // minutes => hours _treatmentAdjustmentDuration.open() @@ -93,6 +99,24 @@ onCloseClicked : close() onConfirmClicked : vTreatmentAdjustmentFlows.doAdjustment(bloodFlowRateValue, dialysateFlowRateValue) } + + TreatmentAdjustmentPressures{ id: _treatmentAdjustmentPressures + onCloseClicked : close() + //onConfirmClicked : vTreatmentAdjustmentFlows.doAdjustment(bloodFlowRateValue, dialysateFlowRateValue) + // TODO : TEST : values are real regarding PRS but has to be populated my Model. + arterialPressureMinimum : -400 + arterialPressureLowerBound : -300 + arterialPressureUpperBound : +100 + arterialPressureMaximum : +600 + arterialPressureValue : 70 + + venousPressureMinimum : -100 + venousPressureLowerBound : +100 + venousPressureUpperBound : +400 + venousPressureMaximum : +700 + venousPressureValue : 300 + } + TreatmentAdjustmentDuration { id: _treatmentAdjustmentDuration onCloseClicked : close() onConfirmClicked : vTreatmentAdjustmentDuration.doAdjustment(durationValue) Index: sources/gui/qml/pages/treatment/TreatmentStart.qml =================================================================== diff -u -r56e378f7504701b9e9a9dccaf205aef2fd52c58e -r9a0581274e4dc51af6d6f3e4dd932581e8dce445 --- sources/gui/qml/pages/treatment/TreatmentStart.qml (.../TreatmentStart.qml) (revision 56e378f7504701b9e9a9dccaf205aef2fd52c58e) +++ sources/gui/qml/pages/treatment/TreatmentStart.qml (.../TreatmentStart.qml) (revision 9a0581274e4dc51af6d6f3e4dd932581e8dce445) @@ -52,6 +52,8 @@ signal backClicked() signal sectionFlowClicked() + signal sectionVitalsClicked() + signal sectionPressuresClicked() signal sectionTimeClicked() signal sectionUltrafiltrationClicked() @@ -71,6 +73,9 @@ y : row2Y width : areaWidth height : areaHeightRow2 + onClicked: { + sectionVitalsClicked() + } } Line { x: 0; y: row2LineY; length: lineLength } TreatmentPressure { id: _pressureTouchArea @@ -89,6 +94,10 @@ y : row3Y width : areaWidth height : areaHeightRow3 + + onClicked: { + sectionPressuresClicked() + } } // ---------- COLUMN RIGHT Index: sources/gui/qml/pages/treatment/adjustments/TreatmentAdjustmentPressures.qml =================================================================== diff -u --- sources/gui/qml/pages/treatment/adjustments/TreatmentAdjustmentPressures.qml (revision 0) +++ sources/gui/qml/pages/treatment/adjustments/TreatmentAdjustmentPressures.qml (revision 9a0581274e4dc51af6d6f3e4dd932581e8dce445) @@ -0,0 +1,290 @@ +/*! + * + * Copyright (c) 2019-2020 Diality Inc. - All Rights Reserved. + * \copyright + * THIS CODE MAY NOT BE COPIED OR REPRODUCED IN ANY FORM, IN PART OR IN + * WHOLE, WITHOUT THE EXPLICIT PERMISSION OF THE COPYRIGHT OWNER. + * + * \file TreatmentAdjustmentFlow.qml + * \author (last) Behrouz NematiPour + * \date (last) 30-Jul-2020 + * \author (original) Behrouz NematiPour + * \date (original) 22-Mar-2020 + * + */ + +// Qt +import QtQuick 2.12 + +// Project + +// Qml imports +import "qrc:/globals" +import "qrc:/components" + +/*! + * \brief TreatmentAdjustmentPressures.qml is the screen + * To adjust the treatment inline blood pressure ranges of Arterial and venous + */ +TreatmentAdjustmentBase { id: _root + contentItem.objectName: "TreatmentAdjustmentPressures" //SquishQt testability + + property alias arterialPressureMinimum : _arterialPressureRangeBar.minimum + property alias arterialPressureLowerBound : _arterialPressureRangeBar.lowerBound + property alias arterialPressureUpperBound : _arterialPressureRangeBar.upperBound + property alias arterialPressureMaximum : _arterialPressureRangeBar.maximum + property alias arterialPressureValue : _arterialPressureRangeBar.value + property real arterialPressureStep : 10 + + property alias venousPressureMinimum : _venousPressureRangeBar.minimum + property alias venousPressureLowerBound: _venousPressureRangeBar.lowerBound + property alias venousPressureUpperBound: _venousPressureRangeBar.upperBound + property alias venousPressureMaximum : _venousPressureRangeBar.maximum + property alias venousPressureValue : _venousPressureRangeBar.value + property real venousPressureStep : 10 + + readonly property int textWidth : 200 + readonly property int slidersTopMargin : 75 + + titleText: qsTr("PRESSURES") + + //// Note : The slider values are not bound and will be set by user freely + //// and will be used to be sent for adjustment + //// if accepted will not changed and + //// if rejected then will be reset to the values passed by adjustment response + //// + //// reset the flow values to the current flow values + //// function currentFlows() { + //// _bloodFlowSlider.value = vTreatmentBloodFlow. bloodFlow_FlowSetPoint + //// _dialysateFlowSlider.value = vTreatmentDialysateFlow.dialysateFlow_FlowSetPoint + //// } + //// + //// // reset the flow values to the values of the adjustment response + //// function resetFlows() { + //// _bloodFlowSlider.value = vTreatmentAdjustmentFlows. bloodFlow_FlowSetPoint + //// _dialysateFlowSlider.value = vTreatmentAdjustmentFlows.dialysateFlow_FlowSetPoint + //// } + //// + //// onAboutToShow: { + //// // TODO : When Testing data on Setting screen is removed + //// // This needs to be moved into the Treatment______.qml + //// currentFlows() + //// } + //// + //// Connections { target: vTreatmentAdjustmentFlows + //// onAdjustmentTriggered: { + //// if ( vTreatmentAdjustmentFlows.adjustment_Accepted ) { + //// accept() + //// } else { + //// resetFlows() + //// notification.text = vTreatmentAdjustmentFlows.text() + //// } + //// } + //// } + + Column { id : _pressuresColumn + spacing: 100 + anchors.centerIn: parent + Row { id : _arterialPressureRow + spacing: 25 + anchors.horizontalCenter: parent.horizontalCenter + TextRect { id: _arterialPressureTextRect + anchors.top: parent.top + width: textWidth + label: qsTr("Arterial") + extra: Variables.unitTextBloodPressure + labelFont.pixelSize: Fonts.fontPixelPresseuresLabel + } + RangeBar { id: _arterialPressureRangeBar + width : Variables.pressuresProgressbarWidth + height : 15 + + rangebar.color: Colors.pressuresArterialBar + + value : vTreatmentPressureOcclusion.pressureocclusion_ArterialPressure + + minimum : _root.arterialMinimum + lowerBound : _root.arterialLowerBound + upperBound : _root.arterialUpperBound + maximum : _root.arterialMaximum + + minText.visible : lowerBound !== minimum + maxText.visible : upperBound !== maximum + minText.anchors.topMargin: 25 + maxText.anchors.topMargin: 25 + minTextHorizontalCenter: true + maxTextHorizontalCenter: true + + minText.font.pixelSize : Fonts.fontPixelPresseuresText + maxText.font.pixelSize : Fonts.fontPixelPresseuresText + rangebar.minText.font.pixelSize : Fonts.fontPixelPresseuresText + rangebar.maxText.font.pixelSize : Fonts.fontPixelPresseuresText + markerFontSize : Fonts.fontPixelPresseuresText + + markerOutRangeNotify : true + } + } + Line { + anchors.horizontalCenter: parent.horizontalCenter + length : _root.width - 100 + color : "#5f809d" + } + Row { id : _venousPressureRow + spacing: 25 + anchors.horizontalCenter: parent.horizontalCenter + TextRect { id: _venousPressureTextRect + anchors.top: parent.top + width: textWidth + label: qsTr("Venous") + extra: Variables.unitTextBloodPressure + labelFont.pixelSize: Fonts.fontPixelPresseuresLabel + } + RangeBar { id: _venousPressureRangeBar + width : Variables.pressuresProgressbarWidth + height : 15 + rangebar.color: Colors.pressuresVenousBar + + value : vTreatmentPressureOcclusion.pressureocclusion_VenousPressure + + minimum : _root.venousPressureMinimum + lowerBound : _root.venousPressureLowerBound + upperBound : _root.venousPressureUpperBound + maximum : _root.venousPressureMaximum + + minText.visible : lowerBound !== minimum + maxText.visible : upperBound !== maximum + minText.anchors.topMargin: 25 + maxText.anchors.topMargin: 25 + minTextHorizontalCenter: true + maxTextHorizontalCenter: true + + minText.font.pixelSize : Fonts.fontPixelPresseuresText + maxText.font.pixelSize : Fonts.fontPixelPresseuresText + rangebar.minText.font.pixelSize : Fonts.fontPixelPresseuresText + rangebar.maxText.font.pixelSize : Fonts.fontPixelPresseuresText + markerFontSize : Fonts.fontPixelPresseuresText + + markerOutRangeNotify : true + } + } + } + + RangeSlider { id: _arterialPressureSlider + property int diff: getXOfValue(-300) + // vertical position + y: _arterialPressureRangeBar.height + + _arterialPressureRangeBar.y + + _pressuresColumn .y + + _arterialPressureRow .y + + slidersTopMargin + + // horizontal location + x: _arterialPressureRangeBar.x + + _pressuresColumn .x + + _arterialPressureRow .x + + diff + width : _arterialPressureRangeBar.width - diff + // HERE : 2020/09/29 + // I have an error : + // qrc:/pages/treatment/adjustments/TreatmentAdjustmentPressures.qml:172:5: QML RangeSlider: Binding loop detected for property "diff" + + height : 5 + diameter: 30 + + decimal : 1 + bgColor : Colors.pressuresOutOfRaneBg + + //// //TODO : TEST : these two texts need to be removed + //// lowerText.visible: true + //// upperText.visible: true + + minText { + text : qsTr("LOW") + font.bold: true + font.pixelSize: Fonts.fontPixelPresseuresText + anchors.leftMargin: - minText.width - 20 + anchors.topMargin : - minText.height / 2 - 5 + color: "white" + } + maxText { + text : qsTr("HIGH") + font.bold: true + font.pixelSize: Fonts.fontPixelPresseuresText + anchors.rightMargin: - minText.width - 20 + anchors.topMargin : - minText.height / 2 - 5 + color: "white" + } + minValue: arterialPressureLowerBound + maxValue: arterialPressureUpperBound + minimum : arterialPressureMinimum + maximum : arterialPressureMaximum + unit : Variables.unitTextBloodPressure + step : arterialPressureStep + //ticks : true + + onMinValueChanged: { + arterialPressureLowerBound = minValue + } + onMaxValueChanged: { + arterialPressureUpperBound = maxValue + } + } + + RangeSlider { id: _venousPressureSliders + // vertical position + y: _venousPressureRangeBar .height + + _venousPressureRangeBar .y + + _pressuresColumn .y + + _venousPressureRow .y + + slidersTopMargin + + + // horizontal location + x: _venousPressureRangeBar .x + + _pressuresColumn .x + + _venousPressureRow .x + width : _venousPressureRangeBar.width + + height : 5 + diameter: 30 + + decimal : 1 + bgColor : Colors.pressuresOutOfRaneBg + + //// //TODO : TEST : these two texts need to be removed + //// lowerText.visible: trues + //// upperText.visible: true + + minText { + text : qsTr("LOW") + font.bold: true + font.pixelSize: Fonts.fontPixelPresseuresText + anchors.leftMargin: - minText.width - 20 + anchors.topMargin : - minText.height / 2 - 5 + color: "white" + } + maxText { + text : qsTr("HIGH") + font.bold: true + font.pixelSize: Fonts.fontPixelPresseuresText + anchors.rightMargin: - minText.width - 20 + anchors.topMargin : - minText.height / 2 - 5 + color: "white" + } + minimum : venousPressureMinimum + maximum : venousPressureMaximum + unit : Variables.unitTextBloodPressure + step : venousPressureStep + //ticks : true + + minValue: venousPressureLowerBound + maxValue: venousPressureUpperBound + + onMinValueChanged: { + venousPressureLowerBound = minValue + } + onMaxValueChanged: { + venousPressureUpperBound = maxValue + } + } +} Index: sources/gui/qml/pages/treatment/sections/TreatmentPressure.qml =================================================================== diff -u -r56e378f7504701b9e9a9dccaf205aef2fd52c58e -r9a0581274e4dc51af6d6f3e4dd932581e8dce445 --- sources/gui/qml/pages/treatment/sections/TreatmentPressure.qml (.../TreatmentPressure.qml) (revision 56e378f7504701b9e9a9dccaf205aef2fd52c58e) +++ sources/gui/qml/pages/treatment/sections/TreatmentPressure.qml (.../TreatmentPressure.qml) (revision 9a0581274e4dc51af6d6f3e4dd932581e8dce445) @@ -52,10 +52,10 @@ width : 175 height : 15 rangebar.color: Colors.pressuresArterialBar + markerOutRangeNotify: true value : vTreatmentPressureOcclusion.pressureocclusion_ArterialPressure - // TEST : simulation code minimum : _root.arterialMinimum lowerBound : _root.arterialLowerBound upperBound : _root.arterialUpperBound @@ -71,6 +71,7 @@ font.pixelSize: Fonts.fontPixelPresseuresText color: Colors.pressuresText } + onClicked: _root.clicked() } RangeBar { id: _venousRangeBar @@ -79,6 +80,7 @@ width : 175 height : 15 rangebar.color: Colors.pressuresVenousBar + markerOutRangeNotify: true value : vTreatmentPressureOcclusion.pressureocclusion_VenousPressure @@ -97,5 +99,6 @@ font.pixelSize: Fonts.fontPixelPresseuresText color: Colors.pressuresText } + onClicked: _root.clicked() } }