Mercurial > hg > xemacs-beta
comparison man/lispref/help.texi @ 272:c5d627a313b1 r21-0b34
Import from CVS: tag r21-0b34
author | cvs |
---|---|
date | Mon, 13 Aug 2007 10:28:48 +0200 |
parents | c7528f8e288d |
children | a4f53d9b3154 |
comparison
equal
deleted
inserted
replaced
271:c7b7086b0a39 | 272:c5d627a313b1 |
---|---|
1 @c -*-texinfo-*- | 1 @c -*-texinfo-*- |
2 @c This is part of the XEmacs Lisp Reference Manual. | 2 @c This is part of the XEmacs Lisp Reference Manual. |
3 @c Copyright (C) 1990, 1991, 1992, 1993, 1994 Free Software Foundation, Inc. | 3 @c Copyright (C) 1990, 1991, 1992, 1993, 1994 Free Software Foundation, Inc. |
4 @c See the file lispref.texi for copying conditions. | 4 @c See the file lispref.texi for copying conditions. |
5 @setfilename ../../info/help.info | 5 @setfilename ../../info/help.info |
6 @node Documentation, Files, Modes, Top | 6 @node Documentation, Files, Modes, Top |
7 @chapter Documentation | 7 @chapter Documentation |
8 @cindex documentation strings | 8 @cindex documentation strings |
149 "Describe the XEmacs Lisp symbols matching PATTERN. | 149 "Describe the XEmacs Lisp symbols matching PATTERN. |
150 All symbols that have PATTERN in their name are described | 150 All symbols that have PATTERN in their name are described |
151 in the `*Help*' buffer." | 151 in the `*Help*' buffer." |
152 (interactive "sDescribe symbols matching: ") | 152 (interactive "sDescribe symbols matching: ") |
153 (let ((describe-func | 153 (let ((describe-func |
154 (function | 154 (function |
155 (lambda (s) | 155 (lambda (s) |
156 @end group | 156 @end group |
157 @group | 157 @group |
158 ;; @r{Print description of symbol.} | 158 ;; @r{Print description of symbol.} |
159 (if (fboundp s) ; @r{It is a function.} | 159 (if (fboundp s) ; @r{It is a function.} |
160 (princ | 160 (princ |
161 (format "%s\t%s\n%s\n\n" s | 161 (format "%s\t%s\n%s\n\n" s |
162 (if (commandp s) | 162 (if (commandp s) |
163 (let ((keys (where-is-internal s))) | 163 (let ((keys (where-is-internal s))) |
164 (if keys | 164 (if keys |
165 (concat | 165 (concat |
166 "Keys: " | 166 "Keys: " |
167 (mapconcat 'key-description | 167 (mapconcat 'key-description |
168 keys " ")) | 168 keys " ")) |
169 "Keys: none")) | 169 "Keys: none")) |
170 "Function") | 170 "Function") |
171 @end group | 171 @end group |
172 @group | 172 @group |
173 (or (documentation s) | 173 (or (documentation s) |
174 "not documented")))) | 174 "not documented")))) |
175 | 175 |
176 (if (boundp s) ; @r{It is a variable.} | 176 (if (boundp s) ; @r{It is a variable.} |
177 @end group | 177 @end group |
178 @group | 178 @group |
179 (princ | 179 (princ |
180 (format "%s\t%s\n%s\n\n" s | 180 (format "%s\t%s\n%s\n\n" s |
181 (if (user-variable-p s) | 181 (if (user-variable-p s) |
182 "Option " "Variable") | 182 "Option " "Variable") |
183 @end group | 183 @end group |
184 @group | 184 @group |
185 (or (documentation-property | 185 (or (documentation-property |
186 s 'variable-documentation) | 186 s 'variable-documentation) |
187 "not documented"))))))) | 187 "not documented"))))))) |
188 sym-list) | 188 sym-list) |
189 @end group | 189 @end group |
190 | 190 |
191 @group | 191 @group |
192 ;; @r{Build a list of symbols that match pattern.} | 192 ;; @r{Build a list of symbols that match pattern.} |
193 (mapatoms (function | 193 (mapatoms (function |
194 (lambda (sym) | 194 (lambda (sym) |
195 (if (string-match pattern (symbol-name sym)) | 195 (if (string-match pattern (symbol-name sym)) |
196 (setq sym-list (cons sym sym-list)))))) | 196 (setq sym-list (cons sym sym-list)))))) |
197 @end group | 197 @end group |
198 | 198 |
210 @smallexample | 210 @smallexample |
211 @group | 211 @group |
212 (describe-symbols "goal") | 212 (describe-symbols "goal") |
213 | 213 |
214 ---------- Buffer: *Help* ---------- | 214 ---------- Buffer: *Help* ---------- |
215 goal-column Option | 215 goal-column Option |
216 *Semipermanent goal column for vertical motion, as set by C-x C-n, or nil. | 216 *Semipermanent goal column for vertical motion, as set by C-x C-n, or nil. |
217 @end group | 217 @end group |
218 @c Do not blithely break or fill these lines. | 218 @c Do not blithely break or fill these lines. |
219 @c That makes them incorrect. | 219 @c That makes them incorrect. |
220 | 220 |
299 @table @code | 299 @table @code |
300 @item \[@var{command}] | 300 @item \[@var{command}] |
301 stands for a key sequence that will invoke @var{command}, or @samp{M-x | 301 stands for a key sequence that will invoke @var{command}, or @samp{M-x |
302 @var{command}} if @var{command} has no key bindings. | 302 @var{command}} if @var{command} has no key bindings. |
303 | 303 |
304 @item \@{@var{mapvar}@} | 304 @item \@{@var{mapvar}@} |
305 stands for a summary of the value of @var{mapvar}, which should be a | 305 stands for a summary of the value of @var{mapvar}, which should be a |
306 keymap. The summary is made by @code{describe-bindings}. | 306 keymap. The summary is made by @code{describe-bindings}. |
307 | 307 |
308 @item \<@var{mapvar}> | 308 @item \<@var{mapvar}> |
309 stands for no text itself. It is used for a side effect: it specifies | 309 stands for no text itself. It is used for a side effect: it specifies |
310 @var{mapvar} as the keymap for any following @samp{\[@var{command}]} | 310 @var{mapvar} as the keymap for any following @samp{\[@var{command}]} |
311 sequences in this documentation string. | 311 sequences in this documentation string. |
312 | 312 |
313 @item \= | 313 @item \= |
327 | 327 |
328 Here are examples of the special sequences: | 328 Here are examples of the special sequences: |
329 | 329 |
330 @smallexample | 330 @smallexample |
331 @group | 331 @group |
332 (substitute-command-keys | 332 (substitute-command-keys |
333 "To abort recursive edit, type: \\[abort-recursive-edit]") | 333 "To abort recursive edit, type: \\[abort-recursive-edit]") |
334 @result{} "To abort recursive edit, type: C-]" | 334 @result{} "To abort recursive edit, type: C-]" |
335 @end group | 335 @end group |
336 | 336 |
337 @group | 337 @group |
338 (substitute-command-keys | 338 (substitute-command-keys |
339 "The keys that are defined for the minibuffer here are: | 339 "The keys that are defined for the minibuffer here are: |
340 \\@{minibuffer-local-must-match-map@}") | 340 \\@{minibuffer-local-must-match-map@}") |
341 @result{} "The keys that are defined for the minibuffer here are: | 341 @result{} "The keys that are defined for the minibuffer here are: |
342 @end group | 342 @end group |
343 | 343 |
361 "Substrings of the form \\=\\@{MAPVAR@} are replaced by summaries | 361 "Substrings of the form \\=\\@{MAPVAR@} are replaced by summaries |
362 \(made by describe-bindings) of the value of MAPVAR, taken as a keymap. | 362 \(made by describe-bindings) of the value of MAPVAR, taken as a keymap. |
363 Substrings of the form \\=\\<MAPVAR> specify to use the value of MAPVAR | 363 Substrings of the form \\=\\<MAPVAR> specify to use the value of MAPVAR |
364 as the keymap for future \\=\\[COMMAND] substrings. | 364 as the keymap for future \\=\\[COMMAND] substrings. |
365 \\=\\= quotes the following character and is discarded; | 365 \\=\\= quotes the following character and is discarded; |
366 thus, \\=\\=\\=\\= puts \\=\\= into the output, | 366 thus, \\=\\=\\=\\= puts \\=\\= into the output, |
367 and \\=\\=\\=\\[ puts \\=\\[ into the output.") | 367 and \\=\\=\\=\\[ puts \\=\\[ into the output.") |
368 @result{} "Substrings of the form \@{MAPVAR@} are replaced by summaries | 368 @result{} "Substrings of the form \@{MAPVAR@} are replaced by summaries |
369 (made by describe-bindings) of the value of MAPVAR, taken as a keymap. | 369 (made by describe-bindings) of the value of MAPVAR, taken as a keymap. |
370 Substrings of the form \<MAPVAR> specify to use the value of MAPVAR | 370 Substrings of the form \<MAPVAR> specify to use the value of MAPVAR |
371 as the keymap for future \[COMMAND] substrings. | 371 as the keymap for future \[COMMAND] substrings. |
496 ---------- Buffer: *Help* ---------- | 496 ---------- Buffer: *Help* ---------- |
497 Buffer-menu-execute | 497 Buffer-menu-execute |
498 Function: Save and/or delete buffers marked with | 498 Function: Save and/or delete buffers marked with |
499 M-x Buffer-menu-save or M-x Buffer-menu-delete commands. | 499 M-x Buffer-menu-save or M-x Buffer-menu-delete commands. |
500 execute-extended-command ESC x | 500 execute-extended-command ESC x |
501 Function: Read function name, then read its | 501 Function: Read function name, then read its |
502 arguments and call it. | 502 arguments and call it. |
503 ---------- Buffer: *Help* ---------- | 503 ---------- Buffer: *Help* ---------- |
504 @end group | 504 @end group |
505 @end ignore | 505 @end ignore |
506 @end smallexample | 506 @end smallexample |
635 @end deffn | 635 @end deffn |
636 | 636 |
637 @ignore @c Not in XEmacs currently | 637 @ignore @c Not in XEmacs currently |
638 @c Emacs 19 feature | 638 @c Emacs 19 feature |
639 @defmac make-help-screen fname help-line help-text help-map | 639 @defmac make-help-screen fname help-line help-text help-map |
640 This macro defines a help command named @var{fname} that acts like a | 640 This macro defines a help command named @var{fname} that acts like a |
641 prefix key that shows a list of the subcommands it offers. | 641 prefix key that shows a list of the subcommands it offers. |
642 | 642 |
643 When invoked, @var{fname} displays @var{help-text} in a window, then | 643 When invoked, @var{fname} displays @var{help-text} in a window, then |
644 reads and executes a key sequence according to @var{help-map}. The | 644 reads and executes a key sequence according to @var{help-map}. The |
645 string @var{help-text} should describe the bindings available in | 645 string @var{help-text} should describe the bindings available in |