Hi,

On 19.11.2012 20:45, Manuel Kasser wrote:
> I'm experimenting with fake input and I'm failing epicly. I just do not
> get it to work.
> I tried to fake one press on spacebar, so I figured out what keycode
> this is (keycode 65, via "xev") and wrote the following code:
> 
>> root.fake_input("key_press", 65, mouse.coords()[1], mouse.coords()[2], 1)
>> root.fake_input("key_release", 65, mouse.coords()[1],
> mouse.coords()[2], 1)
> 
> I put them into a function an call this function via another keybind.
> But unfortunately nothing happens, I assume I'm just using the function
> the wrong way (with wrong parameters/parameter format).

Works for me. I wrote the following into a terminal, pressed "enter" and a new
space got entered".

$ echo 'root.fake_input("key_press", 65) root.fake_input("key_release", 65)' |
awesome-client

Cheers,
Uli
-- 
If you have to type the letters "A-E-S" into your source code, you're doing it
wrong.

-- 
To unsubscribe, send mail to [email protected].

Reply via email to