Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: [BUG] region_highlight+=( "$start $end standout" ) doesn't work as expected



Maybe an automatic patch extraction got in the way - I meant the patch in
file 256-....diff.txt that's attached in the other email.

Niedz., 9.12.2018, 20:49: Peter Stephenson <p.w.stephenson@xxxxxxxxxxxx>
napisał(a):

> On Sun, 2018-12-09 at 20:20 +0100, Sebastian Gniazdowski wrote:
> > I think I've already resolved this in the patch in email "[PATCH] Make
> > 256 color codes be based on zle_highlight array, not on termcap".
>
> Ah, just those two lines as below?  I hadn't realised that was the same
> issue.  I'm happy to commit them on the basis you've got the most
> experience with this support, though I suppose I ought to give Oliver
> the chance to comment.
>
> Certainly termcap is a bit defective in this sort of support, so
> I can believe it.
>
> pws
>
> diff --git a/Src/prompt.c b/Src/prompt.c
> index 568bfc2a9..50c51e479 100644
> --- a/Src/prompt.c
> +++ b/Src/prompt.c
> @@ -2067,6 +2067,11 @@ set_colour_attribute(zattr atr, int fg_bg, int
> flags)
>      } else if (use_truecolor) {
>         ptr += sprintf(ptr, "8;2;%d;%d;%d", colour >> 16,
>                 (colour >> 8) & 0xff, colour & 0xff);
> +    } else if (use_truecolor) {
> +        ptr += sprintf(ptr, "8;2;%d;%d;%d", colour >> 16,
> +                (colour >> 8) & 0xff, colour & 0xff);
> +    } else if (colour > 7 && colour <= 255) {
> +        ptr += sprintf(ptr, "8;5;%d", colour);
>      } else
>         *ptr++ = colour + '0';
>      strcpy(ptr, fg_bg_sequences[fg_bg].end);
>
>


Messages sorted by: Reverse Date, Date, Thread, Author