emacs-devel
[Top][All Lists]
Advanced

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

Re: [PATCH] `completing-read`: Add `group-function` support to completio


From: Daniel Mendler
Subject: Re: [PATCH] `completing-read`: Add `group-function` support to completion metadata (REVISED PATCH)
Date: Thu, 29 Apr 2021 19:13:39 +0200

On 4/29/21 7:07 PM, Stefan Monnier wrote:
> The purpose of the `group-function` when called with a non-nil
> `transform` arg is not to *add* text but on the contrary to make the
> entries shorter (presumably by removing text shared by all elements of
> the group and made redundant by the group name being printed as
> a "section title").
> 
> So the purpose of `affixation/annotation-function` and `group-function`
> seem orthogonal (tho we should be careful to make them work together:
> the affixation/annotation function will usually need the "full name" in
> order to decide what to add, but that the thing should be added to the
> text as shortened by `group-function`).

Exactly, the grouping and affixation transformation functions are
orthogonal and should not be conflated. The patch I provided ensures
that the two features work well together - in both cases, with grouping
enabled and disabled.

Daniel



reply via email to

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