unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
* Re: Intelligent history cycling
       [not found] ` <vafwuss7g9m.fsf@lucy.cs.uni-dortmund.de>
@ 2002-06-21 20:11   ` Stefan Monnier <foo@acm.com>
  2002-06-22  9:33     ` Kai Großjohann
  2002-06-22 22:51     ` Richard Stallman
  0 siblings, 2 replies; 4+ messages in thread
From: Stefan Monnier <foo@acm.com> @ 2002-06-21 20:11 UTC (permalink / raw)


>>>>> "Kai" == Kai Großjohann <Kai.Grossjohann@CS.Uni-Dortmund.DE> writes:
> I use this:
> (mapcar
>  (function
>   (lambda (x)
>     (define-key x (kbd "ESC p") 'previous-complete-history-element)
>     (define-key x (kbd "ESC n") 'next-complete-history-element)))
>  (list minibuffer-local-completion-map minibuffer-local-isearch-map
>        minibuffer-local-map minibuffer-local-must-match-map
>        minibuffer-local-ns-map))
> I wish there was a default keybinding for this.

I also use it just like you.  Actually, if you look at simple.el you'll
see that there is code that does it as well, but it's commented out.
I wish we could turn it on again.

I think Richard didn't like it for some reason.  Maybe it was because
it fails when nothing matches or because C-x C-f M-p only lists the
previous file(s) in the same directory.
I've actually changed mine such that M-p only does search if the
user has already typed something (so that C-x C-f M-p behaves just
like it does now).  Also M-p reverts back to non-searching if the
search fails.


        Stefan

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Intelligent history cycling
  2002-06-21 20:11   ` Intelligent history cycling Stefan Monnier <foo@acm.com>
@ 2002-06-22  9:33     ` Kai Großjohann
  2002-06-22 17:46       ` Stefan Monnier
  2002-06-22 22:51     ` Richard Stallman
  1 sibling, 1 reply; 4+ messages in thread
From: Kai Großjohann @ 2002-06-22  9:33 UTC (permalink / raw)
  Cc: emacs-devel

"Stefan Monnier <foo@acm.com>" <monnier+gnu.emacs.help/news/@rum.cs.yale.edu> writes:

> I also use it just like you.  Actually, if you look at simple.el you'll
> see that there is code that does it as well, but it's commented out.
> I wish we could turn it on again.

Maybe it's enough to find free keys?  Hm.  Lessee...  One possibility
is to use C-n/C-p for next/prev history element, and M-n/M-p for
next/prev complete history element.

C-c C-n/C-c C-p are still free.

C-M-n/C-M-p could be used, since these commands don't appear
necessary in the minibuffer.

kai
-- 
A large number of young women don't trust men with beards.  (BFBS Radio)

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Intelligent history cycling
  2002-06-22  9:33     ` Kai Großjohann
@ 2002-06-22 17:46       ` Stefan Monnier
  0 siblings, 0 replies; 4+ messages in thread
From: Stefan Monnier @ 2002-06-22 17:46 UTC (permalink / raw)
  Cc: emacs-devel

> > I also use it just like you.  Actually, if you look at simple.el you'll
> > see that there is code that does it as well, but it's commented out.
> > I wish we could turn it on again.
> Maybe it's enough to find free keys?

I don't see a need for it.  M-n and M-p work just fine.  You can always
get the old (i.e. current) behavior with C-a C-k M-p and C-a C-k M-n
(although in most cases you don't need to since M-p and M-n are mostly used
before doing anything else (before modifying the prompt) in which case
my code is careful to not do a history search but just the good
old "fetch next/prev history item").


	Stefan

PS: your "From:" header is giving problems because it's split on a second
    line just between Kai and Grossjohann.  Sometimes I see a space
    between the two, and sometimes not, depending on what piece of code
    it goes through.  Furthermore, it triggers a harmless bug in my mail
    reader :-(

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Intelligent history cycling
  2002-06-21 20:11   ` Intelligent history cycling Stefan Monnier <foo@acm.com>
  2002-06-22  9:33     ` Kai Großjohann
@ 2002-06-22 22:51     ` Richard Stallman
  1 sibling, 0 replies; 4+ messages in thread
From: Richard Stallman @ 2002-06-22 22:51 UTC (permalink / raw)
  Cc: emacs-devel

    I think Richard didn't like it for some reason.  Maybe it was because
    it fails when nothing matches or because C-x C-f M-p only lists the
    previous file(s) in the same directory.

I prefer the current behavior of M-p and M-n.
We have other commands to search the history list.

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2002-06-22 22:51 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <3D1350DF.9080502@radioscape.com>
     [not found] ` <vafwuss7g9m.fsf@lucy.cs.uni-dortmund.de>
2002-06-21 20:11   ` Intelligent history cycling Stefan Monnier <foo@acm.com>
2002-06-22  9:33     ` Kai Großjohann
2002-06-22 17:46       ` Stefan Monnier
2002-06-22 22:51     ` Richard Stallman

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).