I\'m trying to write a simple macro recorder in Python for OSX - something which can capture mouse and key events as the script runs in the background and replay them. I can use
Here's a solution without using curses:
curses
http://docs.python.org/faq/library.html#how-do-i-get-a-single-keypress-at-a-time
This question was asked some time back here - Python cross-platform listening for keypresses?
You might find the sample code there helpful!