aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/edit.c
diff options
context:
space:
mode:
authorbfredl <bjorn.linse@gmail.com>2023-05-22 14:16:42 +0200
committerGitHub <noreply@github.com>2023-05-22 14:16:42 +0200
commit07883940b2294e0ab32fb58e6624d18d9dd1715a (patch)
tree2ce3b16ad7b6e96a4141a8502a3c667071ebf814 /src/nvim/edit.c
parentcb34d0ddd086141d6afcb9c48eae180abbeffecc (diff)
parent6eeb28845a930fbfe128dc3edc7969b0d9b2ed1c (diff)
downloadrneovim-07883940b2294e0ab32fb58e6624d18d9dd1715a.tar.gz
rneovim-07883940b2294e0ab32fb58e6624d18d9dd1715a.tar.bz2
rneovim-07883940b2294e0ab32fb58e6624d18d9dd1715a.zip
Merge pull request #20130 from bfredl/inline
feat(ui): inline virtual text
Diffstat (limited to 'src/nvim/edit.c')
-rw-r--r--src/nvim/edit.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/nvim/edit.c b/src/nvim/edit.c
index e3321a8b99..a25387f5a6 100644
--- a/src/nvim/edit.c
+++ b/src/nvim/edit.c
@@ -232,7 +232,7 @@ static void insert_enter(InsertState *s)
stop_insert_mode = false;
// need to position cursor again when on a TAB
- if (gchar_cursor() == TAB) {
+ if (gchar_cursor() == TAB || curbuf->b_virt_text_inline > 0) {
curwin->w_valid &= ~(VALID_WROW|VALID_WCOL|VALID_VIRTCOL);
}
@@ -3471,7 +3471,7 @@ static bool ins_esc(long *count, int cmdchar, bool nomove)
State = MODE_NORMAL;
may_trigger_modechanged();
// need to position cursor again when on a TAB
- if (gchar_cursor() == TAB) {
+ if (gchar_cursor() == TAB || curbuf->b_virt_text_inline > 0) {
curwin->w_valid &= ~(VALID_WROW|VALID_WCOL|VALID_VIRTCOL);
}