Closed ghost closed 6 years ago
I guess the problem is that x
is already bound to something in the context where you try to use modalka
. So it's not a prefix key and thus you cannot get a sequential command.
Oh of course, I misunderstood how it works. I had set (modalka-define-kbd "x" "C-x")
earlier, which was blocking the x
key. Thanks!
On a related note - once we have...
(modalka-define-kbd "x" "C-x")
(modalka-define-kbd "e" "C-e")
...why can't we press x e
to get C-x C-e
? Instead, my config looks like -
(let ((keybind-re (rx-to-string '(group-n 1 (or (and bow (1+ (char graph)) eow)
(and (1+ (char graph))))))))
(mapc
(lambda (actual)
(let ((target (replace-regexp-in-string keybind-re "C-\\1" actual)))
(modalka-define-kbd actual target)))
'("`" "1" "2" "3" "4" "5" "6" "7" "8" "9" "0" "-" "="
"q" "w" "e" "r" "y" "u" "i" "o" "p" "[" "]" "\\"
"a" "s" "d" "f" "h" "j" "k" "l" ";" "'"
"z" "v" "b" "n" "m" "," "." "/"
"<" ">" "?"
"SPC"
"x =" "x -" "x e" "x s" "x d"
"x f" "x l" "x x" "x c" "x v" "x b"
"t w" "t e" "t l"
"c n" "c ," "c ." "c p"
"c c n" "c h u" "c h m")))
...21 definitions where 3 could have sufficed :disappointed:
I'm getting started with modalka, and I tried to run
(modalka-define-kbd "x o" "C-x o")
like i saw here but I got an error. Would you mind pointing me in the right direction? Thanks!