mirror of
https://github.com/doomemacs/doomemacs.git
synced 2026-03-08 15:50:40 -07:00
fix(evil): clean isearch overlays after ex-search navigation
`evil-ex-search' (used by `n'/`N') calls `isearch-range-invisible' which temporarily opens fold overlays to check visibility, but never calls `isearch-clean-overlays' to restore them. This corrupts org-fold overlay state, making subtrees permanently unfoldable with TAB. The initial `/` search properly cleans up via `evil-ex-search-stop-session', but repeated `n'/`N' navigation skips this step. Add `:after' advice to call `isearch-clean-overlays'. Ref: emacs-evil/evil#1630 Fix: #8625 Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
parent
f1e8b97bad
commit
9019a16887
1 changed files with 9 additions and 0 deletions
|
|
@ -67,6 +67,15 @@ directives. By default, this only recognizes C directives.")
|
|||
:config
|
||||
(evil-select-search-module 'evil-search-module 'evil-search)
|
||||
|
||||
;; HACK: `evil-ex-search' (used by `n'/`N') calls `isearch-range-invisible'
|
||||
;; which temporarily opens fold overlays, but never calls
|
||||
;; `isearch-clean-overlays' to restore them. This corrupts org-fold
|
||||
;; overlay state, making subtrees permanently unfoldable with TAB.
|
||||
;; See emacs-evil/evil#1630, doomemacs/doomemacs#8625.
|
||||
(defadvice! +evil--clean-isearch-overlays-a (&rest _)
|
||||
:after #'evil-ex-search
|
||||
(isearch-clean-overlays))
|
||||
|
||||
;; PERF: Stop copying the selection to the clipboard each time the cursor
|
||||
;; moves in visual mode. Why? Because on most non-X systems (and in terminals
|
||||
;; with clipboard plugins like xclip.el active), Emacs will spin up a new
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue