Index: sources/gui/qml/compounds/BPHREntry.qml =================================================================== diff -u -r31b1e7a5d69f014398827e16286f28515cd60e35 -r23121e17d1a6120ae4a31930e18de362d9533bcb --- sources/gui/qml/compounds/BPHREntry.qml (.../BPHREntry.qml) (revision 31b1e7a5d69f014398827e16286f28515cd60e35) +++ sources/gui/qml/compounds/BPHREntry.qml (.../BPHREntry.qml) (revision 23121e17d1a6120ae4a31930e18de362d9533bcb) @@ -26,7 +26,7 @@ * \details and dynamically creates list of items which can be later set as started/done to have * bussy circle or check mark as done. */ -Item { id: _root + Item { id: _root property int labelWidth : 200 property int unitWidth : 100 property int entryWidth : 100 @@ -63,85 +63,71 @@ anchors.fill: parent - Row { id: _container - spacing: 50 + Column { id: _container + spacing : 50 + leftPadding : _root.titleIndent anchors.centerIn: parent - Column { - spacing : 25 - leftPadding : _root.titleIndent - Row { - spacing : 10 - TextEntry { id : _bloodPressureSystolic - text : Variables.notSetVariable(vTreatmentVitals.systolic, 0) - label.text : qsTr("Blood Pressure") - label.width : _root.labelWidth - validator : IntValidator { bottom: vTreatmentVitals.systolicMin; top : vTreatmentVitals.systolicMax } - nextInput : _bloodPressureDiastolic - textInput.color: (textInput.acceptableInput && _private.isBloodPressureCompareValid) ? Colors.textMain : Colors.red - useQtNumPad : false + Row { + spacing : 10 + TextEntry { id : _bloodPressureSystolic + text : Variables.notSetVariable(vTreatmentVitals.systolic, 0) + label.text : qsTr("Blood Pressure") + label.width : _root.labelWidth + validator : IntValidator { bottom: vTreatmentVitals.systolicMin; top : vTreatmentVitals.systolicMax } + nextInput : _bloodPressureDiastolic + textInput.color: (textInput.acceptableInput && _private.isBloodPressureCompareValid) ? Colors.textMain : Colors.red + useQtNumPad : false - onClicked : numPad.open ( _bloodPressureSystolic, - qsTr("Systolic"), - vTreatmentVitals.systolicMin, - vTreatmentVitals.systolicMax, - Variables.unitTextBloodPressure) - } - Label { - text : "/" - width : 10 - } - TextEntry { id : _bloodPressureDiastolic - text : Variables.notSetVariable(vTreatmentVitals.diastolic, 0) - label.width : 0 - validator : IntValidator { bottom: vTreatmentVitals.diastolicMin; top : vTreatmentVitals.diastolicMax } - nextInput : _heartRate - textInput.color: (textInput.acceptableInput && _private.isBloodPressureCompareValid) ? Colors.textMain : Colors.red - useQtNumPad : false - - onClicked : numPad.open ( _bloodPressureDiastolic, - qsTr("Diastolic"), - vTreatmentVitals.diastolicMin, - _bloodPressureSystolic.textInput.acceptableInput && - _bloodPressureSystolic.text < vTreatmentVitals.diastolicMax ? _bloodPressureSystolic.text : - vTreatmentVitals.diastolicMax, - Variables.unitTextBloodPressure) - } - Label { - text : Variables.unitTextBloodPressure - width : unitWidth - } + onClicked : numPad.open ( _bloodPressureSystolic, + qsTr("Systolic"), + vTreatmentVitals.systolicMin, + vTreatmentVitals.systolicMax, + Variables.unitTextBloodPressure) } - Row { - spacing : 10 - TextEntry { id : _heartRate - text : Variables.notSetVariable(vTreatmentVitals.heartRate, 0) - label.text : qsTr("Heart Rate") - label.width : _root.labelWidth - validator : IntValidator { bottom: vTreatmentVitals.heartRateMin; top : vTreatmentVitals.heartRateMax } - useQtNumPad : false + Label { + text : "/" + width : 10 + } + TextEntry { id : _bloodPressureDiastolic + text : Variables.notSetVariable(vTreatmentVitals.diastolic, 0) + label.width : 0 + validator : IntValidator { bottom: vTreatmentVitals.diastolicMin; top : vTreatmentVitals.diastolicMax } + nextInput : _heartRate + textInput.color: (textInput.acceptableInput && _private.isBloodPressureCompareValid) ? Colors.textMain : Colors.red + useQtNumPad : false - onClicked : numPad.open ( _heartRate, - qsTr("Heart Rate"), - vTreatmentVitals.heartRateMin, - vTreatmentVitals.heartRateMax, - Variables.unitTextHeartBeat) - } - Label { - text : Variables.unitTextHeartBeat - width : unitWidth - } + onClicked : numPad.open ( _bloodPressureDiastolic, + qsTr("Diastolic"), + vTreatmentVitals.diastolicMin, + _bloodPressureSystolic.textInput.acceptableInput && + _bloodPressureSystolic.text < vTreatmentVitals.diastolicMax ? _bloodPressureSystolic.text : + vTreatmentVitals.diastolicMax, + Variables.unitTextBloodPressure) } + Label { + text : Variables.unitTextBloodPressure + width : unitWidth + } + } + Row { + spacing : 10 + TextEntry { id : _heartRate + text : Variables.notSetVariable(vTreatmentVitals.heartRate, 0) + label.text : qsTr("Heart Rate") + label.width : _root.labelWidth + validator : IntValidator { bottom: vTreatmentVitals.heartRateMin; top : vTreatmentVitals.heartRateMax } + useQtNumPad : false -// Text { id: _lastRecorded -// height : 50 -// width : 50 -// font.pixelSize : 16 -// font.weight : Font.Normal -// verticalAlignment : Text.AlignBottom -// color : Colors.textMain -// text : qsTr("Last Recorded: %1").arg(vTreatmentVitals.lastRead) -// } - + onClicked : numPad.open ( _heartRate, + qsTr("Heart Rate"), + vTreatmentVitals.heartRateMin, + vTreatmentVitals.heartRateMax, + Variables.unitTextHeartBeat) + } + Label { + text : Variables.unitTextHeartBeat + width : unitWidth + } } } }