emacs-devel
[Top][All Lists]
Advanced

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

Re: BIKESHED: completion faces


From: Eli Zaretskii
Subject: Re: BIKESHED: completion faces
Date: Fri, 08 Nov 2019 16:02:36 +0200

> From: João Távora <address@hidden>
> Cc: address@hidden,  address@hidden,  address@hidden,
>   address@hidden
> Date: Fri, 08 Nov 2019 10:15:02 +0000
> 
> It's pretty simple.  In that mail I made three statements, you objected
> to the second, which lead me to think that you agree with the other
> two.

I'm sorry for causing you to misunderstand what I was saying.

> 1. Alias 'completions-first-difference' to 'completion-emphasis'
> 2. Alias 'completions-common-part' to 'completion-secondary-emphasis'
> 3. Make 'flex' use only completion-emphasis to highlight the
>    pattern in the candidates.  

We are miscommunicating.  These faces aren't flex-specific, and I was
talking about their names in the context of any completion style,
including, but not limited to flex.

In any case, I consider both completion-emphasis and
completion-secondary-emphasis to be sub-optimal names, because they
say nothing at all regarding what is being emphasized.

> >>   fabrobazor
> >>   ^   ^   ^
> >>   `---`---`----- I want these bold by default in the future
> >> 
> >> no change to the 'basic/prefix' completion.
> >
> > I understand that you want to highlight both f, o, o, and r, but the
> > latter with a different face.  If my understanding is incorrect,
> 
> It is incorrect indeed: 'r' is should have the same face as 'a' or 'b'.

Did I say that _only_ r will be highlighted with that face?

I'm okay with highlighting a and b as well in this example, provided
that typing "faoo" will include "fabrobazor" in the results.

However, please note that r is somewhat different from a and b,
because to type r I don't need to move point, I need just to type the
letter, whereas the other two require me to use cursor motion commands
first.  Not sure if this difference is significant enough to justify
yet another face (and another round of bikeshedding).

> > then what will the other face be used for?
> 
> Nothing.  I don't (yet) see 'flex' as needing secondary kinds of
> emphasis.

What about styles other than flex?

> > I understand that what I called completions-match-emphasis will
> > highlight f, o, and o -- the characters that were in the string typed
> > by the user.  These are currently not highlighted at all.  I also
> > understand that there will be another face, the one we currently call
> > completions-first-difference (and you want another name for it), which
> > will highlight r in this example.
> 
> No, that is again incorrect.  That "other face" is already the most
> important one of the two.  Again, I repeat, the one we currently call
> 'completions-first-difference', is currently the bold one, by default.
> I want to change its name (to 'completion-emphasis' in my proposal) so
> that it makes sense for flex to apply it to flex's most important parts,
> which, in the above example, are the three characters 'f', 'o' and 'o'
> and no other characters.

That would mean this face is used inconsistently: in basic and other
similar styles it highlights the character(s) that narrow(s) the
selection of candidates, while in flex they will highlight the
characters already typed by the user.  Is that correct?  If so, I
object to this inconsistency.



reply via email to

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