Hi,
I'm a newbie to Linux and to Perl. I have half of a degree so far in software engineering and have spent a few years helping out at a small business, learning the basics of IT support. I have an input problem related to key presses executing custom code -- like a numpad key moving the mouse instead of sending a character message.
I already have a script that:
imports Win32::GuiTest
declares configuration variables
loops
{
if statement that checks for ( IsKeyPressed(numpad virtual key) ) then SendMouseMoveRel(arguments)
}
This produces the first part of the requirement -- the mouse does move with the press of a key. However, the key still sends a message to the OS. Does Perl or a module within Perl possess a function that can specifically block or intercept a key press? I understand that a hook may be required, but I'd rather try something higher level first.
I'm developing this for both Microsoft Windows 7 and 10 and on Linux distros including Unity. I'm intending this for use both within work and home environments, at a small business and on my own desktop and laptops.
Regards,
beyond.wudge
Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
Read Where should I post X? if you're not absolutely sure you're posting in the right place.
Please read these before you post! —
Posts may use any of the Perl Monks Approved HTML tags:
- a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
| |
For: |
|
Use: |
| & | | & |
| < | | < |
| > | | > |
| [ | | [ |
| ] | | ] |
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.