[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Re: Elusive buffer(s).

From: martin rudalics
Subject: Re: Re: Elusive buffer(s).
Date: Thu, 29 Dec 2011 20:55:50 +0100
User-agent: Thunderbird (Windows/20090302)

> That's clear, thanks, but then for the bug report I've mentioned below
> the question remains. How pcl-cvs managed to create and _select_ the
> *cvs* buffer without it appearing in the frame-local buffer list? Is it
> still a bug? Emacs or pcl-cvs one?

If you told me which function call is responsible for displaying that
buffer, I could try to look what happens.  Probably only very few people
nowadays use pcl-cvs and that's why no one so far responded to your bug

> I don't have Emacs 24 yet, but even if I had I can't see right now how I
> can use those functions to make a function that switches between two
> recent buffers. As I wrote in those bug-report, the function that I use
> (and bind to a key) looks like:
> (defun switch-to-previous-buffer ()
>     "Switch to the previous buffer."
>     (interactive)
>     (switch-to-buffer (other-buffer (current-buffer))))
> I also noticed that I never able to select *Info* buffer with this
> function. Why?
> BTW, an extended function that cycles between recent N buffers
> would be even more cool.
> FYI, it all started when I switched from XEmacs to Emacs. XEmacs has
> this function built-in and it's very convenient once one gets used to
> it. It's not a very big deal, but my attempt to emulate it in Emacs is
> still only semi-successful.

`other-buffer' isn't very useful for that.  I'd use the first N elements
of a list I would construct as in the completely untested snippet below.


(let (list)
  (dolist (buffer (buffer-list))
    (with-current-buffer buffer
      (when buffer-display-time
        (setq list (cons (cons (float-time buffer-display-time) buffer) 

  (sort list (function (lambda (a b) (> (car a) (car b))))))

reply via email to

[Prev in Thread] Current Thread [Next in Thread]