org-fold-core-region: Fix removing non-fold overlays
* lisp/org-fold-core.el (org-fold-core-region): Do not clear all the overlays in region when unfolding and when SPEC-OR-ALIAS is nil. Reported-by: Bruno Barbier <brubar.cs@gmail.com> Link: https://orgmode.org/list/65f4a408.df0a0220.5debf.2c65@mx.google.com
This commit is contained in:
parent
9f4064e68e
commit
712ef988c3
|
@ -1071,8 +1071,9 @@ If SPEC-OR-ALIAS is omitted and FLAG is nil, unfold everything in the region."
|
|||
(when org-fold-core--isearch-active
|
||||
(cl-pushnew ov org-fold-core--isearch-overlays)))))
|
||||
(overlays-in from to))
|
||||
(remove-overlays from to 'org-invisible spec)
|
||||
(remove-overlays from to 'invisible spec)))
|
||||
(when spec
|
||||
(remove-overlays from to 'org-invisible spec)
|
||||
(remove-overlays from to 'invisible spec))))
|
||||
(if flag
|
||||
(if (not spec)
|
||||
(error "Calling `org-fold-core-region' with missing SPEC")
|
||||
|
|
Loading…
Reference in New Issue