|
From: | Michael Heerdegen |
Subject: | bug#55234: 28.1; replace-string in rectangle regio |
Date: | Sat, 04 Jun 2022 15:20:45 +0200 |
User-agent: | Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux) |
Juri Linkov <juri@linkov.net> writes: > (defun rectangle--extract-region (orig &optional delete) > (cond > ((not rectangle-mark-mode) > (funcall orig delete)) > ((eq delete 'bounds) > - (extract-rectangle-bounds (region-beginning) (region-end))) > + (extract-rectangle-bounds > + ;; Avoid recursive calls > + (let (rectangle-mark-mode) (region-beginning)) > + (let (rectangle-mark-mode) (region-end)))) > (t > (let* ((strs (funcall (if delete > #'delete-extract-rectangle > #'extract-rectangle) > - (region-beginning) (region-end))) > + ;; Avoid recursive calls > + (let (rectangle-mark-mode) (region-beginning)) > + (let (rectangle-mark-mode) (region-end)))) > (str (mapconcat #'identity strs "\n"))) > (when (eq last-command 'kill-region) > ;; Try to prevent kill-region from appending this to some Is it intended to - at the end - call the original functions here? TIA, Michael.
[Prev in Thread] | Current Thread | [Next in Thread] |