Make TAB respect org-cycle-separator-lines #800

outline-toggle-children and org-cycle-hide-drawers didn't respect
org-cycle-separator-lines.
This commit is contained in:
Henrik Lissner 2018-08-13 15:21:03 +02:00
parent 90fa4a8c37
commit 5663778e36
No known key found for this signature in database
GPG key ID: 5F6C0EA160557395

View file

@ -398,15 +398,16 @@ with `org-cycle')."
(unless (eq this-command 'org-shifttab)
(save-excursion
(org-beginning-of-line)
(when (and (org-at-heading-p)
(or org-cycle-open-archived-trees
(not (member org-archive-tag (org-get-tags))))
(or (not arg)
(outline-invisible-p (line-end-position))))
(outline-toggle-children)
(unless (outline-invisible-p (line-end-position))
(org-cycle-hide-drawers 'subtree))
t))))
(let (invisible-p)
(when (and (org-at-heading-p)
(or org-cycle-open-archived-trees
(not (member org-archive-tag (org-get-tags))))
(or (not arg)
(setq invisible-p (outline-invisible-p (line-end-position)))))
(unless invisible-p
(setq org-cycle-subtree-status 'subtree))
(org-cycle-internal-local)
t)))))
;;;###autoload
(defun +org|remove-occur-highlights ()