Does not make org-mode folds with matches visible
uggedal opened this issue · 7 comments
isearch
opens invisible org-mode sections if there are matches within them. ctrlf
does not do this. It finds the matches and you can cycle between them, but they are invisible if the section is invisible.
isearch
seems to handle it here: https://github.com/emacs-mirror/emacs/blob/d0e2a341dd9a9a365fd311748df024ecb25b70ec/lisp/isearch.el#L2947
swiper
handles it here: https://github.com/abo-abo/swiper/blob/4b4f7c8c37314be92d9e4971687e987fb7b3ef3e/swiper.el#L877
Good point, that's an excellent opportunity for improvement. Thanks for the pointers.
Let me know if this works for your use case. It seems to work for outline-minor-mode
at least, and in principle should extend to anything else supported by Isearch.
This unfortunately does not seem to work for hideshow. That is, if I have a block hidden by hs-hide-block
, I cannot search for terms within that block. Could we re-open this? If not, I can give a repro.
I also seem to be able to trigger an error in the post-command-hook if blocks are hidden and I try to search through the buffer:
Error in post-command-hook (ctrlf--minibuffer-post-command-hook): (wrong-number-of-arguments (2 . 2) 1)
Error in minibuffer-exit-hook (ctrlf--minibuffer-exit-hook): (wrong-number-of-arguments (2 . 2) 1)
Quit
Why don't you open a new issue for this bug and I can take a look?