Skip to content

Commit

Permalink
org-fold: Do not fold text inserted right after outline fold
Browse files Browse the repository at this point in the history
* lisp/org-fold.el (org-fold-initialize): Do not extend the fold when
text is inserted right after it.  This resembles folding overlay
behavior used in previous Org versions and in the 'overlays
`org-fold-core-style'.

Fixes https://orgmode.org/list/871quprrra.fsf@gmail.com
  • Loading branch information
yantar92 committed Jul 19, 2022
1 parent 3b7523a commit 39005dc
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions lisp/org-fold.el
Original file line number Diff line number Diff line change
Expand Up @@ -223,9 +223,11 @@ smart Make point visible, and do insertion/deletion if it is
(:isearch-open . t)
;; This is needed to make sure that inserting a
;; new planning line in folded heading is not
;; revealed.
;; revealed. Also, the below combination of :font-sticky and
;; :real-sticky conforms to the overlay properties in outline.el
;; and the older Org versions as in `outline-flag-region'.
(:front-sticky . t)
(:rear-sticky . t)
(:rear-sticky . nil)
(:font-lock-skip . t)
(:alias . (headline heading outline inlinetask plain-list)))
(org-fold-block
Expand Down

0 comments on commit 39005dc

Please sign in to comment.