Create visibility overlays properly

* org.el (org-set-outline-overlay-data): Use outline-flag-region to make a
region invisible.  This ensures all necessary actions, especially adding
isearch-open-invisible property, are applied.
This commit is contained in:
Milan Zamazal 2011-10-31 22:40:28 +01:00 committed by Bastien Guerry
parent 4f7e1fb108
commit a5ed98e452
1 changed files with 1 additions and 2 deletions

View File

@ -6626,8 +6626,7 @@ DATA should have been made by `org-outline-overlay-data'."
(widen)
(show-all)
(mapc (lambda (c)
(setq o (make-overlay (car c) (cdr c)))
(overlay-put o 'invisible 'outline))
(outline-flag-region (car c) (cdr c) t))
data)))))
;;; Folding of blocks