aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorLewis Russell <lewis6991@gmail.com>2022-10-14 11:49:57 +0100
committerLewis Russell <lewis6991@gmail.com>2022-10-14 13:03:03 +0100
commit546b294e74ac10d0a5e1216dd530fc96bdc66f29 (patch)
treeb43aaac69171cb60d9c16c2d677c1088baf90fe6 /src
parent9931db2e3fa43ed02e1b0bc6f167ed5398fa6369 (diff)
downloadrneovim-546b294e74ac10d0a5e1216dd530fc96bdc66f29.tar.gz
rneovim-546b294e74ac10d0a5e1216dd530fc96bdc66f29.tar.bz2
rneovim-546b294e74ac10d0a5e1216dd530fc96bdc66f29.zip
fix(decoration): redraw correctly when re-using ids
00cfc1d (from #20249) reduced the amount of unnecessary redraws. This surfaced an issue where if and extmark with a specific ID is repositioned to a different row, the decorations from the old row were not redrawn and removed. This change fixes that by redrawing the old row.
Diffstat (limited to 'src')
-rw-r--r--src/nvim/extmark.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/nvim/extmark.c b/src/nvim/extmark.c
index 176ad0d5c8..df87cc8ab6 100644
--- a/src/nvim/extmark.c
+++ b/src/nvim/extmark.c
@@ -112,6 +112,7 @@ void extmark_set(buf_T *buf, uint32_t ns_id, uint32_t *idp, int row, colnr_T col
marktree_revise(buf->b_marktree, itr, decor_level, old_mark);
goto revised;
}
+ decor_remove(buf, old_mark.pos.row, old_mark.pos.row, old_mark.decor_full);
marktree_del_itr(buf->b_marktree, itr, false);
}
} else {