Use `org-flag-subtree' instead of `outline-hide-subtree'
* lisp/org-agenda.el (org-agenda-show-1): * lisp/org-archive.el (org-archive-to-archive-sibling): * lisp/org-crypt.el (org-encrypt-entry): * lisp/org-feed.el (org-feed-update): * lisp/org.el (org-set-visibility-according-to-property): (org-move-subtree-down): (org-paste-subtree): (org-yank-generic): * testing/lisp/test-org-inlinetask.el (test-org-inlinetask/folding-directly-consecutive-tasks/1): Use `org-flag-subtree' instead of `outline-hide-subtree'. `outline-hide-subtree' leaves overlays on top of white spaces, particularly at the end of the buffer. `org-flag-subtree' does not.
This commit is contained in:
parent
cd1af27a2a
commit
12f93c112b
|
@ -8766,7 +8766,7 @@ if it was hidden in the outline."
|
|||
(set-window-start (selected-window) (point-at-bol))
|
||||
(cond
|
||||
((= more 0)
|
||||
(outline-hide-subtree)
|
||||
(org-flag-subtree t)
|
||||
(save-excursion
|
||||
(org-back-to-heading)
|
||||
(run-hook-with-args 'org-cycle-hook 'folded))
|
||||
|
|
|
@ -450,7 +450,7 @@ Archiving time is retained in the ARCHIVE_TIME node property."
|
|||
(format-time-string
|
||||
(substring (cdr org-time-stamp-formats) 1 -1)))
|
||||
(outline-up-heading 1 t)
|
||||
(outline-hide-subtree)
|
||||
(org-flag-subtree t)
|
||||
(org-cycle-show-empty-lines 'folded)
|
||||
(when org-provide-todo-statistics
|
||||
;; Update TODO statistics of parent.
|
||||
|
|
|
@ -190,7 +190,7 @@ See `org-crypt-disable-auto-save'."
|
|||
(error (insert contents) (error (nth 1 err)))))
|
||||
(when folded
|
||||
(goto-char start-heading)
|
||||
(outline-hide-subtree))
|
||||
(org-flag-subtree t))
|
||||
nil)))))
|
||||
|
||||
(defun org-decrypt-entry ()
|
||||
|
|
|
@ -412,7 +412,7 @@ it can be a list structured like an entry in `org-feed-alist'."
|
|||
|
||||
;; Normalize the visibility of the inbox tree
|
||||
(goto-char inbox-pos)
|
||||
(outline-hide-subtree)
|
||||
(org-flag-subtree t)
|
||||
(org-show-children)
|
||||
|
||||
;; Hooks and messages
|
||||
|
|
10
lisp/org.el
10
lisp/org.el
|
@ -6480,11 +6480,11 @@ With a numeric prefix, show all headlines up to that level."
|
|||
(if (not (org-at-property-p)) (outline-next-heading)
|
||||
(save-excursion
|
||||
(org-back-to-heading t)
|
||||
(outline-hide-subtree)
|
||||
(org-flag-subtree t)
|
||||
(org-reveal)
|
||||
(pcase state
|
||||
("folded"
|
||||
(outline-hide-subtree))
|
||||
(org-flag-subtree t))
|
||||
("children"
|
||||
(org-show-hidden-entry)
|
||||
(org-show-children))
|
||||
|
@ -7490,7 +7490,7 @@ case."
|
|||
(org-skip-whitespace)
|
||||
(move-marker ins-point nil)
|
||||
(if folded
|
||||
(outline-hide-subtree)
|
||||
(org-flag-subtree t)
|
||||
(org-show-entry)
|
||||
(org-show-children))
|
||||
(org-clean-visibility-after-subtree-move)
|
||||
|
@ -7656,7 +7656,7 @@ When REMOVE is non-nil, remove the subtree from the clipboard."
|
|||
(equal org-subtree-clip (current-kill 0))
|
||||
org-subtree-clip-folded)
|
||||
;; The tree was folded before it was killed/copied
|
||||
(outline-hide-subtree))
|
||||
(org-flag-subtree t))
|
||||
(when for-yank (goto-char newend))
|
||||
(when remove (pop kill-ring)))))
|
||||
|
||||
|
@ -20365,7 +20365,7 @@ interactive command with similar behavior."
|
|||
(or (looking-at org-outline-regexp)
|
||||
(re-search-forward org-outline-regexp-bol end t))
|
||||
(while (and (< (point) end) (looking-at org-outline-regexp))
|
||||
(outline-hide-subtree)
|
||||
(org-flag-subtree t)
|
||||
(org-cycle-show-empty-lines 'folded)
|
||||
(condition-case nil
|
||||
(outline-forward-same-level 1)
|
||||
|
|
|
@ -148,7 +148,7 @@ p4
|
|||
*************** END
|
||||
|
||||
"
|
||||
(outline-hide-subtree)
|
||||
(org-flag-subtree t)
|
||||
(org-cycle)
|
||||
(and
|
||||
(not (invisible-p (1- (search-forward "p1"))))
|
||||
|
|
Loading…
Reference in New Issue