Hello everyone,
I have embedded a QwtPlot canvas in a QGraphicsItem using QGraphicsProxyWidget as a child of my QGraphicsItem.
Everything is ok but a strange behavior of the QwtPlotPicker object I have added to be able to select part of the data displayed.

My picker is associated with a QwtPickerDragRectMachine, it has a RectRubberdand and is always on.

When the mouse is pressed the Rubber band is displayed but.. it never ends.
Other mouse clicks don't end the selection, so the select() signal is never emited.

Debugging the code I found that the widgetMouseReleaseEvent() is never called. widgetMousePressEvent() is called everytime the mouse is pressed.
So, I guess that's why my rect selection is never ending.

Any Ideas?

I've checked that mouse events come to my QGraphicsItem successfully.

I reimplemented a picker of my own, to define my own Text Tracker.

Qt Code:
  1. class TFPicker : public QwtPlotPicker
  2. {
  3. public:
  4. TFPicker(QwtPlotCanvas *canvas) : QwtPlotPicker(canvas) {}
  5. QwtText trackerText(const QPoint &pos) const;
  6. protected:
  7. void widgetMouseReleaseEvent(QMouseEvent *e);
  8. void widgetMousePressEvent(QMouseEvent *e);
  9. };
To copy to clipboard, switch view to plain text mode