[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH] (icomplete-vertical-mode): Add support for affixations and,
From: |
Juri Linkov |
Subject: |
Re: [PATCH] (icomplete-vertical-mode): Add support for affixations and, annotations |
Date: |
Tue, 25 May 2021 19:59:25 +0300 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (x86_64-pc-linux-gnu) |
> I have no strong feelings on plist, versus alist, versus propertized
> string, versus object, versus whatever. Just slightly strong feelings
> as to the fundamental mission of this function which is to do
> annotation/affixation/whatchacallit, not filtering or reordering.
>
> For reasons of "forward compatibility", as you called them, which is the
> ability for newer backends to work on older Emacs that don't understand
> these new things, if that work is done in `annotation-function` then it
> needs to use propertized strings. But if it's done in a new thing, say
> called decoration-function, it doesn't.
As I said a month ago, while affixation-function was an improvement over
annotation-function, it's still not perfect. I welcome a better API function,
but OTOH adding prefix/suffix text properties on the annotation strings
is not an improvement.
> To clarify, the analog in some markup format is specifying something as
> "emphasis" and then the renderer usually decides that bold if it can, or
> surround it in asterisks. But the markup format doesn't usually say
> "bold". For the same reasons, what you're now calling "columns" should
> probably be referred to as "fields" or something equivalently agnostic
> as to the format in which they are display.
While looking for an analog, a better analogy would be the classic
MVC architecture:
- M: data comes from the list of completion strings;
- V: render functions like completion--insert-* or icomplete-completions;
- C: API callers that provide metadata functions that specify
how to process data for displaying, e.g. they define display-sort-function
where the prefix 'display-' hints that it affects the view,
so the frontend has no own choice how to sort completions.
Following such pattern, affixation-function could return more fields
(e.g. when completions-format is customized to the value 'multi-column')
in the same format as tabulated-list (and an indication in which column
there are completion candidates) for the frontend to display in columns.
- Re: [PATCH] (icomplete-vertical-mode): Add support for affixations and, annotations, (continued)
- Re: [PATCH] (icomplete-vertical-mode): Add support for affixations and, annotations, Dmitry Gutov, 2021/05/24
- Re: [PATCH] (icomplete-vertical-mode): Add support for affixations and, annotations, Juri Linkov, 2021/05/23
- Re: [PATCH] (icomplete-vertical-mode): Add support for affixations and, annotations, Juri Linkov, 2021/05/23
- Re: [PATCH] (icomplete-vertical-mode): Add support for affixations and, annotations, Daniel Mendler, 2021/05/24
- Re: [PATCH] (icomplete-vertical-mode): Add support for affixations and, annotations, Juri Linkov, 2021/05/24
- Re: [PATCH] (icomplete-vertical-mode): Add support for affixations and, annotations, Daniel Mendler, 2021/05/24
- Re: [PATCH] (icomplete-vertical-mode): Add support for affixations and, annotations, João Távora, 2021/05/25
- Re: [PATCH] (icomplete-vertical-mode): Add support for affixations and, annotations,
Juri Linkov <=
- Re: [PATCH] (icomplete-vertical-mode): Add support for affixations and, annotations, João Távora, 2021/05/25
- Re: [PATCH] (icomplete-vertical-mode): Add support for affixations and, annotations, Juri Linkov, 2021/05/25
- Re: [PATCH] (icomplete-vertical-mode): Add support for affixations and, annotations, Juri Linkov, 2021/05/26
- Re: [PATCH] (icomplete-vertical-mode): Add support for affixations and, annotations, Dmitry Gutov, 2021/05/26
- Re: [PATCH] (icomplete-vertical-mode): Add support for affixations and, annotations, João Távora, 2021/05/26
- Re: [PATCH] (icomplete-vertical-mode): Add support for affixations and, annotations, Dmitry Gutov, 2021/05/26
- Re: [PATCH] (icomplete-vertical-mode): Add support for affixations and, annotations, João Távora, 2021/05/27
- Re: [PATCH] (icomplete-vertical-mode): Add support for affixations and, annotations, Dmitry Gutov, 2021/05/27
- Re: [PATCH] (icomplete-vertical-mode): Add support for affixations and, annotations, João Távora, 2021/05/27
- Re: [PATCH] (icomplete-vertical-mode): Add support for affixations and, annotations, Dmitry Gutov, 2021/05/27