[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: minibuffer-completion-help: make sorting of completions customizable
From: |
Stefan Monnier |
Subject: |
Re: minibuffer-completion-help: make sorting of completions customizable? |
Date: |
Tue, 25 Jan 2011 16:13:08 -0500 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/24.0.50 (gnu/linux) |
> As implemented, minibuffer-completion-help *always* sorts the
> completion list using string-lessp. This works most of the time,
> except when the caller has already
> set up the completions to reflect a desired order. Could the
> implementation be updated to provide a setting that could be let
> bound by the caller?
I've resisted it, because I think the right way is for the
completion-table itself to provide this function (the difference becomes
significant when completing things that are made of various parts, some
of which may be sorted one way and others some other way), but this is
a much more significant change.
It basically means extending the `boundaries' method into a generic
`meta-info' method that will include not just boundaries but also
sort-order, type (e.g. it can tell whether you're completing buffers,
files, or something else, which can then be associated to a config
variable to use different completion-styles for different types of
data), (un)quoting rules (needed for reliable completion of file names
in *shell* buffers), a different separator than \n to use in the
*Completions* buffer, ...
Stefan