Mercurial > hg > svgui
diff layer/TimeValueLayer.cpp @ 1315:1d7921b1852f
Ensure scale appears for layer when drawn in AutoAlign mode without any other layer present to align to
author | Chris Cannam |
---|---|
date | Wed, 04 Jul 2018 15:34:16 +0100 |
parents | a34a2a25907c |
children | d79e21855aef |
line wrap: on
line diff
--- a/layer/TimeValueLayer.cpp Wed Jul 04 15:33:47 2018 +0100 +++ b/layer/TimeValueLayer.cpp Wed Jul 04 15:34:16 2018 +0100 @@ -1238,7 +1238,9 @@ int TimeValueLayer::getVerticalScaleWidth(LayerGeometryProvider *v, bool, QPainter &paint) const { - if (!m_model || shouldAutoAlign()) { + if (!m_model) { + return 0; + } else if (shouldAutoAlign() && !valueExtentsMatchMine(v)) { return 0; } else if (m_plotStyle == PlotSegmentation) { if (m_verticalScale == LogScale) {