Hi,

I have now integrated a PlotPicker in my QwtPlot and coded a function which should set the picked x and y location in two QLabes:

Qt Code:
  1. void MainWindow::valuePlotPickerSelected( const QwtDoublePoint& point)
  2. {
  3. QString temp; temp.setNum(point.x());
  4. valuePlotX->setText(temp); temp.setNum(point.y());
  5. valuePlotY->setText(temp);
  6. }
To copy to clipboard, switch view to plain text mode 

This seems to work most of the time. But when I don't replot or even sometimes when i replot it sets the x value to 0.
Y value is allways correct, but I sometimes can pick many points and it is sheer luck if the x value is correct or 0.

What could the problem be? Is it a problem, that there can be less x values than I have pixels on the QwtPlot?

Thanks for taking the time!
sun