in reply to Simple "showkey" in Perl

Do the codes depend on the keyboard or OS type? This snippet doesn't catch numlock/caps key for me. Does block ctrl+z. Thanks for throwing the alarm in :)


If the above content is missing any vital points or you feel that any of the information is misleading, incorrect or irrelevant, please feel free to downvote the post. At the same time, please reply to this node or /msg me to inform me as to what is wrong with the post, so that I may update the node to the best of my ability.

Replies are listed 'Best First'.
Re: Re: Simple "showkey" in Perl
by Mr_Person (Hermit) on Jul 06, 2003 at 04:29 UTC
    Unfortunately I don't have a full understanding of how the code works, just that it works for me :-) I'm guessing it depends on the operating system because the codes I used come from constants in the Linux kernel includes that don't change based on what kind of keyboard you have. The mode I set it to is MEDIUMRAW, you might try just plain RAW which is 0x00, or perhaps a different ReadMode.
Re: Re: Simple "showkey" in Perl
by kral (Monk) on Jul 09, 2003 at 10:36 UTC
    The management of the keyboard it's competence of the kernel.
    So, it's difficult (impossible, imho) to make a script OS independent.
    ----------
    kral
    (sorry for my english)