mirror of
https://gitlab.com/pholy/OSCAR-code.git
synced 2025-04-17 03:00:46 +00:00
Highlight ZEO days in calendar, Graph tooltip showing stage meanings
This commit is contained in:
parent
e3ff868cf1
commit
0bd5c35706
@ -545,6 +545,7 @@ void Daily::UpdateCalendarDay(QDate date)
|
|||||||
QTextCharFormat oxiday;
|
QTextCharFormat oxiday;
|
||||||
QTextCharFormat oxicpap;
|
QTextCharFormat oxicpap;
|
||||||
QTextCharFormat jourday;
|
QTextCharFormat jourday;
|
||||||
|
QTextCharFormat stageday;
|
||||||
|
|
||||||
cpaponly.setForeground(QBrush(Qt::blue, Qt::SolidPattern));
|
cpaponly.setForeground(QBrush(Qt::blue, Qt::SolidPattern));
|
||||||
cpaponly.setFontWeight(QFont::Normal);
|
cpaponly.setFontWeight(QFont::Normal);
|
||||||
@ -554,6 +555,8 @@ void Daily::UpdateCalendarDay(QDate date)
|
|||||||
oxiday.setFontWeight(QFont::Normal);
|
oxiday.setFontWeight(QFont::Normal);
|
||||||
oxicpap.setForeground(QBrush(Qt::red, Qt::SolidPattern));
|
oxicpap.setForeground(QBrush(Qt::red, Qt::SolidPattern));
|
||||||
oxicpap.setFontWeight(QFont::Bold);
|
oxicpap.setFontWeight(QFont::Bold);
|
||||||
|
stageday.setForeground(QBrush(Qt::magenta, Qt::SolidPattern));
|
||||||
|
stageday.setFontWeight(QFont::Bold);
|
||||||
jourday.setForeground(QBrush(QColor("black"), Qt::SolidPattern));
|
jourday.setForeground(QBrush(QColor("black"), Qt::SolidPattern));
|
||||||
jourday.setFontWeight(QFont::Bold);
|
jourday.setFontWeight(QFont::Bold);
|
||||||
nodata.setForeground(QBrush(QColor("black"), Qt::SolidPattern));
|
nodata.setForeground(QBrush(QColor("black"), Qt::SolidPattern));
|
||||||
@ -562,11 +565,14 @@ void Daily::UpdateCalendarDay(QDate date)
|
|||||||
bool hascpap=PROFILE.GetDay(date,MT_CPAP)!=NULL;
|
bool hascpap=PROFILE.GetDay(date,MT_CPAP)!=NULL;
|
||||||
bool hasoxi=PROFILE.GetDay(date,MT_OXIMETER)!=NULL;
|
bool hasoxi=PROFILE.GetDay(date,MT_OXIMETER)!=NULL;
|
||||||
bool hasjournal=PROFILE.GetDay(date,MT_JOURNAL)!=NULL;
|
bool hasjournal=PROFILE.GetDay(date,MT_JOURNAL)!=NULL;
|
||||||
|
bool hasstage=PROFILE.GetDay(date,MT_SLEEPSTAGE)!=NULL;
|
||||||
if (hascpap) {
|
if (hascpap) {
|
||||||
if (hasoxi) {
|
if (hasoxi) {
|
||||||
ui->calendar->setDateTextFormat(date,oxicpap);
|
ui->calendar->setDateTextFormat(date,oxicpap);
|
||||||
} else if (hasjournal) {
|
} else if (hasjournal) {
|
||||||
ui->calendar->setDateTextFormat(date,cpapjour);
|
ui->calendar->setDateTextFormat(date,cpapjour);
|
||||||
|
} else if (hasstage) {
|
||||||
|
ui->calendar->setDateTextFormat(date,stageday);
|
||||||
} else {
|
} else {
|
||||||
ui->calendar->setDateTextFormat(date,cpaponly);
|
ui->calendar->setDateTextFormat(date,cpaponly);
|
||||||
}
|
}
|
||||||
|
6
daily.ui
6
daily.ui
@ -814,6 +814,12 @@
|
|||||||
</item>
|
</item>
|
||||||
<item>
|
<item>
|
||||||
<widget class="QComboBox" name="graphCombo">
|
<widget class="QComboBox" name="graphCombo">
|
||||||
|
<property name="sizePolicy">
|
||||||
|
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
|
||||||
|
<horstretch>0</horstretch>
|
||||||
|
<verstretch>0</verstretch>
|
||||||
|
</sizepolicy>
|
||||||
|
</property>
|
||||||
<property name="toolTip">
|
<property name="toolTip">
|
||||||
<string>Drop down this list to show/hide available graphs.</string>
|
<string>Drop down this list to show/hide available graphs.</string>
|
||||||
</property>
|
</property>
|
||||||
|
@ -118,7 +118,7 @@ Important: One id code per item, DO NOT CHANGE ID NUMBERS!!!
|
|||||||
<channel id="0x1804" class="data" name="SPO2Drop" details="SPO2Drop" label="SPO2 Drop" color="light blue"/>
|
<channel id="0x1804" class="data" name="SPO2Drop" details="SPO2Drop" label="SPO2 Drop" color="light blue"/>
|
||||||
</group>
|
</group>
|
||||||
<group name="SLEEP">
|
<group name="SLEEP">
|
||||||
<channel id="0x2000" class="data" name="SleepStage" details="Sleep Stage" label="Sleep Stage" color="dark grey"/>
|
<channel id="0x2000" class="data" name="SleepStage" details="Sleep Stage" label="Sleep Stage" unit="1=Awake 2=REM 3=Light Sleep 4=Deep Sleep" color="dark grey"/>
|
||||||
<channel id="0x2001" class="data" name="ZeoBW" details="Zeo Brainwave" label="ZeoWave" color="black"/>
|
<channel id="0x2001" class="data" name="ZeoBW" details="Zeo Brainwave" label="ZeoWave" color="black"/>
|
||||||
<channel id="0x2002" class="data" name="Awakenings" details="Awakenings" label="Awakenings" color="black"/>
|
<channel id="0x2002" class="data" name="Awakenings" details="Awakenings" label="Awakenings" color="black"/>
|
||||||
<channel id="0x2003" class="data" name="MorningFeel" details="ZEO Morning Feel" label="Morning Feel" color="black"/>
|
<channel id="0x2003" class="data" name="MorningFeel" details="ZEO Morning Feel" label="Morning Feel" color="black"/>
|
||||||
|
Loading…
Reference in New Issue
Block a user