Mercurial > hg > xemacs-beta
comparison lisp/prim/help.el @ 2:ac2d302a0011 r19-15b2
Import from CVS: tag r19-15b2
author | cvs |
---|---|
date | Mon, 13 Aug 2007 08:46:35 +0200 |
parents | 376386a54a3c |
children | b82b59fe008d |
comparison
equal
deleted
inserted
replaced
1:c0c6a60d29db | 2:ac2d302a0011 |
---|---|
350 ;; Use this function for displaying help when C-h something is pressed | 350 ;; Use this function for displaying help when C-h something is pressed |
351 ;; or in similar situations. Do *not* use it when you are displaying | 351 ;; or in similar situations. Do *not* use it when you are displaying |
352 ;; a help message and then prompting for input in the minibuffer -- | 352 ;; a help message and then prompting for input in the minibuffer -- |
353 ;; this macro usually selects the help buffer, which is not what you | 353 ;; this macro usually selects the help buffer, which is not what you |
354 ;; want in those situations. | 354 ;; want in those situations. |
355 | |
356 ;;; ### Should really be a macro (as suggested above) to eliminate the | |
357 ;;; requirement of caller to code a lambda form in THUNK -- mrb | |
355 (defun with-displaying-help-buffer (thunk) | 358 (defun with-displaying-help-buffer (thunk) |
356 (let ((winconfig (current-window-configuration)) | 359 (let ((winconfig (current-window-configuration)) |
357 (was-one-window (one-window-p))) | 360 (was-one-window (one-window-p))) |
358 (prog1 (with-output-to-temp-buffer "*Help*" | 361 (prog1 (with-output-to-temp-buffer "*Help*" |
359 (prog1 (funcall thunk) | 362 (prog1 (funcall thunk) |