From: "Drew Adams" <drew.adams@oracle.com>
To: "'martin rudalics'" <rudalics@gmx.at>
Cc: 'Lars Magne Ingebrigtsen' <larsi@gnus.org>,
8368@debbugs.gnu.org, rms@gnu.org
Subject: bug#8368: 24.0.50; "temp" means "help" - rename or at least document
Date: Mon, 30 Apr 2012 07:28:04 -0700 [thread overview]
Message-ID: <FE922E770F1641C09E08C4A6FE1AC6BB@us.oracle.com> (raw)
In-Reply-To: <4F9E5E08.4030400@gmx.at>
> >> You don't have to remove and re-add any hooks. It's
> >> sufficient to turn off help mode in the body of
> >> `with-output-to-temp-buffer'. Similarly,
> >> if you don't want to run `completion-list-mode-finish', turn off
> >> `completion-list-mode' in the buffer.
> >
> > Sufficient? That sounds like more work, not less. Why
> > turn help mode etc. on automatically and then turn it off again.
> > Why not just remove the hook so it does not get turned on?
>
> Because it's non-trivial to "just" do that. We have to go through all
> users of `with-output-to-temp-buffer' and check whether they want to
> turn on help mode or not. I don't have the slightest idea
> whether, for example, the calls in ada-xref.el require activating
> help mode or not.
We might be miscommunicating.
First, let me say that I don't really want to argue about the solution so much
as report the problem and ask for a solution.
Second, I was not talking about changing any existing code, especially Emacs Dev
code. I was simply saying that because help-mode stuff is currently hard-coded
into `w-o-t-t-b', then IF a programmer wants a temp buffer without that help
stuff then s?he can do something like what I wrote, as a workaround: define a
macro that uses `w-o-t-t-b', but first removes the help-stuff hooks and restores
them afterward. That's all.
Your suggestion was IIUC to instead use `w-o-t-t-b' and just turn off help-mode
in the BODY. OK, but that means that help-mode is entered and exited for
nothing - the hooks are run uselessly. That's all I was pointing out. Nothing
wrong with such useless work, but it, like my workaround, does not seem like the
solution to the problem.
> Obviously, dealing with `temp-buffer-show-hook' in
> `with-output-to-plain-temp-buffer' isn't necessary either if you don't
> run `help-mode-setup' before.
Ah, yes. Of course that means paying even more attention etc.
Anyway, thanks for thinking about this. I really would like to see Emacs fixed
in this regard. To my mind (not having thought much about it, and being pretty
ignorant about it), I would think that inheritance could be used to factor out
the stuff that is not specifically for help mode (i.e., have the help-mode stuff
inherit from that).
next prev parent reply other threads:[~2012-04-30 14:28 UTC|newest]
Thread overview: 23+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-03-28 16:24 bug#8368: 24.0.50; "temp" means "help" - rename or at least document Drew Adams
2011-07-14 19:26 ` Lars Magne Ingebrigtsen
2011-09-11 3:45 ` Lars Magne Ingebrigtsen
2011-09-11 4:58 ` Stefan Monnier
2011-09-11 5:00 ` Lars Magne Ingebrigtsen
2012-04-28 0:15 ` Drew Adams
2012-04-28 8:25 ` martin rudalics
2012-04-28 14:00 ` Drew Adams
2012-04-29 10:40 ` martin rudalics
2012-04-29 15:28 ` Drew Adams
2012-04-30 9:40 ` martin rudalics
2012-04-30 14:28 ` Drew Adams [this message]
2012-05-01 8:08 ` martin rudalics
2012-05-01 13:09 ` Drew Adams
2012-05-02 9:40 ` martin rudalics
2012-05-02 14:19 ` Drew Adams
2012-04-28 15:07 ` Stefan Monnier
2016-04-28 10:28 ` Lars Ingebrigtsen
2019-10-11 20:34 ` Lars Ingebrigtsen
2011-09-11 18:41 ` Richard Stallman
2011-09-11 18:48 ` Lars Magne Ingebrigtsen
2011-09-11 19:24 ` Drew Adams
2011-09-12 2:46 ` Richard Stallman
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=FE922E770F1641C09E08C4A6FE1AC6BB@us.oracle.com \
--to=drew.adams@oracle.com \
--cc=8368@debbugs.gnu.org \
--cc=larsi@gnus.org \
--cc=rms@gnu.org \
--cc=rudalics@gmx.at \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.