[Top][All Lists]

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

Re: Ordering of command completions

From: Óscar Fuentes
Subject: Re: Ordering of command completions
Date: Sun, 07 Dec 2014 21:24:31 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/25.0.50 (gnu/linux)

Drew Adams <address@hidden> writes:

>> I use Ido+flx. Yes, as you type the number of candidates quickly
>> decrease from thousands to dozens, but my experience is that the
>> vast majority of candidates are not applicable on the current
>> context and they force you to type quite a bit more.
> I don't disagree wrt "applicable on the current context", but
> I'm wary as to what someone might think that should mean.
> I don't think Emacs should be overly ambitious here in excluding
> commands.  It should instead exclude only commands that it is
> absolutely sure no user would be able to use in the current
> context.  What "context" means here is probably the real question.

Well, if the command definition comes with an attached statement about
its applicable context ("when such mode is enabled") Emacs has a
definitive method for the decision.

>> Then we have non-predictability. You enable a mode through an
>> autoloaded function and suddenly, for the rest of the Emacs
>> session, `M-x foo' no longer resolves to the same list of
>> candidates where it used to.
> You see?  Now that's an example of what I meant by the meaning
> of "context" being important.
> To me, if you have loaded a library that defines commands that
> you can invoke currently (which, a priori is the case for most
> commands), then I *want* `M-x' to include those commands when
> my input matches their names.

I was thinking about this scenario: the user is happily hacking on C
code, then he starts Gnus, reads for a while, quits the Gnus session and
comes back to his C hacking. Now M-x lists hundreds of gnus-* functions
such as gnus-summary-expire-articles-now, which only applies to a Gnus
Summary buffer. This is a net negative contribution to the usability of


>> OTOH, if it is a matter of sorting the candidates, which is
>> what the OP suggested, it is fine.
> I see.  I misunderstood.  I asked whether by "noise" what
> was meant was a large number of candidates.

Yes, it was. The OP asked about the ordering of candidates. Then Lars
mentioned the old discussion about discarding the non-applicable ones,
those that I call "noise".


reply via email to

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