matplotlib/matplotlib — pull request #837 by pelson (2012-04-17 06:56:00+00:00)
Title: Make qt4 backend more consistent with tk and gtk.

This pull request fixes the following in the qt4 backend:
* #299 (arrow keys not triggering a key press event)
* Focus now set properly without the user needing to click on the canvas to activate keyboard events
* Fixed a consistency such that unmapped keys still come through as None (as tk and gtk do)

Code to test these (by hand):

```
import matplotlib

matplotlib.use('qt4agg')
#matplotlib.use('tkagg')
#matplotlib.use('gtkagg')

import matplotlib.pyplot as plt

plt.plot(range(10))

def onclick(event):
print event.key

cid = plt.gcf().canvas.mpl_connect('key_press_event', onclick)

plt.show()
```

I've based this off master, but it might be that we would prefer to put this on the 1.1.x line?