diff --git a/qt-ui/preferences.cpp b/qt-ui/preferences.cpp
index 68dcbf2a0..dd484b6e8 100644
--- a/qt-ui/preferences.cpp
+++ b/qt-ui/preferences.cpp
@@ -41,7 +41,7 @@ PreferencesDialog::PreferencesDialog(QWidget* parent, Qt::WindowFlags f) : QDial
ui->calculated_ceiling->setChecked(B(calcceiling, profile_calc_ceiling));
ui->increment_3m->setEnabled(ui->calculated_ceiling->isChecked());
ui->increment_3m->setChecked(B(calcceiling3m, calc_ceiling_3m_incr));
- ui->all_tissues->setEnabled(ui->all_tissues->isChecked());
+ ui->all_tissues->setEnabled(ui->calculated_ceiling->isChecked());
ui->all_tissues->setChecked(B(calcalltissues, calc_all_tissues));
ui->gflow->setValue((int)(I(gflow, gflow)));
diff --git a/qt-ui/preferences.ui b/qt-ui/preferences.ui
index 1617c453b..3cef8785a 100644
--- a/qt-ui/preferences.ui
+++ b/qt-ui/preferences.ui
@@ -6,8 +6,8 @@
0
0
- 604
- 490
+ 698
+ 521
@@ -731,8 +731,8 @@
accept()
- 226
- 522
+ 235
+ 511
157
@@ -747,8 +747,8 @@
reject()
- 294
- 522
+ 303
+ 511
286
@@ -767,8 +767,8 @@
97
- 186
- 8
+ 282
+ 18
@@ -779,12 +779,12 @@
setEnabled(bool)
- 288
- 179
+ 187
+ 77
- 681
- 194
+ 581
+ 80
@@ -795,12 +795,12 @@
setEnabled(bool)
- 301
- 179
+ 187
+ 77
- 742
- 184
+ 668
+ 80
@@ -811,12 +811,12 @@
setEnabled(bool)
- 295
- 208
+ 186
+ 121
- 673
- 216
+ 581
+ 124
@@ -827,12 +827,12 @@
setEnabled(bool)
- 301
- 206
+ 186
+ 121
- 740
- 216
+ 668
+ 124
@@ -843,12 +843,12 @@
setEnabled(bool)
- 296
- 240
+ 184
+ 165
- 683
- 242
+ 581
+ 168
@@ -859,12 +859,12 @@
setEnabled(bool)
- 304
- 232
+ 184
+ 165
- 760
- 236
+ 668
+ 168
@@ -875,12 +875,12 @@
setEnabled(bool)
- 294
- 267
+ 195
+ 209
- 692
- 271
+ 591
+ 212
@@ -891,12 +891,12 @@
setEnabled(bool)
- 286
- 261
+ 195
+ 209
- 760
- 269
+ 668
+ 212
@@ -907,12 +907,12 @@
setEnabled(bool)
- 288
- 344
+ 298
+ 327
- 555
- 351
+ 512
+ 327
@@ -923,12 +923,28 @@
setEnabled(bool)
- 198
- 286
+ 298
+ 327
- 503
- 286
+ 668
+ 327
+
+
+
+
+ dc_reported_ceiling
+ clicked(bool)
+ red_ceiling
+ setEnabled(bool)
+
+
+ 362
+ 275
+
+
+ 586
+ 270
diff --git a/qt-ui/profilegraphics.cpp b/qt-ui/profilegraphics.cpp
index d635e1956..fb336da72 100644
--- a/qt-ui/profilegraphics.cpp
+++ b/qt-ui/profilegraphics.cpp
@@ -1074,28 +1074,26 @@ void ProfileGraphicsView::plot_depth_profile()
}
/* plot the calculated ceiling for all tissues */
- if (prefs.calc_all_tissues){
+ if (prefs.profile_calc_ceiling && prefs.calc_all_tissues){
int k;
for (k=0; k<16; k++){
- if (prefs.profile_calc_ceiling) {
- pat.setColorAt(0, profile_color[CALC_CEILING_SHALLOW].first());
- pat.setColorAt(1, QColor(100, 100, 100, 50));
+ pat.setColorAt(0, profile_color[CALC_CEILING_SHALLOW].first());
+ pat.setColorAt(1, QColor(100, 100, 100, 50));
- entry = gc.pi.entry;
- p.clear();
- p.append(QPointF(SCALEGC(0, 0)));
- for (i = 0; i < gc.pi.nr; i++, entry++) {
- if ((entry->ceilings)[k])
- p.append(QPointF(SCALEGC(entry->sec, (entry->ceilings)[k])));
- else
- p.append(QPointF(SCALEGC(entry->sec, 0)));
- }
- p.append(QPointF(SCALEGC((entry-1)->sec, 0)));
- neatFill = new QGraphicsPolygonItem();
- neatFill->setPolygon(p);
- neatFill->setBrush(pat);
- scene()->addItem(neatFill);
+ entry = gc.pi.entry;
+ p.clear();
+ p.append(QPointF(SCALEGC(0, 0)));
+ for (i = 0; i < gc.pi.nr; i++, entry++) {
+ if ((entry->ceilings)[k])
+ p.append(QPointF(SCALEGC(entry->sec, (entry->ceilings)[k])));
+ else
+ p.append(QPointF(SCALEGC(entry->sec, 0)));
}
+ p.append(QPointF(SCALEGC((entry-1)->sec, 0)));
+ neatFill = new QGraphicsPolygonItem();
+ neatFill->setPolygon(p);
+ neatFill->setBrush(pat);
+ scene()->addItem(neatFill);
}
}
/* next show where we have been bad and crossed the dc's ceiling */