emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[nongnu] elpa/evil-goggles b611a140a2 162/225: Highlight the whole line


From: ELPA Syncer
Subject: [nongnu] elpa/evil-goggles b611a140a2 162/225: Highlight the whole line when pasting a whole line, not just the text
Date: Wed, 12 Jan 2022 08:59:05 -0500 (EST)

branch: elpa/evil-goggles
commit b611a140a24e4f6e1816d8ada4d801c04715e777
Author: Evgeni Kolev <evgenysw@gmail.com>
Commit: Evgeni Kolev <evgenysw@gmail.com>

    Highlight the whole line when pasting a whole line, not just the text
---
 evil-goggles.el | 8 +++-----
 1 file changed, 3 insertions(+), 5 deletions(-)

diff --git a/evil-goggles.el b/evil-goggles.el
index 553b67fe1b..9f3007cb31 100644
--- a/evil-goggles.el
+++ b/evil-goggles.el
@@ -541,12 +541,10 @@ COUNT REGISTER YANK-HANDLER are the arguments of the 
original function."
   (prog1
       (evil-goggles--funcall-preserve-interactive orig-fun count register 
yank-handler)
     (when (evil-normal-state-p)
-      (let* ((beg (save-excursion (evil-goto-mark ?\[) (point)))
-             (end (save-excursion (evil-goto-mark ?\]) (point)))
-             (is-beg-at-eol (save-excursion (goto-char beg) (eolp)))
-             (beg-corrected (if is-beg-at-eol (1+ beg) beg))
+      (let* ((beg (save-excursion (evil-goto-mark ?\[) (if (eolp) (1+ (point)) 
(point))))
+             (end (save-excursion (evil-goto-mark ?\]) (if (eolp) (1+ (point)) 
(point))))
              (use-block-hint (evil-goggles--evil-paste-block-p register 
yank-handler)))
-        (evil-goggles--show-hint beg-corrected end 'evil-goggles-paste-face 
use-block-hint)))))
+        (evil-goggles--show-hint beg end 'evil-goggles-paste-face 
use-block-hint)))))
 
 (defun evil-goggles--evil-paste-block-p (register yank-handler)
   "Return t if the paste was a vertical block.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]