]> code.delx.au - gnu-emacs/blobdiff - lispref/help.texi
Avoid name conflicts with outline.el. Use 3 installments to keep
[gnu-emacs] / lispref / help.texi
index a601825d053d886b38424918b9209d14e0b8615b..eb9dc0a75d7787cc28f0310d770aa17adc7e0368 100644 (file)
@@ -107,13 +107,15 @@ use to print nice-looking hardcopy for the file
 @section Access to Documentation Strings
 
 @defun documentation-property symbol property &optional verbatim
-This function returns the documentation string that is recorded
-in @var{symbol}'s property list under property @var{property}.  It
-retrieves the text from a file if necessary, and runs
-@code{substitute-command-keys} to substitute actual key bindings.  (This
-substitution is not done if @var{verbatim} is non-@code{nil}.)  If
-@var{property} isn't a string and doesn't refer to the documentation
-file @file{etc/DOC}, it is evaluated to obtain a string.
+This function returns the documentation string that is recorded in
+@var{symbol}'s property list under property @var{property}.  It
+retrieves the text from a file if the value calls for that.  If the
+property value isn't @code{nil}, isn't a string, and doesn't refer to
+text in a file, then it is evaluated to obtain a string.
+
+Finally, @code{documentation-property} passes the string through
+@code{substitute-command-keys} to substitute actual key bindings,
+unless @var{verbatim} is non-@code{nil}.
 
 @smallexample
 @group
@@ -129,14 +131,18 @@ file @file{etc/DOC}, it is evaluated to obtain a string.
 @end defun
 
 @defun documentation function &optional verbatim
-This function returns the documentation string of @var{function}.  If
-@var{function} is a symbol, this function looks for a
-@code{function-documentation'} property of that symbol; if it has a
-non-@code{nil} value, the documentation is taken from that value (if
-the value is not a string, it is evaluated).  Alternatively,
-@code{documentation} reads the text from a file if necessary.  Then
-(unless @var{verbatim} is non-@code{nil}) it calls
-@code{substitute-command-keys}, to return a value containing the
+This function returns the documentation string of @var{function}.
+
+If @var{function} is a symbol, this function first looks for the
+@code{function-documentation} property of that symbol; if that has a
+non-@code{nil} value, the documentation comes from that value (if the
+value is not a string, it is evaluated).  If @var{function} is not a
+symbol, or if it has no @code{function-documentation} property, then
+@code{documentation} extracts the documentation string from the actual
+function definition, reading it from a file if called for.
+
+Finally, unless @var{verbatim} is non-@code{nil}, it calls
+@code{substitute-command-keys} so as to return a value containing the
 actual (current) key bindings.
 
 The function @code{documentation} signals a @code{void-function} error
@@ -382,17 +388,17 @@ about valid events.  See also the examples for
 @cindex control character printing
 @cindex meta character printing
 This function returns a string describing @var{event} in the standard
-Emacs notation for keyboard input.  A normal printing character appears
-as itself, but a control character turns into a string starting with
-@samp{C-}, a meta character turns into a string starting with @samp{M-},
-and space, tab, etc.@: appear as @samp{SPC}, @samp{TAB}, etc.  A
-function key symbol appears as itsels, but inside angle brackets
-@samp{<>}.  An event that is a list appears as the name of the symbol
-in the @sc{car} of the list, inside angle brackets.
+Emacs notation for keyboard input.  A normal printing character
+appears as itself, but a control character turns into a string
+starting with @samp{C-}, a meta character turns into a string starting
+with @samp{M-}, and space, tab, etc.@: appear as @samp{SPC},
+@samp{TAB}, etc.  A function key symbol appears inside angle brackets
+@samp{<@dots{}>}.  An event that is a list appears as the name of the
+symbol in the @sc{car} of the list, inside angle brackets.
 
 If the optional argument @var{no-angles} is non-@code{nil}, the angle
 brackets around function keys and event symbols are omitted; this is
-for compatibility with old versions of Emacs which didn't print the
+for compatibility with old versions of Emacs which didn't use the
 brackets.
 
 @smallexample