From 41ebe41b62921142bb486e5f30bd2fa9f53f1700 Mon Sep 17 00:00:00 2001 From: zeertzjq Date: Sun, 12 Feb 2023 19:02:14 +0800 Subject: fix(ui-ext): force cursor update after resize in char-based UI Neither ui/screen.lua nor Neovim Qt keep cursor position after resizing. --- src/nvim/api/ui.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'src/nvim/api/ui.c') diff --git a/src/nvim/api/ui.c b/src/nvim/api/ui.c index 3ad625234c..8f5465db77 100644 --- a/src/nvim/api/ui.c +++ b/src/nvim/api/ui.c @@ -645,6 +645,8 @@ void remote_ui_grid_resize(UI *ui, Integer grid, Integer width, Integer height) Array args = data->call_buf; if (ui->ui_ext[kUILinegrid]) { ADD_C(args, INTEGER_OBJ(grid)); + } else { + data->client_col = -1; // force cursor update } ADD_C(args, INTEGER_OBJ(width)); ADD_C(args, INTEGER_OBJ(height)); -- cgit