Hi, I'm working on GUI apps using matplotlib's class library
> with both WXAgg and TkAgg backends, and am having a
> love/hate relationship with the FigureCanvase.mpl_connect()
> methods. These return a platform-neutral, matplotlib-aware
> Event, which is great for dealing with the Plot canvas, but
> swallow the native GUI event, complicating working with the
> GUI toolkit.
Hmm, I thought the point of doing the Skip call
def _onKeyDown(self, evt):
"""Capture key press."""
key = self._get_key(evt)
evt.Skip()
FigureCanvasBase.key_press_event(self, key)
would be to prevent the event from being swallowed. So you should be
able to get those events if you've made a second connection, right?
If so, what you are arguing for is the ability to get the GUI event
within the mpl event because this is more convenient than making two
connections. Is that right?
You can always make the change with guiEvent=None in the
__init__function so other backends can add it when/if they want it.
It looks like a good idea to me to add it across backends, though.
JDH