|
From: | Juri Linkov |
Subject: | Re: [PATCH] `completing-read`: Add `group-function` support to completion metadata (REVISED PATCH VERSION 5) |
Date: | Tue, 11 May 2021 20:59:35 +0300 |
User-agent: | Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (x86_64-pc-linux-gnu) |
> 1. By doing such an override the ability of the user to configure the > completion UI is subverted. Such an override could be advisable only when the API user provides an equivalent user option with more choices when necessary. > 2. Since the variables are let-bound, they influence the behavior of > nested recursive completion sessions. It is better to override the > variables with `setq-local` in a `minibuffer-setup-hook`. Agreed. > +(defcustom completions-group-sort-function #'identity > + "Sorting function for the groups. > +The function takes and returns an alist of groups, where the each > +element is a pair of a group title string and the candidate strings > +belonging to the group." > + :type 'function > + :version "28.1") As the most useful non-default choice, it could also include a function to sort alphabetically.
[Prev in Thread] | Current Thread | [Next in Thread] |