diff options
| author | Eli Zaretskii | 2006-05-06 07:53:25 +0000 |
|---|---|---|
| committer | Eli Zaretskii | 2006-05-06 07:53:25 +0000 |
| commit | 321eb4b29a0cd5899f0ff7633f86935e9167175f (patch) | |
| tree | 18bedfbae6ba92e0a0f2b0fed8a47bab9610d450 | |
| parent | 41f7a85e0d33a63df8c1a4cac61fc3ee8b123d7c (diff) | |
| download | emacs-321eb4b29a0cd5899f0ff7633f86935e9167175f.tar.gz emacs-321eb4b29a0cd5899f0ff7633f86935e9167175f.zip | |
(Minibuffer History): Document add-to-history.
| -rw-r--r-- | lispref/minibuf.texi | 18 |
1 files changed, 17 insertions, 1 deletions
diff --git a/lispref/minibuf.texi b/lispref/minibuf.texi index 4faf8fd374c..dd96a020057 100644 --- a/lispref/minibuf.texi +++ b/lispref/minibuf.texi | |||
| @@ -449,11 +449,27 @@ list, put the length in the @code{history-length} property of the | |||
| 449 | history list symbol. The variable @code{history-delete-duplicates} | 449 | history list symbol. The variable @code{history-delete-duplicates} |
| 450 | specifies whether to delete duplicates in history. | 450 | specifies whether to delete duplicates in history. |
| 451 | 451 | ||
| 452 | @defun add-to-history history-var newelt &optional maxelt keep-dups | ||
| 453 | This function adds a new element @var{newelt} to the history list | ||
| 454 | stored in the variable @var{history-var}, and returns the updated | ||
| 455 | history list. By default, the list length is limited by the value | ||
| 456 | specified by @code{history-length} (described below), but the optional | ||
| 457 | argument @var{maxelt} overrides that. The possible values of | ||
| 458 | @var{maxelt} have the same meaning as the values of | ||
| 459 | @code{history-length}. | ||
| 460 | |||
| 461 | Duplicate members are removed from the history list, unless | ||
| 462 | @code{history-delete-duplicates} is @code{nil} or the second optional | ||
| 463 | argument of this function @var{keep-dups} is non-@code{nil}. | ||
| 464 | @end defun | ||
| 465 | |||
| 452 | @defvar history-length | 466 | @defvar history-length |
| 453 | The value of this variable specifies the maximum length for all | 467 | The value of this variable specifies the maximum length for all |
| 454 | history lists that don't specify their own maximum lengths. If the | 468 | history lists that don't specify their own maximum lengths. If the |
| 455 | value is @code{t}, that means there no maximum (don't delete old | 469 | value is @code{t}, that means there no maximum (don't delete old |
| 456 | elements). | 470 | elements). The value of @code{history-length} property of the history |
| 471 | list variable's symbol, if set, overrides this variable for that | ||
| 472 | particular history list. | ||
| 457 | @end defvar | 473 | @end defvar |
| 458 | 474 | ||
| 459 | @defvar history-delete-duplicates | 475 | @defvar history-delete-duplicates |