intercept keystrokes, prevent them from reaching X11
Linux - SoftwareThis forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Distribution: Debian Gnu/Linux Lenny on AMD64x2 (32-bit mode), an AMD Sempron 64 laptop, debian, 32bit
Posts: 101
Rep:
intercept keystrokes, prevent them from reaching X11
Greetings!
I ordered a Logitech G15. It's in the mail, and while it's on its way, I'm pondering the various (geeky) things I could do with it.
What I would like to do is set it up so that my instant messenging happens on the LCD panel. I'm perfectly willing to write the code to do this part.
The problem is this: when running an X server (as we all like to do), the X server generally gets all the keyboard input. I would like to divert the keyboard input when I press a key combination (and un-divert it when I press the combination again) to an arbitrary application.
Does anyone know of a way to do this (aside from hacking xfree86)?
That will help if I ever write a Java-based GUI program .
The problem is, while this can detect keys within an application, it can't stop keys from being sent to other applications, nor can it detect keys that weren't sent directly to it.
I ordered a Logitech G15. It's in the mail, and while it's on its way, I'm pondering the various (geeky) things I could do with it.
What I would like to do is set it up so that my instant messenging happens on the LCD panel. I'm perfectly willing to write the code to do this part.
The problem is this: when running an X server (as we all like to do), the X server generally gets all the keyboard input. I would like to divert the keyboard input when I press a key combination (and un-divert it when I press the combination again) to an arbitrary application.
Does anyone know of a way to do this (aside from hacking xfree86)?
I dont know but in the new distros there is SCIM, which is key input for all kinds of languages, which may have done the hacking See whether poking about with this gives you the result you need.
Distribution: Debian Gnu/Linux Lenny on AMD64x2 (32-bit mode), an AMD Sempron 64 laptop, debian, 32bit
Posts: 101
Original Poster
Rep:
Quote:
Originally Posted by resetreset
I dont know but in the new distros there is SCIM, which is key input for all kinds of languages, which may have done the hacking See whether poking about with this gives you the result you need.
Looking at it for a quick moment, it looks very promising. I'll have to look with a little more detail, but I'm wondering if (since it has keystrokes for different input systems) it would work to just write a custom "input system" that feeds the keys to my application.
Thanks!
Last edited by jakykong; 07-14-2008 at 02:28 PM.
Reason: typo
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.