Hello.

When I want to use EUC-JP Hankaku Katakana character in 'listchars',
It doesn't work.

The 'listchars' accepts the EUC-JP Hankaku Katakana character (0x8e 0xNN),
because it has a single width on screen.
(dbcs_char2cells returns 1 for the Katakana, because the first byte is 0x8e)

But in display phase, the next 0xNN character is displayed WITHOUT 0x8e.
It messes up a vim screen / terminal emulator.

The 0x8e character should be displayed prior to the 0xNN.

Here is a simple patch to fix it.
I'm not sure that the patch is a good fix, but it works fine for me.

Regards,
kikuchan

--- screen.c    2009-12-05 04:45:05.000000000 +0900
+++ screen.c    2009-12-05 04:46:19.000000000 +0900
@@ -4620,8 +4620,10 @@
 #endif
            ScreenLines[off] = c;
 #ifdef FEAT_MBYTE
-           if (enc_dbcs == DBCS_JPNU)
+           if (enc_dbcs == DBCS_JPNU) {
+               if (((c >> 8) & 0xFF) == 0x8e) ScreenLines[off] = 0x8e;
                ScreenLines2[off] = mb_c & 0xff;
+           }
            else if (enc_utf8)
            {
                if (mb_utf8)

-- 
You received this message from the "vim_dev" maillist.
For more information, visit http://www.vim.org/maillist.php

Raspunde prin e-mail lui