diff src/mbyte.c @ 12650:f58755eb453e v8.0.1203

patch 8.0.1203: terminal window mistreats composing characters commit https://github.com/vim/vim/commit/6daeef1933be68055aabe1d55f8467d46a707753 Author: Bram Moolenaar <Bram@vim.org> Date: Sun Oct 15 22:56:49 2017 +0200 patch 8.0.1203: terminal window mistreats composing characters Problem: Terminal window mistreats composing characters. Solution: Count composing characters with the base character. (Ozaki Kiichi, closes #2195)
author Christian Brabandt <cb@256bit.org>
date Sun, 15 Oct 2017 23:00:04 +0200
parents aa3f6d093f4b
children 351cf7c67bbe
line wrap: on
line diff
--- a/src/mbyte.c
+++ b/src/mbyte.c
@@ -1402,6 +1402,8 @@ static struct interval ambiguous[] =
     int
 utf_uint2cells(UINT32_T c)
 {
+    if (c >= 0x100 && utf_iscomposing((int)c))
+	return 0;
     return utf_char2cells((int)c);
 }
 #endif