Mirror of the Vim source from https://github.com/vim/vim
Révision | e351146e7974acd49f2e9aab749f31670b2c6044 (tree) |
---|---|
l'heure | 2007-09-18 05:39:42 |
Auteur | vimboss |
Commiter | vimboss |
updated for version 7.1-116
@@ -2305,9 +2305,11 @@ | ||
2305 | 2305 | prev_c = u8c; |
2306 | 2306 | #endif |
2307 | 2307 | /* Non-BMP character: display as ? or fullwidth ?. */ |
2308 | +#ifdef UNICODE16 | |
2308 | 2309 | if (u8c >= 0x10000) |
2309 | 2310 | ScreenLinesUC[idx] = (cells == 2) ? 0xff1f : (int)'?'; |
2310 | 2311 | else |
2312 | +#endif | |
2311 | 2313 | ScreenLinesUC[idx] = u8c; |
2312 | 2314 | for (i = 0; i < Screen_mco; ++i) |
2313 | 2315 | { |
@@ -3678,13 +3680,18 @@ | ||
3678 | 3680 | if ((mb_l == 1 && c >= 0x80) |
3679 | 3681 | || (mb_l >= 1 && mb_c == 0) |
3680 | 3682 | || (mb_l > 1 && (!vim_isprintc(mb_c) |
3681 | - || mb_c >= 0x10000))) | |
3683 | +# ifdef UNICODE16 | |
3684 | + || mb_c >= 0x10000 | |
3685 | +# endif | |
3686 | + ))) | |
3682 | 3687 | { |
3683 | 3688 | /* |
3684 | 3689 | * Illegal UTF-8 byte: display as <xx>. |
3685 | 3690 | * Non-BMP character : display as ? or fullwidth ?. |
3686 | 3691 | */ |
3692 | +# ifdef UNICODE16 | |
3687 | 3693 | if (mb_c < 0x10000) |
3694 | +# endif | |
3688 | 3695 | { |
3689 | 3696 | transchar_hex(extra, mb_c); |
3690 | 3697 | # ifdef FEAT_RIGHTLEFT |
@@ -3692,11 +3699,13 @@ | ||
3692 | 3699 | rl_mirror(extra); |
3693 | 3700 | # endif |
3694 | 3701 | } |
3702 | +# ifdef UNICODE16 | |
3695 | 3703 | else if (utf_char2cells(mb_c) != 2) |
3696 | 3704 | STRCPY(extra, "?"); |
3697 | 3705 | else |
3698 | 3706 | /* 0xff1f in UTF-8: full-width '?' */ |
3699 | 3707 | STRCPY(extra, "\357\274\237"); |
3708 | +# endif | |
3700 | 3709 | |
3701 | 3710 | p_extra = extra; |
3702 | 3711 | c = *p_extra; |
@@ -6245,6 +6254,7 @@ | ||
6245 | 6254 | else |
6246 | 6255 | u8c = utfc_ptr2char(ptr, u8cc); |
6247 | 6256 | mbyte_cells = utf_char2cells(u8c); |
6257 | +# ifdef UNICODE16 | |
6248 | 6258 | /* Non-BMP character: display as ? or fullwidth ?. */ |
6249 | 6259 | if (u8c >= 0x10000) |
6250 | 6260 | { |
@@ -6252,6 +6262,7 @@ | ||
6252 | 6262 | if (attr == 0) |
6253 | 6263 | attr = hl_attr(HLF_8); |
6254 | 6264 | } |
6265 | +# endif | |
6255 | 6266 | # ifdef FEAT_ARABIC |
6256 | 6267 | if (p_arshape && !p_tbidi && ARABIC_CHAR(u8c)) |
6257 | 6268 | { |
@@ -667,6 +667,8 @@ | ||
667 | 667 | static int included_patches[] = |
668 | 668 | { /* Add new patch number below this line */ |
669 | 669 | /**/ |
670 | + 116, | |
671 | +/**/ | |
670 | 672 | 115, |
671 | 673 | /**/ |
672 | 674 | 114, |