From fc25eaa44c74e03eda7158466272011295c47404 Mon Sep 17 00:00:00 2001 From: Sean Whitton Date: Fri, 18 Jun 2021 20:55:40 -0700 Subject: expand comment on M-Z binding --- .emacs.d/init-spw.el | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/.emacs.d/init-spw.el b/.emacs.d/init-spw.el index 168ca436..13cadc00 100644 --- a/.emacs.d/init-spw.el +++ b/.emacs.d/init-spw.el @@ -480,7 +480,20 @@ I use by default)." ;; somewhere) (global-set-key "\C-x\C-d" #'kill-region) -;; also make `zap-up-to-char' available +;; Is a binding for `zap-up-to-char' needed in addition to one for +;; `zap-to-char'? If you don't need to insert any text before the target +;; char, then M-z CHAR CHAR is equivalent to using `zap-up-to-char' with CHAR, +;; and is easy to type. If you do need to insert, you can just M-z CHAR, type +;; or yank, and then type CHAR again to conclude. By contrast, replacing use +;; of `zap-to-char' with `zap-up-to-char' is not so easy, as you might need to +;; switch from typing M-z to typing C-d, for example. +;; +;; At the very least this demonstrates that `zap-to-char' more deserves to be +;; on an easy-to-strike key than does `zap-up-to-char'. So for now, make the +;; other command available on a less valuable key. +;; +;; Hmm, might be good to add `paredit-zap-to-char' which doesn't actually +;; delete some delimiters. (global-set-key "\M-Z" #'zap-up-to-char) ;; We cannot reliably distinguish from so I -- cgit v1.2.3