Mercurial > vim
comparison src/libvterm/src/unicode.c @ 20443:e02d45e302a2 v8.2.0776
patch 8.2.0776: libvterm code lags behind the upstream version
Commit: https://github.com/vim/vim/commit/e178ba36546ec7805020280910306331f1ef4ed0
Author: Bram Moolenaar <Bram@vim.org>
Date: Sun May 17 14:59:47 2020 +0200
patch 8.2.0776: libvterm code lags behind the upstream version
Problem: Libvterm code lags behind the upstream version.
Solution: Include revision 719.
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Sun, 17 May 2020 15:00:04 +0200 |
parents | 3be01cf0a632 |
children | a4652d7ec99f |
comparison
equal
deleted
inserted
replaced
20442:18447aca68fc | 20443:e02d45e302a2 |
---|---|
589 #endif | 589 #endif |
590 | 590 |
591 // ################################ | 591 // ################################ |
592 // ### The rest added by Paul Evans | 592 // ### The rest added by Paul Evans |
593 | 593 |
594 static const struct interval fullwidth[] = { | |
595 #include "fullwidth.inc" | |
596 }; | |
597 | |
594 INTERNAL int vterm_unicode_width(uint32_t codepoint) | 598 INTERNAL int vterm_unicode_width(uint32_t codepoint) |
595 { | 599 { |
600 if(bisearch(codepoint, fullwidth, sizeof(fullwidth) / sizeof(fullwidth[0]) - 1)) | |
601 return 2; | |
602 | |
596 return WCWIDTH_FUNCTION(codepoint); | 603 return WCWIDTH_FUNCTION(codepoint); |
597 } | 604 } |
598 | 605 |
599 INTERNAL int vterm_unicode_is_combining(uint32_t codepoint) | 606 INTERNAL int vterm_unicode_is_combining(uint32_t codepoint) |
600 { | 607 { |