diff options
author | Bram Moolenaar <Bram@vim.org> | 2016-03-03 11:45:15 +0100 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2016-03-03 11:45:15 +0100 |
commit | 00ded43a5a85df57abb74f9e3a38a401f6fbd8fd (patch) | |
tree | bdee40329ca36d5b5b23881fd59fe800b279b0ab /src/ui.c | |
parent | 5fac467474376a844407cecc0ff481510ead221c (diff) | |
download | vim-git-00ded43a5a85df57abb74f9e3a38a401f6fbd8fd.tar.gz |
patch 7.4.1475v7.4.1475
Problem: When using hangulinput with utf-8 a CSI character is
misintepreted.
Solution: Convert CSI to K_CSI. (SungHyun Nam)
Diffstat (limited to 'src/ui.c')
-rw-r--r-- | src/ui.c | 16 |
1 files changed, 12 insertions, 4 deletions
@@ -1689,13 +1689,21 @@ push_raw_key(char_u *s, int len) tmpbuf = hangul_string_convert(s, &len); if (tmpbuf != NULL) + { s = tmpbuf; - while (len--) - inbuf[inbufcount++] = *s++; - - if (tmpbuf != NULL) + for (; len--; s++) + { + inbuf[inbufcount++] = *s; + if (*s == CSI) + { + /* Turn CSI into K_CSI. */ + inbuf[inbufcount++] = KS_EXTRA; + inbuf[inbufcount++] = (int)KE_CSI; + } + } vim_free(tmpbuf); + } } #endif |