aboutsummaryrefslogtreecommitdiff
path: root/evil-search.el
diff options
context:
space:
mode:
authorFrank Fischer <frank-fischer@shadow-soft.de>2015-08-18 22:13:17 +0200
committerFrank Fischer <frank-fischer@shadow-soft.de>2015-08-18 22:13:17 +0200
commit44f51cec1188eb0aad5108eb6b1c32744f1278a7 (patch)
tree7486e8fcd2eac29fed3f34606020ed899fd994b3 /evil-search.el
parent50cb525290bb199afd70bdfabf6bc117d1397acb (diff)
add persistent highlight option for interactive search (fix #562)
Diffstat (limited to 'evil-search.el')
-rw-r--r--evil-search.el4
1 files changed, 3 insertions, 1 deletions
diff --git a/evil-search.el b/evil-search.el
index 37455b6..4f23c78 100644
--- a/evil-search.el
+++ b/evil-search.el
@@ -1085,7 +1085,9 @@ current search result."
(setq evil-ex-search-match-beg (match-beginning 0)
evil-ex-search-match-end (match-end 0))
(evil-ex-search-goto-offset offset)
- (evil-push-search-history search-string (eq direction 'forward)))
+ (evil-push-search-history search-string (eq direction 'forward))
+ (unless evil-ex-search-persistent-highlight
+ (evil-ex-delete-hl 'evil-ex-search)))
(t
(goto-char evil-ex-search-start-point)
(evil-ex-delete-hl 'evil-ex-search)