all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Michael Heerdegen <michael_heerdegen@web.de>
To: help-gnu-emacs@gnu.org
Subject: Re: switch to previous buffer
Date: Tue, 02 Apr 2013 23:23:21 +0200	[thread overview]
Message-ID: <87fvz88w52.fsf@web.de> (raw)
In-Reply-To: <382a2375-aed1-4deb-ad29-21952926c809@googlegroups.com> (Rami A.'s message of "Fri, 29 Mar 2013 15:07:04 -0700 (PDT)")

Rami A <rami.ammari@gmail.com> writes:

> Usually I switch between buffers going through the "buffer menu".
> So I would be in Buffer 1 -> C-x C-b "bufer menu" -> buffer 2
>
> I have the short cut:
> (global-set-key "\M-a" 'switch-to-previous-buffer)
>
> So I could switch back to the previous buffer.
> How is possible to skip the buffer menu when doing so.
>
> Basically,
> Buffer 1 -> C-x C-b "bufer menu" -> buffer 2 -> M-a -> buffer 1
> "without going back to buffer menu"

Have a look at winner.el, which is part of Gnu Emacs.  `winner-undo'
should do what you want.  It is very handy when it's on a good key, I
use it all the time.

Basically, winner.el is about window configurations, but since changing
a window's buffer is regarded as a change of the window
configuration... calling `winner-undo' gives you the previously shown
buffer in that window.  Moreover, winner.el also records the window
layout, so that you can "undo" popup windows etc.


Regards,

Michael.



      parent reply	other threads:[~2013-04-02 21:23 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-03-29 22:07 switch to previous buffer Rami A
2013-03-29 22:58 ` Chris F.A. Johnson
2013-03-29 23:17   ` Rami A
2013-03-29 23:20     ` Rami A
2013-03-30  0:12     ` Chris F.A. Johnson
2013-03-30  0:23       ` Rami A
2013-03-30  6:51     ` Bob Proulx
2013-03-30  7:08       ` Le Wang
2013-03-30 14:31         ` Drew Adams
     [not found]       ` <mailman.23083.1364627323.855.help-gnu-emacs@gnu.org>
2013-03-30  8:07         ` Rami A
2013-03-31 13:01           ` Oleksandr Gavenko
2013-03-31 13:17             ` Teemu Likonen
2013-03-31 22:28               ` Oleksandr Gavenko
     [not found]           ` <mailman.23139.1364734910.855.help-gnu-emacs@gnu.org>
2013-03-31 19:46             ` Rami A
2013-04-01 20:53               ` Oleksandr Gavenko
     [not found]               ` <mailman.23252.1364849659.855.help-gnu-emacs@gnu.org>
2013-04-02  3:07                 ` Rami A
2013-03-30 11:03 ` Bernardo
2013-04-02 21:23 ` Michael Heerdegen [this message]

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=87fvz88w52.fsf@web.de \
    --to=michael_heerdegen@web.de \
    --cc=help-gnu-emacs@gnu.org \
    /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.