# HG changeset patch # User Chris Cannam # Date 1485465397 0 # Node ID 6f0d7aa25816e4a19784ab24842027fc88a7cdfb # Parent 37f86e26a8d2b108dde56538fbb166c17cbdef7f Scale pen used for centre line diff -r 37f86e26a8d2 -r 6f0d7aa25816 view/Pane.cpp --- a/view/Pane.cpp Thu Jan 26 21:15:36 2017 +0000 +++ b/view/Pane.cpp Thu Jan 26 21:16:37 2017 +0000 @@ -566,6 +566,8 @@ { Layer *scaleLayer = 0; +// cerr << "Pane::drawVerticalScale[" << this << "]" << endl; + double min, max; bool log; QString unit; @@ -580,6 +582,8 @@ int sw = topLayer->getVerticalScaleWidth (this, m_manager->shouldShowVerticalColourScale(), paint); +// cerr << "sw = " << sw << endl; + if (sw > 0) { scaleLayer = topLayer; m_scaleWidth = sw; @@ -645,7 +649,9 @@ } if (!scaleLayer) m_scaleWidth = 0; - + +// cerr << "m_scaleWidth = " << m_scaleWidth << ", r.left = " << r.left() << endl; + if (m_scaleWidth > 0 && r.left() < m_scaleWidth) { // Profiler profiler("Pane::paintEvent - painting vertical scale", true); @@ -734,7 +740,7 @@ c = QColor(240, 240, 240); } - paint.setPen(c); + paint.setPen(PaintAssistant::scalePen(c)); int x = width() / 2; if (!omitLine) {