summaryrefslogtreecommitdiff
path: root/gr-qtgui/lib/TimeDomainDisplayPlot.cc
diff options
context:
space:
mode:
Diffstat (limited to 'gr-qtgui/lib/TimeDomainDisplayPlot.cc')
-rw-r--r--gr-qtgui/lib/TimeDomainDisplayPlot.cc10
1 files changed, 4 insertions, 6 deletions
diff --git a/gr-qtgui/lib/TimeDomainDisplayPlot.cc b/gr-qtgui/lib/TimeDomainDisplayPlot.cc
index 2ddb4aebcf..7cd803a509 100644
--- a/gr-qtgui/lib/TimeDomainDisplayPlot.cc
+++ b/gr-qtgui/lib/TimeDomainDisplayPlot.cc
@@ -80,15 +80,12 @@ public:
protected:
using QwtPlotZoomer::trackerText;
-#if QWT_VERSION < 0x060000
- virtual QwtText trackerText( const QwtDoublePoint& p ) const
-#else
virtual QwtText trackerText( const QPoint& p ) const
-#endif
{
- QwtText t(QString("%1 %2, %3 V").arg(p.x(), 0, 'f', GetTimePrecision()).
+ QwtDoublePoint dp = QwtPlotZoomer::invTransform(p);
+ QwtText t(QString("%1 %2, %3 V").arg(dp.x(), 0, 'f', GetTimePrecision()).
arg(_unitType.c_str()).
- arg(p.y(), 0, 'f', 4));
+ arg(dp.y(), 0, 'f', 4));
return t;
}
@@ -179,6 +176,7 @@ TimeDomainDisplayPlot::TimeDomainDisplayPlot(int nplots, QWidget* parent)
connect(_picker, SIGNAL(selected(const QwtDoublePoint &)),
this, SLOT(OnPickerPointSelected(const QwtDoublePoint &)));
#else
+ _picker->setStateMachine(new QwtPickerDblClickPointMachine());
connect(_picker, SIGNAL(selected(const QPointF &)),
this, SLOT(OnPickerPointSelected6(const QPointF &)));
#endif