|
@@ -1148,14 +1148,13 @@ may have been stored before."
|
|
|
(when insert-here? (narrow-to-region beg beg))
|
|
|
(org-paste-subtree level template 'for-yank))
|
|
|
(org-capture-position-for-last-stored beg)
|
|
|
- (let ((end (if (org-at-heading-p) (line-end-position 0) (point))))
|
|
|
- (org-capture-empty-lines-after)
|
|
|
- (unless (org-at-heading-p) (outline-next-heading))
|
|
|
- (org-capture-mark-kill-region origin (point))
|
|
|
- (org-capture-narrow beg end)
|
|
|
- (when (or (search-backward "%?" beg t)
|
|
|
- (search-forward "%?" end t))
|
|
|
- (replace-match "")))))))
|
|
|
+ (org-capture-empty-lines-after)
|
|
|
+ (unless (org-at-heading-p) (outline-next-heading))
|
|
|
+ (org-capture-mark-kill-region origin (point))
|
|
|
+ (org-capture-narrow beg (1- (point)))
|
|
|
+ (when (or (search-backward "%?" beg t)
|
|
|
+ (search-forward "%?" nil t))
|
|
|
+ (replace-match ""))))))
|
|
|
|
|
|
(defun org-capture-place-item ()
|
|
|
"Place the template as a new plain list item."
|