Add Customize interface for simulation keys
* exwm-input.el (exwm-input-simulation-keys): New user option for setting simulation keys. (exwm-input--init): Initialize simulation keys from this variable. * exwm-input.el (exwm-input--simulation-prefix-keys) (exwm-input--on-KeyPress-line-mode) (exwm-input--update-simulation-prefix-keys) (exwm-input-set-simulation-keys, exwm-input-set-local-simulation-keys) (exwm-input-send-simulation-key): `exwm-input--simulation-keys' is now a hash table storing both simulation keys and prefix keys. (exwm-input--unset-simulation-keys): Clear the hash table. (exwm-input--exit): Use `exwm-input--unset-simulation-keys'. * exwm-core.el (exwm--kmacro-map, exwm-mode-menu): Adapt to the change of `exwm-input--simulation-keys'. * exwm-config.el (exwm-config-default): Update the example.
This commit is contained in:
parent
5c5729c0d4
commit
7d4c57a6ab
3 changed files with 118 additions and 55 deletions
|
|
@ -52,17 +52,17 @@
|
|||
(interactive (list (read-shell-command "$ ")))
|
||||
(start-process-shell-command command nil command)))
|
||||
;; Line-editing shortcuts
|
||||
(exwm-input-set-simulation-keys
|
||||
'(([?\C-b] . left)
|
||||
([?\C-f] . right)
|
||||
([?\C-p] . up)
|
||||
([?\C-n] . down)
|
||||
([?\C-a] . home)
|
||||
([?\C-e] . end)
|
||||
([?\M-v] . prior)
|
||||
([?\C-v] . next)
|
||||
([?\C-d] . delete)
|
||||
([?\C-k] . (S-end delete))))
|
||||
(setq exwm-input-simulation-keys
|
||||
'(([?\C-b] . [left])
|
||||
([?\C-f] . [right])
|
||||
([?\C-p] . [up])
|
||||
([?\C-n] . [down])
|
||||
([?\C-a] . [home])
|
||||
([?\C-e] . [end])
|
||||
([?\M-v] . [prior])
|
||||
([?\C-v] . [next])
|
||||
([?\C-d] . [delete])
|
||||
([?\C-k] . [S-end delete])))
|
||||
;; Enable EXWM
|
||||
(exwm-enable)
|
||||
;; Configure Ido
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue