Ignoring keyboard events in QwtPlotPicker
Sorry if this question was already asked, I couldn't find it searching.
I have the following plot picker initialized for my QwtPlot:
I see that the default behavior is that the keyboard events (mainly the direction keys) are handled by the plot picker to move around the cross. How can I ignore these events so that they are not caught by the plot / picker?
Re: Ignoring keyboard events in QwtPlotPicker
QwtPicker is derived from QwtEventPattern, where all mouse and keyboard assignments are defined, that the picker handles.
Uwe
Re: Ignoring keyboard events in QwtPlotPicker
Thanks for your reply Uwe. I see the inheritance and I see some samples that define mouse keys. But what I still can't understand is how to set my object to ignore the up and down keys.
I'm looking at the documentation at http://qwt.sourceforge.net/class_qwt_event_pattern.html but I don't see the right way to go.
Re: Ignoring keyboard events in QwtPlotPicker
Simply change the key code, that is connected to the KeyUp/KeyDown events. 0 would disable the functionality completely ( as it is no valid key code ).
Check QKeyEvent for the meaning of the key/button combinations you could use to redefine your picker.
Uwe
Re: Ignoring keyboard events in QwtPlotPicker
Thank you! That was exactly what I was looking for.