From 5c3c492fd8ba6c29b0ac864d7238acbe9bdd9958 Mon Sep 17 00:00:00 2001 From: Alexander Rosenberg Date: Mon, 9 Dec 2024 23:09:36 -0800 Subject: [PATCH] Undo kkp tab and return decoding --- init.el | 28 +++++++++++++++------------- 1 file changed, 15 insertions(+), 13 deletions(-) diff --git a/init.el b/init.el index aa681a5..d567253 100644 --- a/init.el +++ b/init.el @@ -381,18 +381,18 @@ directory. Otherwise, run `find-file' on that file." :defer nil :config (global-kkp-mode 1) - (defun my/-kkp-after-terminal-setup () - ;; Make tab and backtab work properly - (define-key input-decode-map [(control ?i)] [tab]) - (define-key input-decode-map [(control ?I)] [backtab]) - (define-key input-decode-map [(control ?m)] [return])) - (defun my/-kkp-after-terminal-teardown (term) - (with-selected-frame (car (frames-on-display-list term)) - (define-key input-decode-map [(control ?i)] nil t) - (define-key input-decode-map [(control ?I)] nil t) - (define-key input-decode-map [(control ?m)] nil t))) - (advice-add 'kkp--terminal-setup :after 'my/-kkp-after-terminal-setup) - (advice-add 'kkp--terminal-teardown :after 'my/-kkp-after-terminal-teardown) + ;; (defun my/-kkp-after-terminal-setup () + ;; ;; Make tab and backtab work properly + ;; (define-key input-decode-map [(control ?i)] [tab]) + ;; (define-key input-decode-map [(control ?I)] [backtab]) + ;; (define-key input-decode-map [(control ?m)] [return])) + ;; (defun my/-kkp-after-terminal-teardown (term) + ;; (with-selected-frame (car (frames-on-display-list term)) + ;; (define-key input-decode-map [(control ?i)] nil t) + ;; (define-key input-decode-map [(control ?I)] nil t) + ;; (define-key input-decode-map [(control ?m)] nil t))) + ;; (advice-add 'kkp--terminal-setup :after 'my/-kkp-after-terminal-setup) + ;; (advice-add 'kkp--terminal-teardown :after 'my/-kkp-after-terminal-teardown) (defun my/quoted-insert (arg) "Insert the next character using read-key, not read-char." (interactive "*p") @@ -632,7 +632,9 @@ in the region and indents once)." 'lisp-dedent-adjust-parens) (evil-define-key '(normal visual) adjust-parens-mode-map (kbd "") #'my/lisp-indent-adjust-parens - (kbd "") #'my/lisp-dedent-adjust-parens)) + (kbd "") #'my/lisp-dedent-adjust-parens + (kbd "C-c C-i") #'my/lisp-indent-adjust-parens + (kbd "C-c S-") #'my/lisp-dedent-adjust-parens)) ;; for when the files are just too large (use-package vlf