diff options
author | Oliver Kiddle <opk@zsh.org> | 2023-01-10 21:06:55 +0100 |
---|---|---|
committer | Oliver Kiddle <opk@zsh.org> | 2023-01-10 21:06:55 +0100 |
commit | cc672f1c3bfa9cdf4bbf100d85439340a479cb6b (patch) | |
tree | 1dd3d3c01c49c388c7ce02a8cc1abd43ab368bbd | |
parent | 9d99a01367e85dc3d9cd8e711d78dc1cec6f018b (diff) | |
download | zsh-cc672f1c3bfa9cdf4bbf100d85439340a479cb6b.tar.gz zsh-cc672f1c3bfa9cdf4bbf100d85439340a479cb6b.zip |
51289: don't disable non-colour attributes in prompts for SINGLE_LINE_ZLE and remove superfluous extra escapes to disable attributes
-rw-r--r-- | ChangeLog | 4 | ||||
-rw-r--r-- | Src/Zle/zle_refresh.c | 2 | ||||
-rw-r--r-- | Src/prompt.c | 3 |
3 files changed, 5 insertions, 4 deletions
@@ -1,5 +1,9 @@ 2023-01-10 Oliver Kiddle <opk@zsh.org> + * 51289: Src/Zle/zle_refresh.c, Src/prompt.c: don't disable + non-colour attributes in prompts for SINGLE_LINE_ZLE and remove + superfluous extra escapes to disable attributes + * 51281: Src/Zle/zle_main.c, Src/Zle/zle_refresh.c, Src/zsh.h: keep track of attributes left on at the end of left and right prompts and reapply them explicitly as appropriate diff --git a/Src/Zle/zle_refresh.c b/Src/Zle/zle_refresh.c index ab84a1376..8949a851c 100644 --- a/Src/Zle/zle_refresh.c +++ b/Src/Zle/zle_refresh.c @@ -1107,8 +1107,6 @@ zrefresh(void) #endif /* we probably should only have explicitly set attributes */ tsetcap(TCALLATTRSOFF, 0); - tsetcap(TCSTANDOUTEND, 0); - tsetcap(TCUNDERLINEEND, 0); txtcurrentattrs = txtpendingattrs = txtunknownattrs = 0; if (trashedzle && !clearflag) diff --git a/Src/prompt.c b/Src/prompt.c index 488a90d09..4f29a6728 100644 --- a/Src/prompt.c +++ b/Src/prompt.c @@ -1004,8 +1004,7 @@ stradd(char *d) mod_export void tsetcap(int cap, int flags) { - if (tccan(cap) && !isset(SINGLELINEZLE) && - !(termflags & (TERM_NOUP|TERM_BAD|TERM_UNKNOWN))) { + if (tccan(cap) && !(termflags & (TERM_NOUP|TERM_BAD|TERM_UNKNOWN))) { switch (flags) { case TSC_RAW: tputs(tcstr[cap], 1, putraw); |