diff options
| author | Oliver Kiddle <opk@zsh.org> | 2023-01-10 21:17:24 +0100 |
|---|---|---|
| committer | Oliver Kiddle <opk@zsh.org> | 2023-01-10 21:17:24 +0100 |
| commit | b513ca21c8aff35c76bb9b1cb30a9644e936833a (patch) | |
| tree | 46b0212b0e6835219286c5fc4ef39c9610113335 /Src/Zle | |
| parent | 51291: support for highlighting ellipses in the line editor (diff) | |
| download | zsh-b513ca21c8aff35c76bb9b1cb30a9644e936833a.tar zsh-b513ca21c8aff35c76bb9b1cb30a9644e936833a.tar.gz zsh-b513ca21c8aff35c76bb9b1cb30a9644e936833a.tar.bz2 zsh-b513ca21c8aff35c76bb9b1cb30a9644e936833a.tar.lz zsh-b513ca21c8aff35c76bb9b1cb30a9644e936833a.tar.xz zsh-b513ca21c8aff35c76bb9b1cb30a9644e936833a.tar.zst zsh-b513ca21c8aff35c76bb9b1cb30a9644e936833a.zip | |
51292: fix dynamic updates of region_highlight to account for PREDISPLAY
Diffstat (limited to 'Src/Zle')
| -rw-r--r-- | Src/Zle/zle_utils.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/Src/Zle/zle_utils.c b/Src/Zle/zle_utils.c index 1a580a9e6..45a82dd5e 100644 --- a/Src/Zle/zle_utils.c +++ b/Src/Zle/zle_utils.c @@ -866,13 +866,13 @@ shiftchars(int to, int cnt) if (rhp->start_meta - sub > to + cnt) rhp->start_meta -= cnt; else - rhp->start_meta = to; + rhp->start_meta = to + sub; } if (rhp->end_meta - sub > to) { if (rhp->end_meta - sub > to + cnt) rhp->end_meta -= cnt; else - rhp->end_meta = to; + rhp->end_meta = to + sub; } } } @@ -896,13 +896,13 @@ shiftchars(int to, int cnt) if (rhp->start - sub > to + cnt) rhp->start -= cnt; else - rhp->start = to; + rhp->start = to + sub; } if (rhp->end - sub > to) { if (rhp->end - sub > to + cnt) rhp->end -= cnt; else - rhp->end = to; + rhp->end = to + sub; } } } |
