Greetings,

I have several qwtplotcurve attaced on a qwtplot, and it must responds mouseEvent: single left click on the curve to pick up the closest point of the curve, and double left click on curve to select the whole curve. Whatever selected, it should be hightlighted(change the color of the selected point or curve).

For two days, I searched on google, I got some useful information:

1. to track a point: use QwtPlotPicker and connect the selected signal with a slot
2. to find closest point: call QwtPlotCurve::closestPoint()

My questions are:

1. QwtPlotPicker is able to track all the points on canvas, but unable to track for a specific area(a rectangle, a line, a circle), only I just want to track the points on the curve, return me the object/pointer of the selected point.

2. If there is several curve on the plot, how could I tell the point from which curve(the curves may cross each other)

3. QwtPlotPicker can pick up a point, but how do I do to select a curve? (get the object/pointer of the curve)


Thank you in advance.


Tang Tao