On Windows, but not on Linux, with Python 3.9.8 installed, key_press_events both work for the two examples from the MPL documentation: ...