aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNoam Postavsky2016-12-19 19:49:47 -0500
committerNoam Postavsky2016-12-19 20:02:57 -0500
commit88cdf14b37a7344bb266e94512485e3cc738c23d (patch)
treeeefe4d81bf729855905da86400e31df39ac9342a
parentce5538248e29ba2e4db531192a92e7c334de92da (diff)
downloademacs-88cdf14b37a7344bb266e94512485e3cc738c23d.tar.gz
emacs-88cdf14b37a7344bb266e94512485e3cc738c23d.zip
Improve skeleton docstrings
* lisp/skeleton.el (skeleton-end-newline): Remove mention of `skeleton-end-hook', its default code was moved into `skeleton-insert'. (skeleton-insert): Mention `skeleton-end-newline' and move reference to `skeleton-end-hook' above the explanation of skeleton syntax.
-rw-r--r--lisp/skeleton.el12
1 files changed, 6 insertions, 6 deletions
diff --git a/lisp/skeleton.el b/lisp/skeleton.el
index 0e81e2d74c6..1b77a095fbc 100644
--- a/lisp/skeleton.el
+++ b/lisp/skeleton.el
@@ -59,8 +59,7 @@ region.")
59(make-obsolete-variable 'skeleton-autowrap nil "24.5") 59(make-obsolete-variable 'skeleton-autowrap nil "24.5")
60 60
61(defvar skeleton-end-newline t 61(defvar skeleton-end-newline t
62 "If non-nil, make sure that the skeleton inserted ends with a newline. 62 "If non-nil, make sure that the skeleton inserted ends with a newline.")
63This just influences the way the default `skeleton-end-hook' behaves.")
64 63
65(defvar skeleton-end-hook nil 64(defvar skeleton-end-hook nil
66 "Hook called at end of skeleton but before going to point of interest. 65 "Hook called at end of skeleton but before going to point of interest.
@@ -187,6 +186,10 @@ The optional third argument STR, if specified, is the value for the
187variable `str' within the skeleton. When this is non-nil, the 186variable `str' within the skeleton. When this is non-nil, the
188interactor gets ignored, and this should be a valid skeleton element. 187interactor gets ignored, and this should be a valid skeleton element.
189 188
189When done with skeleton, but before going back to `_'-point, add
190a newline (unless `skeleton-end-newline' is non-nil) and run the
191hook `skeleton-end-hook'.
192
190SKELETON is made up as (INTERACTOR ELEMENT ...). INTERACTOR may be nil if 193SKELETON is made up as (INTERACTOR ELEMENT ...). INTERACTOR may be nil if
191not needed, a prompt-string or an expression for complex read functions. 194not needed, a prompt-string or an expression for complex read functions.
192 195
@@ -235,10 +238,7 @@ available:
235 then: insert previously read string once more 238 then: insert previously read string once more
236 help help-form during interaction with the user or nil 239 help help-form during interaction with the user or nil
237 input initial input (string or cons with index) while reading str 240 input initial input (string or cons with index) while reading str
238 v1, v2 local variables for memorizing anything you want 241 v1, v2 local variables for memorizing anything you want"
239
240When done with skeleton, but before going back to `_'-point call
241`skeleton-end-hook' if that is non-nil."
242 (let ((skeleton-regions regions)) 242 (let ((skeleton-regions regions))
243 (and skeleton-regions 243 (and skeleton-regions
244 (setq skeleton-regions 244 (setq skeleton-regions