summaryrefslogtreecommitdiff
path: root/lisp/isearch.el
diff options
context:
space:
mode:
authorJuri Linkov <juri@linkov.net>2021-12-04 22:04:37 +0200
committerJuri Linkov <juri@linkov.net>2021-12-04 22:04:37 +0200
commitf247fa5d5ce7cb34f23c979c17b14c5713eb5490 (patch)
tree4be9f106245141838833bcc06d579ba8d57642dd /lisp/isearch.el
parent08782d58db6437b593c0469372dc936f9d8a62da (diff)
downloademacs-f247fa5d5ce7cb34f23c979c17b14c5713eb5490.tar.gz
* lisp/isearch.el (isearch-delete-char): Reopen hidden overlays (bug#52248).
(isearch-filter-visible): Move text-property-not-all higher to not call isearch-range-invisible on inhibit-isearch text. Remove min/max since arguments are always in the right order.
Diffstat (limited to 'lisp/isearch.el')
-rw-r--r--lisp/isearch.el12
1 files changed, 8 insertions, 4 deletions
diff --git a/lisp/isearch.el b/lisp/isearch.el
index fcb7d646c66..8815cb4f2d6 100644
--- a/lisp/isearch.el
+++ b/lisp/isearch.el
@@ -2504,6 +2504,11 @@ If no input items have been entered yet, just beep."
(if (null (cdr isearch-cmds))
(ding)
(isearch-pop-state))
+ ;; When going back to the hidden match, reopen it.
+ (when (and (eq search-invisible 'open) isearch-hide-immediately
+ isearch-other-end)
+ (isearch-range-invisible (min (point) isearch-other-end)
+ (max (point) isearch-other-end)))
(isearch-update))
(defun isearch-del-char (&optional arg)
@@ -3787,10 +3792,9 @@ Isearch, at least partially, as determined by `isearch-range-invisible'.
If `search-invisible' is t, which allows Isearch matches inside
invisible text, this function will always return non-nil, regardless
of what `isearch-range-invisible' says."
- (and (or (eq search-invisible t)
- (not (isearch-range-invisible beg end)))
- (not (text-property-not-all (min beg end) (max beg end)
- 'inhibit-isearch nil))))
+ (and (not (text-property-not-all beg end 'inhibit-isearch nil))
+ (or (eq search-invisible t)
+ (not (isearch-range-invisible beg end)))))
;; General utilities