diff options
| author | Oliver Kiddle <opk@zsh.org> | 2025-01-27 23:50:27 +0100 |
|---|---|---|
| committer | Oliver Kiddle <opk@zsh.org> | 2025-01-27 23:50:27 +0100 |
| commit | 4f3d69e2a0bc6b4d98a4aa3ef37ebea44cbda51f (patch) | |
| tree | 37f4760f69718d227bba50f1d49f701cf59aceb6 /Src/Modules | |
| parent | github #128: Updated completion for neovim (diff) | |
| download | zsh-4f3d69e2a0bc6b4d98a4aa3ef37ebea44cbda51f.tar zsh-4f3d69e2a0bc6b4d98a4aa3ef37ebea44cbda51f.tar.gz zsh-4f3d69e2a0bc6b4d98a4aa3ef37ebea44cbda51f.tar.bz2 zsh-4f3d69e2a0bc6b4d98a4aa3ef37ebea44cbda51f.tar.lz zsh-4f3d69e2a0bc6b4d98a4aa3ef37ebea44cbda51f.tar.xz zsh-4f3d69e2a0bc6b4d98a4aa3ef37ebea44cbda51f.tar.zst zsh-4f3d69e2a0bc6b4d98a4aa3ef37ebea44cbda51f.zip | |
53329: adapt .zle.sgr for CSI sequences that use : instead of ;
Diffstat (limited to 'Src/Modules')
| -rw-r--r-- | Src/Modules/hlgroup.c | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/Src/Modules/hlgroup.c b/Src/Modules/hlgroup.c index 082762623..6c5a4bec4 100644 --- a/Src/Modules/hlgroup.c +++ b/Src/Modules/hlgroup.c @@ -50,9 +50,14 @@ convertattr(char *attrstr, int sgr) char *c = s, *t = s - 1; while (c[0] == '\033' && c[1] == '[') { - c += 2; - while (isdigit(*c) || *c == ';') - *++t = *c++; + for (c += 2; ; c++) { + if (isdigit(*c)) + *++t = *c; + else if (*c == ';' || *c == ':') + *++t = ';'; + else + break; + } t++; if (*c != 'm') break; |
