diff options
| author | Dave Love | 1999-03-03 17:42:47 +0000 |
|---|---|---|
| committer | Dave Love | 1999-03-03 17:42:47 +0000 |
| commit | b64ef3fb2f84500d9aa18365a9556fc5d8799b66 (patch) | |
| tree | 186710910bcfaf6aa46efd93c6a9d258467b47b8 | |
| parent | 4029384bd476658dbb3bc819ecba4448923b49da (diff) | |
| download | emacs-b64ef3fb2f84500d9aa18365a9556fc5d8799b66.tar.gz emacs-b64ef3fb2f84500d9aa18365a9556fc5d8799b66.zip | |
(edit-options): Doc fix.
(list-options): Don't lose with unbound symbols. Maintain
Edit-options-mode.
| -rw-r--r-- | lisp/options.el | 32 |
1 files changed, 16 insertions, 16 deletions
diff --git a/lisp/options.el b/lisp/options.el index 413e4105171..3697de1080c 100644 --- a/lisp/options.el +++ b/lisp/options.el | |||
| @@ -37,9 +37,6 @@ | |||
| 37 | (defun list-options () | 37 | (defun list-options () |
| 38 | "Display a list of Emacs user options, with values and documentation." | 38 | "Display a list of Emacs user options, with values and documentation." |
| 39 | (interactive) | 39 | (interactive) |
| 40 | (save-excursion | ||
| 41 | (set-buffer (get-buffer-create "*List Options*")) | ||
| 42 | (Edit-options-mode)) | ||
| 43 | (with-output-to-temp-buffer "*List Options*" | 40 | (with-output-to-temp-buffer "*List Options*" |
| 44 | (let (vars) | 41 | (let (vars) |
| 45 | (mapatoms (function (lambda (sym) | 42 | (mapatoms (function (lambda (sym) |
| @@ -48,25 +45,28 @@ | |||
| 48 | (setq vars (sort vars 'string-lessp)) | 45 | (setq vars (sort vars 'string-lessp)) |
| 49 | (while vars | 46 | (while vars |
| 50 | (let ((sym (car vars))) | 47 | (let ((sym (car vars))) |
| 51 | (princ ";; ") | 48 | (when (boundp sym) |
| 52 | (prin1 sym) | 49 | (princ ";; ") |
| 53 | (princ ":\n\t") | 50 | (prin1 sym) |
| 54 | (prin1 (symbol-value sym)) | 51 | (princ ":\n\t") |
| 55 | (terpri) | 52 | (prin1 (symbol-value sym)) |
| 56 | (princ (substitute-command-keys | 53 | (terpri) |
| 57 | (documentation-property sym 'variable-documentation))) | 54 | (princ (substitute-command-keys |
| 58 | (princ "\n;;\n")) | 55 | (documentation-property sym 'variable-documentation))) |
| 59 | (setq vars (cdr vars))))) | 56 | (princ "\n;;\n")) |
| 60 | (save-excursion | 57 | (setq vars (cdr vars)))) |
| 61 | (set-buffer "*List Options*") | 58 | (with-current-buffer "*List Options*" |
| 62 | (setq buffer-read-only t))) | 59 | (Edit-options-mode) |
| 60 | (setq buffer-read-only t))))) | ||
| 63 | 61 | ||
| 64 | ;;;###autoload | 62 | ;;;###autoload |
| 65 | (defun edit-options () | 63 | (defun edit-options () |
| 66 | "Edit a list of Emacs user option values. | 64 | "Edit a list of Emacs user option values. |
| 67 | Selects a buffer containing such a list, | 65 | Selects a buffer containing such a list, |
| 68 | in which there are commands to set the option values. | 66 | in which there are commands to set the option values. |
| 69 | Type \\[describe-mode] in that buffer for a list of commands." | 67 | Type \\[describe-mode] in that buffer for a list of commands. |
| 68 | |||
| 69 | The Custom feature is intended to make this obsolete." | ||
| 70 | (interactive) | 70 | (interactive) |
| 71 | (list-options) | 71 | (list-options) |
| 72 | (pop-to-buffer "*List Options*")) | 72 | (pop-to-buffer "*List Options*")) |