adding keyhooks for keyboard events in pyrecs