emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] master 4d65821 1/2: Add/fix documentation for widget-apply


From: Juanma Barranquero
Subject: [Emacs-diffs] master 4d65821 1/2: Add/fix documentation for widget-apply
Date: Wed, 16 Oct 2019 09:43:15 -0400 (EDT)

branch: master
commit 4d65821bf016dff6a8b10578913970f854763346
Author: Juanma Barranquero <address@hidden>
Commit: Juanma Barranquero <address@hidden>

    Add/fix documentation for widget-apply
    
    * doc/misc/widget.texi (Widget Properties): Document `widget-apply'.
    
    * src/fns.c (Fwidget_apply): Document return value (used in many
    places).
---
 doc/misc/widget.texi | 6 ++++++
 src/fns.c            | 1 +
 2 files changed, 7 insertions(+)

diff --git a/doc/misc/widget.texi b/doc/misc/widget.texi
index 6d94768..c1127a4 100644
--- a/doc/misc/widget.texi
+++ b/doc/misc/widget.texi
@@ -1446,6 +1446,12 @@ Non-@code{nil} if @var{widget} has a value (even 
@code{nil}) for
 property @var{property}.
 @end defun
 
+@defun widget-apply widget property &rest args
+Apply the value of @var{property} to @var{widget}, passing @var{args}
+as additional arguments to the function.  Return the result of that
+function call.
+@end defun
+
 Occasionally it can be useful to know which kind of widget you have,
 i.e., the name of the widget type you gave when the widget was created.
 
diff --git a/src/fns.c b/src/fns.c
index fc1abe8..cbb6879 100644
--- a/src/fns.c
+++ b/src/fns.c
@@ -3093,6 +3093,7 @@ later with `widget-put'.  */)
 
 DEFUN ("widget-apply", Fwidget_apply, Swidget_apply, 2, MANY, 0,
        doc: /* Apply the value of WIDGET's PROPERTY to the widget itself.
+Return the result of applying the value of PROPERTY to WIDGET.
 ARGS are passed as extra arguments to the function.
 usage: (widget-apply WIDGET PROPERTY &rest ARGS)  */)
   (ptrdiff_t nargs, Lisp_Object *args)



reply via email to

[Prev in Thread] Current Thread [Next in Thread]