]> git.eshelyaron.com Git - emacs.git/commitdiff
; Improve documentation of 'help-fns-edit-variable'
authorEli Zaretskii <eliz@gnu.org>
Wed, 16 Apr 2025 08:13:41 +0000 (11:13 +0300)
committerEshel Yaron <me@eshelyaron.com>
Thu, 17 Apr 2025 07:08:25 +0000 (09:08 +0200)
* lisp/help-fns.el (help-fns-edit-variable)
(help-enable-variable-value-editing): Doc fixes.

(cherry picked from commit bf737dc42a70fd8665b7c5ad506249a6119ec4c4)

lisp/help-fns.el

index 2ea4735dccd675b771c4dc0704b6b812be16cc2c..20992596c284e73206cc3765676328bc40faec2e 100644 (file)
@@ -77,11 +77,11 @@ current help buffer.")
 (make-obsolete-variable 'help-enable-completion-autoload nil "31.1")
 
 (defcustom help-enable-variable-value-editing nil
-  "If non-nil, allow editing values in *Help* buffers.
+  "If non-nil, allow editing variable values in *Help* buffers.
 
 To edit the value of a variable, use \\[describe-variable] to
 display a \"*Help*\" buffer, move point after the text
-\"Its value is\" and type \\`e'.
+\"Its value is\" and type \\`e' to invoke `help-fns-edit-variable'.
 
 Values that aren't readable by the Emacs Lisp reader can't be
 edited even if this option is enabled."
@@ -1575,7 +1575,16 @@ it is displayed along with the global value."
 (defvar help-fns--edit-variable)
 
 (defun help-fns-edit-variable ()
-  "Edit the variable under point."
+  "Edit the variable value at point in \"*Help*\" buffer.
+This command only works if `help-enable-variable-value-editing' is non-nil.
+
+To edit the value of a variable, use \\[describe-variable] followed by the name
+of a variable, to display a \"*Help*\" buffer, move point to
+the variable's value, usually after the text \"Its value is\", and
+type \\`e' to invoke this command.
+
+Values that aren't readable by the Emacs Lisp reader can't be edited
+by this command."
   (declare (completion ignore))
   (interactive)
   (let ((var (get-text-property (point) 'help-fns--edit-variable)))