summaryrefslogtreecommitdiff
path: root/src/screen.c
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2016-10-02 23:09:31 +0200
committerBram Moolenaar <Bram@vim.org>2016-10-02 23:09:31 +0200
commit84dbd494dca599ecff05b2c2279d402c12e6d197 (patch)
treefaca7727d15b5facdd5d67a4580977a846d25c14 /src/screen.c
parent6100d02aab7c8294b581cb299250eea164b50e9d (diff)
downloadvim-git-84dbd494dca599ecff05b2c2279d402c12e6d197.tar.gz
patch 8.0.0021v8.0.0021
Problem: In the GUI when redrawing the cursor it may be on the second half of a double byte character. Solution: Correct the cursor column. (Yasuhiro Matsumoto)
Diffstat (limited to 'src/screen.c')
-rw-r--r--src/screen.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/screen.c b/src/screen.c
index 4604ec728..5ebca0980 100644
--- a/src/screen.c
+++ b/src/screen.c
@@ -765,6 +765,9 @@ update_screen(int type)
* uses that. */
gui.col = gui_cursor_col;
gui.row = gui_cursor_row;
+# ifdef FEAT_MBYTE
+ gui.col = mb_fix_col(gui.col, gui.row);
+# endif
gui_update_cursor(FALSE, FALSE);
screen_cur_col = gui.col;
screen_cur_row = gui.row;