[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#37514: PATCH: Add setting to allow switching to an already-visible b
From: |
Jefferson Carpenter |
Subject: |
bug#37514: PATCH: Add setting to allow switching to an already-visible buffer by default |
Date: |
Thu, 26 Sep 2019 19:14:14 +0000 |
User-agent: |
Zoho Mail |
+bug-gnu-emacs
---- On Thu, 26 Sep 2019 19:13:08 +0000 Jefferson Carpenter
<jefferson@aoeu2code.com> wrote ----
> ---- On Thu, 26 Sep 2019 07:12:23 +0000 Eli Zaretskii <eliz@gnu.org> wrote
> ----
>
> >
> > Why is it important what "C-x b" offers as the default? You can still
> > type the name of the buffer you want and switch to it.
>
> Because it requires fewer key strokes.
>
> >
> > FWIW, I use the workflow you mention from time to time, and I never
> > felt the need for such an option, because its effect will be global on
> > the entire session, and I don't want it everywhere. I'd need to reset
> > such an option when I go back to the other workflows, which would be a
> > nuisance.
>
> >
> > And if the above is somehow still not satisfactory, you can always
> > write a trivial wrapper around switch-to-buffer, which behaves the way
> > you like. Why do we need to canonicalize this in Emacs?
>
> Because IMHO, emacs (and any software) should do as little as possible by
> default, or at least easily allow itself to be configured to do as little as
> possible. I think it makes the most sense that switch-to-buffer takes you
> back to the last buffer you were visiting by default, without doing the
> extra work of preferring buffers that are not currently visible.
>
>
> ---- On Thu, 26 Sep 2019 07:20:53 +0000 martin rudalics <rudalics@gmx.at>
> wrote ----
>
> >
> > Wouldn't 'quit-window' accomplish that without any prompting? Or
> > 'switch-to-prev-buffer'?
> >
> > Thanks, martin
> >
>
> No, quit-window buries the buffer that you leave, even though it switches
> directly to the previous buffer on the top of the buffer list, and so it
> cannot be used to alternate back and fourth. Switch-to-prev-buffer seems to
> do the same thing - executing it twice does not return you to the buffer you
> started at. Besides, using these functions would require adding an extra
> key in addition to 'C-x b', and keys are at a premium.
>