all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: "Drew Adams" <drew.adams@oracle.com>
To: "'Juri Linkov'" <juri@jurta.org>, "'Xavier Maillard'" <xma@gnu.org>
Cc: monnier@iro.umontreal.ca, emacs-devel@gnu.org
Subject: RE: C-r and C-s in minibuffer should search completion
Date: Sat, 29 Mar 2008 09:23:37 -0700	[thread overview]
Message-ID: <001901c891b9$3e6c95a0$0200a8c0@us.oracle.com> (raw)
In-Reply-To: <877iflk8zy.fsf@jurta.org>

> Normally <prior> is bound to previous-history-element, but in some
> minibuffers it is bound to switch-to-completions.

Yes, that is poor design, IMO. Not the fact that it has a different meaning in
different minibuffer maps (completion vs no completion), but the fact that the
`prior' key is naturally associated with the `next' key, and Emacs does not
exploit that association - it breaks it.

> Maybe we should avoid this inconsistency by using
> another key for switch-to-completions?

FWIW, Icicles uses `C-insert' for this. And hitting it again takes you back to
the minibuffer (and copies the completion at point in *Completions* to the
minibuffer` for editing). That key won't work for emacs -nw, but `M-insert'
presumably would (in the form of `ESC insert'). 

(Icicles uses `insert' itself for something else. And Emacs likewise should
perhaps reserve `insert' for something that needs to be quick. Switching buffers
need not be so quick as to deserve a single key.)

> What about binding switch-to-completions to <M-down> because typing
> simply <down> starts moving to the next item in a list of defaults
> and completions. And also to bind a new command switch-to-history
> (that will display a list of history items in a separate window)
> to <M-up> because simply <up> moves to the previous history item.

Your association is a bit far-fetched, IMO - you are stretching things to fit
your proposal, rather than proposing something that seems natural.

There is little connection between the idea of having `down' and `up' move to
the next and previous items in a series and the idea of switching
windows/buffers.

Other things being equal: Keys that form natural pairs, such as `down'/`up',
`next'/`prior', and `home'/`end' should be reserved for things that perform some
sort of succession (i.e., next or previous) behavior. Or for some sort of
bracketing (e.g. grouping) behavior, such as start-something...end-something. Or
for some sort of complementary behavior (e.g. `insert'/`delete'). The same is
true for other such natural pairs of keys: (), [], {}, <>.

Succession is a natural choice for pairs, such as `next'/`prior', whose names
suggest succession. Opposite behavior can be a natural choice for pairs, such as
`insert'/`delete', whose names suggest that.

Finally, why use a separate window for history items? Why not simply use
*Completions* and let users complete against history items? IOW, use the normal
completion mechanism, with everything that it provides.

That is what I suggested when I mentioned `M-o', which is the key that Icicles
uses for this. You can use `M-o' from any minibuffer, not just during
completion. It uses a recursive minibuffer to let you choose from the current
input history (using completion) - your choice is inserted in the minibuffer,
where you can edit it for the original minibuffer reading.






  reply	other threads:[~2008-03-29 16:23 UTC|newest]

Thread overview: 64+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-03-20 19:13 C-r and C-s in minibuffer should search completion Stefan Monnier
2008-03-20 19:35 ` Juri Linkov
2008-03-20 20:07   ` Lennart Borgman (gmail)
2008-03-20 20:38     ` Juri Linkov
2008-03-20 20:54       ` Drew Adams
2008-03-20 23:07         ` Juri Linkov
2008-03-20 22:13   ` Stefan Monnier
2008-03-20 22:27     ` Drew Adams
2008-03-20 23:03     ` Juri Linkov
2008-03-21  1:26       ` Stefan Monnier
2008-03-22  1:17         ` Juri Linkov
2008-03-22 17:04           ` Stefan Monnier
2008-03-23  2:17             ` Juri Linkov
2008-03-23  3:24               ` Stefan Monnier
2008-03-29  1:00   ` Xavier Maillard
2008-03-29 12:30     ` Juri Linkov
2008-03-29 16:23       ` Drew Adams [this message]
2008-03-30  0:38         ` Juri Linkov
2008-03-30  2:38           ` Drew Adams
2008-03-20 20:44 ` Drew Adams
2008-03-25 21:44 ` Juri Linkov
2008-03-26  2:31   ` Stefan Monnier
2008-03-26  7:01     ` Drew Adams
2008-03-26 14:41       ` Stefan Monnier
2008-03-26 17:07         ` Drew Adams
2008-03-26 10:56     ` Juri Linkov
2008-03-26 14:47       ` Stefan Monnier
2008-03-27  0:44         ` Juri Linkov
2008-03-27  2:43           ` Stefan Monnier
2008-03-27 23:43             ` Juri Linkov
2008-03-29  4:03               ` Stefan Monnier
2008-03-30  0:44                 ` Juri Linkov
2008-03-30  4:01                   ` Stefan Monnier
2008-03-30 18:32                     ` Juri Linkov
2008-03-30 22:41                       ` Stefan Monnier
2008-03-30 23:50                         ` Juri Linkov
2008-03-31  2:11                           ` Stefan Monnier
2008-04-03 22:59                             ` Juri Linkov
2008-04-04  1:18                               ` Stefan Monnier
2008-04-06 20:45                                 ` Juri Linkov
2008-04-07 15:32                                   ` Stefan Monnier
2008-04-15 22:28                                     ` Juri Linkov
2008-04-16  2:08                                       ` Stefan Monnier
2008-04-16 23:16                                         ` Juri Linkov
2008-04-17  1:41                                           ` Stefan Monnier
2008-04-17  9:18                                             ` Juri Linkov
2008-04-18  1:07                                               ` Stefan Monnier
2008-04-19 20:11                                                 ` Juri Linkov
2008-04-19 21:10                                                   ` Stefan Monnier
2008-04-19 22:46                                                     ` Juri Linkov
2008-04-20  2:44                                                       ` Stefan Monnier
2008-04-21 21:51                                                         ` Juri Linkov
2008-04-22  3:11                                                           ` Stefan Monnier
2008-04-22 20:59                                                             ` Juri Linkov
2008-04-23  2:28                                                               ` Stefan Monnier
2008-04-21  3:07                                                       ` Richard Stallman
2008-04-21 22:54                                                         ` Juri Linkov
2008-04-22  3:10                                                           ` Stefan Monnier
2008-03-30  0:44                 ` minibuffer-default-add-shell-commands (was: C-r and C-s in minibuffer should search completion) Juri Linkov
2008-03-30  4:08                   ` minibuffer-default-add-shell-commands Stefan Monnier
2008-03-30 18:28                     ` minibuffer-default-add-shell-commands Juri Linkov
2008-03-30 11:30                   ` minibuffer-default-add-shell-commands Reiner Steib
2008-03-30 18:31                     ` minibuffer-default-add-shell-commands Juri Linkov
2008-03-30 20:25                       ` minibuffer-default-add-shell-commands Reiner Steib

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='001901c891b9$3e6c95a0$0200a8c0@us.oracle.com' \
    --to=drew.adams@oracle.com \
    --cc=emacs-devel@gnu.org \
    --cc=juri@jurta.org \
    --cc=monnier@iro.umontreal.ca \
    --cc=xma@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.