branch: externals/org
commit 0a9a8e1b438bb507e8c6fbc4557f453dcc5bb760
Author: Ihor Radchenko <[email protected]>
Commit: Ihor Radchenko <[email protected]>

    org-capture-fill-template: Clarify that point may move as a side effect
    
    * lisp/org-capture.el (org-capture-fill-template): Update the
    docstring, warning that calling the function might lead to point
    moving in displayed buffers.
    
    Reported-by: Lewis Baker <[email protected]>
    Link: 
https://orgmode.org/list/calqfjj6gmrqkgxksv7bk4h6yrwwilmsv2-e1zz+gd6y-_oa...@mail.gmail.com
---
 lisp/org-capture.el | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/lisp/org-capture.el b/lisp/org-capture.el
index 3c80408544..5d5b1ed70a 100644
--- a/lisp/org-capture.el
+++ b/lisp/org-capture.el
@@ -1745,7 +1745,10 @@ The template may still contain \"%?\" for cursor 
positioning.
 INITIAL content and/or ANNOTATION may be specified, but will be overridden
 by their respective `org-store-link-plist' properties if present.
 
-Expansion occurs in a temporary Org mode buffer."
+Expansion occurs in a temporary Org mode buffer that will be displayed
+if the template expansion triggers user prompt.  Beware that displaying
+the temporary buffer may alter point position in the already displayed
+buffers."
   (let* ((template (or template (org-capture-get :template)))
         (buffer (org-capture-get :buffer))
         (file (buffer-file-name (or (buffer-base-buffer buffer) buffer)))

Reply via email to