Mercurial > hg > svgui
diff view/View.cpp @ 283:86a112b5b319
* Make it possible to "measure" a feature on the spectrogram by double-
clicking in measure mode
* Make shift-click-drag (for zoom to region) work in measure mode as well
as navigate mode. It would be nice to be able to shift-doubleclick to
zoom on a feature directly using a combination of these last two features,
but that isn't possible yet.
* Make Del delete the measurement under the mouse pointer.
author | Chris Cannam |
---|---|
date | Thu, 05 Jul 2007 15:36:37 +0000 |
parents | 47fe0352861e |
children | cd2492c5fe45 |
line wrap: on
line diff
--- a/view/View.cpp Thu Jul 05 11:07:01 2007 +0000 +++ b/view/View.cpp Thu Jul 05 15:36:37 2007 +0000 @@ -1737,7 +1737,7 @@ } } - if (b0 && b1 && u0 == u1) { + if (b0 && b1 && v1 != v0 && u0 == u1) { dxs = QString("(%1 %2)").arg(fabs(v1 - v0)).arg(u1); dw = paint.fontMetrics().width(dxs); } @@ -1771,7 +1771,8 @@ QString du; if ((bd = topLayer->getYScaleDifference(this, r.y(), r.y() + r.height(), - dy, du))) { + dy, du)) && + dy != 0) { if (du != "") { dys = QString("(%1 %2)").arg(dy).arg(du); } else {