[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#61283: 29.0.60; pcomplete-completions-at-point loses text properties
From: |
Eli Zaretskii |
Subject: |
bug#61283: 29.0.60; pcomplete-completions-at-point loses text properties, breaking pcomplete-from-help annotations |
Date: |
Thu, 18 May 2023 09:58:25 +0300 |
> Date: Wed, 17 May 2023 23:44:17 -0700
> Cc: liuhui1610@gmail.com, arstoffel@gmail.com, monnier@iro.umontreal.ca,
> 61283@debbugs.gnu.org
> From: Jim Porter <jporterbugs@gmail.com>
>
> > And why do we have to fix this in Emacs 29.1? This only affects
> > Eshell, AFAIU, is that true?
>
> It affects M-x shell for me too. Maybe I'm just doing something wrong
> though. I tried this:
>
> emacs -Q -f shell
> ls -<TAB>
>
> From that, I get completions like "--block-size=", which doesn't show
> the annotation. With the annotation, it should be "--block-size=SIZE".
>
> Currently, Pcomplete passes the annotation around by propertizing the
> first character of the candidate string. That ends up not working, since
> the completion code uses the characters in the buffer and concats the
> suffix from Pcomplete. So then the pcomplete-annotation almost always
> gets thrown out.
>
> I think a safe (but incomplete) fix would be to put the annotation on
> the *last* character of the candidate string. Then it usually wouldn't
> get thrown out. It won't work in *every* case, but it would only fail in
> rare edge cases.
Maybe that's better.
The other part of "safe" is whether completion--twq-all is called only
when these annotations are needed, or also in other cases. If the
latter, which use cases the proposed change could affect?
- bug#61283: 29.0.60; pcomplete-completions-at-point loses text properties, breaking pcomplete-from-help annotations, (continued)
- bug#61283: 29.0.60; pcomplete-completions-at-point loses text properties, breaking pcomplete-from-help annotations, Jim Porter, 2023/05/17
- bug#61283: 29.0.60; pcomplete-completions-at-point loses text properties, breaking pcomplete-from-help annotations, Daniel Mendler, 2023/05/17
- bug#61283: 29.0.60; pcomplete-completions-at-point loses text properties, breaking pcomplete-from-help annotations, Stefan Monnier, 2023/05/17
- bug#61283: 29.0.60; pcomplete-completions-at-point loses text properties, breaking pcomplete-from-help annotations, Stefan Monnier, 2023/05/17
- bug#61283: 29.0.60; pcomplete-completions-at-point loses text properties, breaking pcomplete-from-help annotations, Daniel Mendler, 2023/05/17
- bug#61283: 29.0.60; pcomplete-completions-at-point loses text properties, breaking pcomplete-from-help annotations, Eli Zaretskii, 2023/05/18
- bug#61283: 29.0.60; pcomplete-completions-at-point loses text properties, breaking pcomplete-from-help annotations, Jim Porter, 2023/05/18
- bug#61283: 29.0.60; pcomplete-completions-at-point loses text properties, breaking pcomplete-from-help annotations,
Eli Zaretskii <=
- bug#61283: 29.0.60; pcomplete-completions-at-point loses text properties, breaking pcomplete-from-help annotations, Daniel Mendler, 2023/05/18
- bug#61283: 29.0.60; pcomplete-completions-at-point loses text properties, breaking pcomplete-from-help annotations, Stefan Monnier, 2023/05/18
- bug#61283: 29.0.60; pcomplete-completions-at-point loses text properties, breaking pcomplete-from-help annotations, Jim Porter, 2023/05/18
- bug#61283: 29.0.60; pcomplete-completions-at-point loses text properties, breaking pcomplete-from-help annotations, Daniel Mendler, 2023/05/18
- bug#61283: 29.0.60; pcomplete-completions-at-point loses text properties, breaking pcomplete-from-help annotations, Stefan Monnier, 2023/05/18
- bug#61283: 29.0.60; pcomplete-completions-at-point loses text properties, breaking pcomplete-from-help annotations, Jim Porter, 2023/05/23
bug#61283: 29.0.60; pcomplete-completions-at-point loses text properties, breaking pcomplete-from-help annotations, Stefan Monnier, 2023/05/16
bug#61283: 29.0.60; pcomplete-completions-at-point loses text properties, breaking pcomplete-from-help annotations, Gregory Heytings, 2023/05/16