commit 8c39b9a4ecd880a50b959c1f689421b0399d7424 parent a8e4705e5483c2ccd149f41a56db4530a046bf6b Author: andsy10 <andsy1016@gmail.com> Date: Thu, 8 Oct 2026 01:08:23 +0800 Add kmacro-x Diffstat:
| M | lisp/init-edit.el | | | 12 | ++++++++++++ |
| M | lisp/init-kbd.el | | | 5 | +++++ |
2 files changed, 17 insertions(+), 0 deletions(-)
diff --git a/lisp/init-edit.el b/lisp/init-edit.el @@ -46,6 +46,18 @@ undo-strong-limit 100663296 undo-outer-limit 1006632960)) +;; kmacro enhancement (and multiple cursors) +(use-package kmacro-x + :straight + (kmacro-x :fork (:type git :repo "https://git.trogloxene.org/kmacro-x.git")) + :delight + (kmacro-x-atomic-undo-mode nil) + :hook + (after-init . kmacro-x-atomic-undo-mode) + (kmacro-x-mc-mode . kmacro-x-mc-atomic-undo-mode) + :config + (setq kmacro-x-mc-live-preview t)) + ;; expand-region (use-package expand-region :commands diff --git a/lisp/init-kbd.el b/lisp/init-kbd.el @@ -42,6 +42,11 @@ "C-c e" #'er/expand-region "M-z" #'avy-zap-to-char-dwim "M-Z" #'avy-zap-up-to-char-dwim + "C-<" #'kmacro-x-mc-mark-previous + "C->" #'kmacro-x-mc-mark-next + "C-M-<" #'kmacro-x-mc-unmark-previous + "C-M->" #'kmacro-x-mc-unmark-next + "C-S-<mouse-1>" #'kmacro-x-mc-mark-at-click ;; undo "C-/" #'undo-fu-only-undo