diff options
| author | Glenn Morris | 2007-08-03 03:14:34 +0000 |
|---|---|---|
| committer | Glenn Morris | 2007-08-03 03:14:34 +0000 |
| commit | fd2a7b94b3d89d6d46e7ec2776b25d27842ec34b (patch) | |
| tree | 9355cd1d5a98e9f7a4ca90e7181910897bf515b8 | |
| parent | 7d7d10b874929e0e46a96c870017db26c59b44c8 (diff) | |
| download | emacs-fd2a7b94b3d89d6d46e7ec2776b25d27842ec34b.tar.gz emacs-fd2a7b94b3d89d6d46e7ec2776b25d27842ec34b.zip | |
Drew Adams <drew.adams at oracle.com>
(pp-eval-expression): Add progress message. Make buffer writable.
| -rw-r--r-- | lisp/emacs-lisp/pp.el | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/lisp/emacs-lisp/pp.el b/lisp/emacs-lisp/pp.el index 21175a03b4d..a5cefff399f 100644 --- a/lisp/emacs-lisp/pp.el +++ b/lisp/emacs-lisp/pp.el | |||
| @@ -103,6 +103,7 @@ Also add the value to the front of the list in the variable `values'." | |||
| 103 | (interactive | 103 | (interactive |
| 104 | (list (read-from-minibuffer "Eval: " nil read-expression-map t | 104 | (list (read-from-minibuffer "Eval: " nil read-expression-map t |
| 105 | 'read-expression-history))) | 105 | 'read-expression-history))) |
| 106 | (message "Evaluating...") | ||
| 106 | (setq values (cons (eval expression) values)) | 107 | (setq values (cons (eval expression) values)) |
| 107 | (let* ((old-show-function temp-buffer-show-function) | 108 | (let* ((old-show-function temp-buffer-show-function) |
| 108 | ;; Use this function to display the buffer. | 109 | ;; Use this function to display the buffer. |
| @@ -126,13 +127,16 @@ Also add the value to the front of the list in the variable `values'." | |||
| 126 | (progn | 127 | (progn |
| 127 | (select-window window) | 128 | (select-window window) |
| 128 | (run-hooks 'temp-buffer-show-hook)) | 129 | (run-hooks 'temp-buffer-show-hook)) |
| 129 | (select-window old-selected))) | 130 | (select-window old-selected) |
| 131 | (message "Evaluating...done. \ | ||
| 132 | See buffer *Pp Eval Output*."))) | ||
| 130 | (message "%s" (buffer-substring (point-min) (point))) | 133 | (message "%s" (buffer-substring (point-min) (point))) |
| 131 | )))))) | 134 | )))))) |
| 132 | (with-output-to-temp-buffer "*Pp Eval Output*" | 135 | (with-output-to-temp-buffer "*Pp Eval Output*" |
| 133 | (pp (car values)) | 136 | (pp (car values)) |
| 134 | (with-current-buffer standard-output | 137 | (with-current-buffer standard-output |
| 135 | (emacs-lisp-mode) | 138 | (emacs-lisp-mode) |
| 139 | (setq buffer-read-only nil) | ||
| 136 | (set (make-local-variable 'font-lock-verbose) nil))))) | 140 | (set (make-local-variable 'font-lock-verbose) nil))))) |
| 137 | 141 | ||
| 138 | ;;;###autoload | 142 | ;;;###autoload |