[Haskell-cafe] ANN: Robot - Simulate keyboard and mouse events under X11

Niklas Hambüchen mail at nh2.me
Sun May 12 10:46:07 CEST 2013


Yes, that works now.

I have another problem though: I move the cursor at high resolution 
(128 Hz) and it seems that when robot issues a command to X, it 
disables (keyboard) state so far. This means that it's impossible for 
me to Ctrl-C my program: Only "c" is sent all the time, me pressing 
Ctrl seems to be reset with the next robot event.

On Sun 12 May 2013 16:02:06 SGT, Chris Wong wrote:
> On Thu, May 9, 2013 at 1:36 PM, Chris Wong
> <chrisyco+haskell-cafe at gmail.com> wrote:
>> On Thu, May 9, 2013 at 4:47 AM, Niklas Hambüchen <mail at nh2.me> wrote:
>>> Hi,
>>>
>>> I just started using your library to move my cursor.
>>>
>>> Is it possible that it ignores negative values in moveBy?
>>>
>>> In other words, I can only move the cursor into one direction.
>>
>> I did some research, and traced this to a bug in an old (1.6) version
>> of xcb-proto [1]. The coordinates were declared incorrectly as Word16,
>> instead of Int16 as they should have been. It's been fixed in
>> xcb-proto since 1.7.
>
> Okay, I've released a new version of Robot (1.0.1.1), that should fix
> this bug. Niklas: can you try it out please?
>
> Also, it turns out taking a screenshot is much easier than I thought.
> A single call to getImage returns a list of bytes, which happens to
> match exactly the internal structure used by JuicyPixels. I'll look
> deeper into this when I get the time.
>
> Chris
>
> --
> Chris Wong, fixpoint conjurer
>   e: lambda.fairy at gmail.com
>   w: http://lfairy.github.io/
>
> _______________________________________________
> Haskell-Cafe mailing list
> Haskell-Cafe at haskell.org
> http://www.haskell.org/mailman/listinfo/haskell-cafe



More information about the Haskell-Cafe mailing list