Implement support for emoji skin tone modifiers

Fixes #787
This commit is contained in:
Kovid Goyal
2018-08-04 10:06:25 +05:30
parent 28447d3389
commit 000c1cf306
8 changed files with 38 additions and 14 deletions

12
kitty/wcwidth-std.h generated
View File

@@ -1,4 +1,4 @@
// unicode data, built from the unicode standard on: 2018-06-14
// unicode data, built from the unicode standard on: 2018-08-04
// see gen-wcwidth.py
#pragma once
#include "data-types.h"
@@ -8,7 +8,7 @@ START_ALLOW_CASE_RANGE
static int
wcwidth_std(int32_t code) {
switch(code) {
// Marks (2234 codepoints) {{{
// Marks (2239 codepoints) {{{
case 0x0:
return 0;
case 0x300 ... 0x36f:
@@ -559,6 +559,8 @@ wcwidth_std(int32_t code) {
return 0;
case 0x1e944 ... 0x1e94a:
return 0;
case 0x1f3fb ... 0x1f3ff:
return 0;
case 0xe0100 ... 0xe01ef:
return 0;
// }}}
@@ -1209,7 +1211,7 @@ wcwidth_std(int32_t code) {
return -2;
// }}}
// East Asian double width (181796 codepoints) {{{
// East Asian double width (181791 codepoints) {{{
case 0x1100 ... 0x115f:
return 2;
case 0x231a ... 0x231b:
@@ -1386,7 +1388,9 @@ wcwidth_std(int32_t code) {
return 2;
case 0x1f3f4:
return 2;
case 0x1f3f8 ... 0x1f43e:
case 0x1f3f8 ... 0x1f3fa:
return 2;
case 0x1f400 ... 0x1f43e:
return 2;
case 0x1f440:
return 2;