diff options
author | Bram Moolenaar <Bram@vim.org> | 2010-07-18 15:31:08 +0200 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2010-07-18 15:31:08 +0200 |
commit | 72597a57b526a8df333e77ef8a837b595baa18c7 (patch) | |
tree | 8b635e3dbb23f92a0a73b730cc79bc538c0b61b9 /src/gui.c | |
parent | 9855d6b3610b3ae46a5522b9f8e1e4b521759e83 (diff) | |
download | vim-72597a57b526a8df333e77ef8a837b595baa18c7.zip |
Added strwidth() and strchars() functions.
Diffstat (limited to 'src/gui.c')
-rw-r--r-- | src/gui.c | 7 |
1 files changed, 1 insertions, 6 deletions
@@ -2329,14 +2329,9 @@ gui_outstr_nowrap(s, len, flags, fg, bg, back) # ifdef FEAT_MBYTE if (enc_dbcs == DBCS_JPNU) { - int clen = 0; - int i; - /* Get the length in display cells, this can be different from the * number of bytes for "euc-jp". */ - for (i = 0; i < len; i += (*mb_ptr2len)(s + i)) - clen += (*mb_ptr2cells)(s + i); - len = clen; + len = mb_string2cells(s, len); } # endif } |