[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: describe-mode "some-mode": (documentation some-mode) (was: IELM)
From: |
Emanuel Berg |
Subject: |
Re: describe-mode "some-mode": (documentation some-mode) (was: IELM) |
Date: |
Sun, 24 Aug 2014 04:05:40 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/24.3 (gnu/linux) |
lee <lee@yun.yagibdah.de> writes:
> (defun my-describe-mode () "Display the documentation
> of MODE." (interactive) (let ((mode (list (intern
> (read-string "Mode: "))))) (unless (functionp mode)
> (with-current-buffer (switch-to-buffer-other-window
> "my-describe-mode") (insert (documentation mode))))))
>
> This inserts "Keyboard macro." into the buffer
> (without the quotes). I'm not too sure about what I'm
> doing here ...
What are you trying to do?
Try: `M-x ielm RET', then type
(documentation 'emacs-lisp-mode)
and hit RET. See that it works except the \n's don't
get respected, so it is all on one/the same line.
I don't think it is wise to fiddle with
`documentation', so probably some wrapper must use
`documentation' to extract the docstring, and then
output it, substituting the \n's for newlines (and
more).
Get back to you on this.
> When I use (help-buffer) instead of
> "my-describe-mode" for a buffer, the (help-buffer)
> might be read-only?
The help buffers are read-only, yes.
--
underground experts united
- RE: describe-mode "some-mode"?, (continued)
- Message not available
- Re: describe-mode "some-mode"?, Emanuel Berg, 2014/08/23
- RE: describe-mode "some-mode"?, Drew Adams, 2014/08/23
- Message not available
- Re: describe-mode "some-mode"?, Emanuel Berg, 2014/08/31
- RE: describe-mode "some-mode"?, Drew Adams, 2014/08/31
- Message not available
- Re: describe-mode "some-mode"?, Emanuel Berg, 2014/08/23
Message not available
- Re: describe-mode "some-mode"?, Emanuel Berg, 2014/08/22
- IELM (was: Re: describe-mode "some-mode"?), Emanuel Berg, 2014/08/22
- describe-mode "some-mode": (documentation some-mode) (was: IELM), lee, 2014/08/23
- Message not available
- Re: describe-mode "some-mode": (documentation some-mode) (was: IELM),
Emanuel Berg <=
- Re: describe-mode "some-mode": (documentation some-mode), lee, 2014/08/30
- Re: describe-mode "some-mode": (documentation some-mode), Michael Heerdegen, 2014/08/30
Re: describe-mode "some-mode"?, Rusi, 2014/08/23