Re: Display *Help* in a dedicated frame
Heime <[email protected]>
| Newsgroups | gmane.emacs.help |
|---|---|
| Message-ID | <Lw3b4dPgGej1dZTEIrLloJ1JKeSk7lqjMxMUlcSTCLeItxl_AjsQs9hXIpa4VuZLFm8MHp6ayk1_Vx1sCt7gXC2t1zwgFoqgT12iy2ZzcVA=@protonmail.com> |
On Wednesday, April 1st, 2026 at 5:16 AM, [email protected] <[email protected]> wrote: > Heime <[email protected]> writes: > > > I would like to show the *Help* buffer display in some frame. > > But if it does not exist make one and name it something. > > > > How may I do so with an elisp function? > > > > (This is a guess about where you might look, assuming that > you have Emacs 30.) > > In Emacs 30, the new action entry ‘pop-up-frames’ for the > function ‘display-buffer’ has been added: > > C-h n: > ** New 'display-buffer' action alist entry 'pop-up-frames'. > This has the same effect as the variable of the same name and takes > precedence over the variable when present. Although this function makes a new frame, the original frame still gets split to show the *Help*, whereas the new frame stays empty. There are also the optional arguments in describe-symbol with some funky stuff happening in there. (defun ksymbol (sbl) "Show the full documentation of symbol SBL in a frame." (interactive (let ( (prompt (format "Describe Symbol [%s]: " (or (symbol-name (symbol-at-point)) ""))) ) (list (completing-read prompt obarray #'fboundp t nil nil (symbol-name (symbol-at-point)))))) (let* ( (rnm "[RDU] Quick Reference Display Unit") (frm (make-frame `((name . ,rnm) (minibuffer . nil)))) (bfr (generate-new-buffer "Describe Symbol")) (sym (intern sbl)) ) (set-window-buffer (frame-root-window frm) bfr) (with-current-buffer bfr (describe-symbol sym) (help-mode-setup-buttons bfr) (setq buffer-read-only t)) (select-frame-set-input-focus frm))) > See: > (info "(elisp) Displaying Buffers") > (info "(elisp) Choosing Window") > and > (info "(elisp) The Zen of Buffer Display") > > -- > The lyf so short, the craft so long to lerne. > - Geoffrey Chaucer, The Parliament of Birds. > >