mirror of
https://git.savannah.gnu.org/git/emacs/org-mode.git
synced 2024-09-18 20:10:59 +00:00
Fix insert-heading
* lisp/org.el (org-insert-heading): Fix problem with inserting heading. The commit fixes a bug introduced in bb2022.
This commit is contained in:
parent
2e67699fe1
commit
0fff0ba6da
|
@ -7509,9 +7509,10 @@ This is important for non-interactive uses of the command."
|
||||||
(and (not (org-in-item-p)) org-insert-heading-respect-content)
|
(and (not (org-in-item-p)) org-insert-heading-respect-content)
|
||||||
(not (org-insert-item
|
(not (org-insert-item
|
||||||
(save-excursion
|
(save-excursion
|
||||||
(org-beginning-of-item)
|
(and (org-in-item-p)
|
||||||
(looking-at org-list-full-item-re)
|
(org-beginning-of-item)
|
||||||
(match-string 3)))))
|
(looking-at org-list-full-item-re)
|
||||||
|
(match-string 3))))))
|
||||||
(let (begn endn)
|
(let (begn endn)
|
||||||
(when (org-buffer-narrowed-p)
|
(when (org-buffer-narrowed-p)
|
||||||
(setq begn (point-min) endn (point-max))
|
(setq begn (point-min) endn (point-max))
|
||||||
|
|
Loading…
Reference in a new issue