5

I need to remap IJKL to the arrow keys while alt is down.

Also, modifiers should still work ie: Shift+Ctrl+Alt+L should map to Shift+Ctrl+RightArrow

I was able to get this working using xbindkeys + xvkbd, but it wasn't working well because it looks like I lose focus every time it sends input, and it didn't work at all in the terminal.

3
  • Heya, did you ever figure out a good way to do this kind of thing?
    – Owen_AR
    Jun 6, 2014 at 17:55
  • xbindkeys + xvkbd is still the best solution I've found, so no /:
    – Farzher
    Jun 6, 2014 at 20:03
  • 2
    Possible duplicate of How to simulate keyboard input?
    – Elder Geek
    Oct 9, 2017 at 18:21

1 Answer 1

2

There are a several more technical ways to do this that I have seen in other SE posts, but one of the easiest ways would be to install AutoKey. It is a full featured keyboard macro processor and it's easy to define simple macros for such a task.

AutoKey does a whole lot of other things easily and, if you know Python which is used as its macro language, you can get a keypress or phrase to do almost anything your system is capable of. And, it works with just about any program because, by default, its output appears to be coming directly from the keyboard exactly the same as if you were typing it.

Try it and see if it works for you. We don't currently have any developers on the project, but the support list is active and many people are successfully using it.

I just reread your question more carefully and the bit about the other modifier keys still working makes it more complicated because you would probably have to code a separate macro for each modifier combination with each key (i, j, k, l), but I think it would still work.

If you decide to try it, make sure you have the latest version (0.90.4) as many distros provide older versions that don't work as well.

4
  • 1
    I tried AutoKey before, but it wasn't consuming input, remapping Alt + I to right arrow key worked, but it still executed Alt + I, which sometimes selects an item from the application menu. Do you know if this is still an issue? (Maybe I was using an old version or did something wrong)
    – Farzher
    Nov 28, 2013 at 20:42
  • Don't know. Was it version 0.90.4? If you post your question on our forum/list https://groups.google.com/forum/#!forum/autokey-users (preferably including a trace generated by running autokey-gtk -l from a console), maybe someone will be able to solve the problem.
    – Joe
    Nov 30, 2013 at 7:30
  • So, I don't have that application menu issue with autokey anymore. But it does have the same issue as xbindkeys of losing window focus quickly when it executes, and the performance of it is so bad it lags my computer. But it does work in the terminal. If I can figure out the performance issue, that's not too bad.
    – Farzher
    Dec 1, 2013 at 20:24
  • Again, you may want to post to our list. I have had a number of problems using AutoKey, but performance has never been one of them. I'm not sure what you mean by losing window focus, but if it's what I think it is, it may be a problem generic to desktop environments when any gui program uses another gui one to get things done. I have a problem that sounds similar with yad (zenity fork) pop-up dialogs issued from bash scripts.
    – Joe
    Dec 2, 2013 at 22:21

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .