[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

Re: [pygame] Sending key-pressing input to a window



On Sun, Aug 02, 2009 at 06:22:24PM -0700, Ian Mallett wrote:
>    Hi,
> 
>    I want to make a PyGame application that will send key press data to the
>    currently active window.  So, if I ran the program, and then switched to
>    another window, the program should send data to that window just as if I
>    had typed in that window.  Can it be done with PyGame?  Thanks,
> 
>    Ian

pygame cannot do that.

I have never done this before. You might want to look at the pyhook 
and/or SendKeys packages, althouth I believe those are both 
windows-only. There is probably not any cross-platform python library to 
do this.

---
James Paige