Sunday, June 26, 2011

Success with non-BMP Unicode characters on Windows?

Hi gurus,

Today somebody asked me about non-BMP support in Vim, and I took a
quick test. These are my steps:

1) Open Word, choose Insert > Symbol, select SimSun-ExtB as the font,
and insert a non-BMP character. I inserted U+2A6D6 in my test.
2) Open GVim, input "set guifontwide=SimSun-ExtB:h12", and then paste
the character from Word to GVim.
3) I can use "ga" to confirm the character is pasted, but nothing is shown.

Anybody has ideas about this?

I also had a quick check in gui_w32.c, and can see the surrogate
support is in gui_mch_draw_string for the UTF-8 encoding. ExtTextOutW
is used to output the character. I do use UTF-8 as encoding.

Best regards,

Yongwei

--
Wu Yongwei
URL: http://wyw.dcweb.cn/

--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

No comments: