Move global and built-in mode keybindings to Emacs section, cleanup
This commit is contained in:
parent
73d9959a52
commit
2f19538913
75
init.org
75
init.org
|
@ -44,51 +44,6 @@ At first I decided to remap all Emacs, Boon, and Hydra bindings, but it turned o
|
|||
#+BEGIN_SRC emacs-lisp
|
||||
(use-package general
|
||||
:commands (general-auto-unbind-keys general-def general-define-key))
|
||||
|
||||
(general-auto-unbind-keys)
|
||||
;; Most if not all of these are translations of their earlier QWERTY bindings.
|
||||
(general-def
|
||||
"M-h" 'default-indent-new-line ;; see also org-mode
|
||||
"M-'" 'fill-paragraph
|
||||
"C-j" 'ctl-x-map
|
||||
"M-n M-n" 'font-lock-fontify-block
|
||||
;; basic Modifier-based editing commands
|
||||
;; "C-d" 'backward-delete-char ;; unnecessary - QWERTY C-h is merely next to your index finger, but Dvorak C-h is directly under it
|
||||
"C-," 'backward-kill-word
|
||||
|
||||
;; ;; Emacs-like
|
||||
"M-e" 'kill-word
|
||||
"C-e" 'delete-char
|
||||
"M-u" 'forward-word
|
||||
"C-." 'end-of-line
|
||||
"M-q" 'execute-extended-command
|
||||
;; "C-x" 'forward-char
|
||||
|
||||
;; ;; Boon-like
|
||||
;; "M-h" 'forward-word
|
||||
;; "M-s" 'forward-word
|
||||
"C-n" 'forward-char
|
||||
"C-t" 'backward-char)
|
||||
(bind-keys
|
||||
("C-h" . backward-delete-char) ;; see also ivy, company
|
||||
:map text-mode-map
|
||||
;; Boon already binds xref-find-definitions to f
|
||||
;; see also latex-mode
|
||||
("M-." . forward-sentence)
|
||||
)
|
||||
;; ;; The old C-n/C-p/M-n/M-p were not the most comfortable to begin with, so I take this opportunity to bind them to something consistent with Boon
|
||||
(general-def minibuffer-local-map
|
||||
"C-c" 'previous-line
|
||||
"C-r" 'next-line
|
||||
"M-c" 'previous-history-element
|
||||
"M-r" 'next-history-element
|
||||
"M-p" 'previous-matching-history-element)
|
||||
(general-def read-expression-map ;; not sure if this works
|
||||
"C-c" 'previous-line
|
||||
"C-r" 'next-line
|
||||
"M-c" 'previous-history-element
|
||||
"M-r" 'next-history-element)
|
||||
(general-auto-unbind-keys t)
|
||||
#+END_SRC
|
||||
|
||||
* ido-mini
|
||||
|
@ -228,7 +183,35 @@ NAME is the name of the process and its buffer."
|
|||
(set-selection-coding-system 'utf-8)
|
||||
(prefer-coding-system 'utf-8)
|
||||
(setq-default undo-limit (* 80 1000))
|
||||
(load custom-file))
|
||||
(load custom-file)
|
||||
:bind
|
||||
("M-h" . default-indent-new-line) ;; QWERTY M-j ;; see also org-mode
|
||||
("M-'" . fill-paragraph) ;; QWERTY M-q
|
||||
("C-j" . ctl-x-map) ;; QWERTY C-c
|
||||
("M-n M-n" . font-lock-fontify-block)
|
||||
;; basic Modifier-based editing commands
|
||||
;; "C-d" 'backward-delete-char ;; unnecessary - QWERTY C-h is merely next to your index finger, but Dvorak C-h is directly under it
|
||||
("C-," . backward-kill-word) ;; QWERTY C-w
|
||||
;; ;; Emacs-like
|
||||
("M-e" . kill-word) ;; QWERTY M-d
|
||||
("C-e" . delete-char) ;; QWERTY C-d
|
||||
("M-u" . forward-word) ;; QWERTY M-f
|
||||
("C-." . end-of-line) ;; QWERTY C-e
|
||||
;; new
|
||||
("C-h" . backward-delete-char) ;; Dvorak C-h = QWERTY C-j (an improvement)
|
||||
(:map text-mode-map ("M-." . forward-sentence))
|
||||
;; ;; The old C-n/C-p/M-n/M-p were not the most comfortable to begin with, so I take this opportunity to bind them to something consistent with Boon
|
||||
(:map minibuffer-local-map
|
||||
("C-c" . previous-line)
|
||||
("C-r" . next-line)
|
||||
("M-c" . previous-history-element)
|
||||
("M-r" . next-history-element)
|
||||
("M-p" . previous-matching-history-element))
|
||||
(:map read-expression-map ;; not sure if this works
|
||||
("C-c" . previous-line)
|
||||
("C-r" . next-line)
|
||||
("M-c" . previous-history-element)
|
||||
("M-r" . next-history-element)))
|
||||
#+END_SRC
|
||||
|
||||
** package.el :package:
|
||||
|
|
Loading…
Reference in New Issue