From 0ddc03cf8c25458260c50faa833291994e756ee3 Mon Sep 17 00:00:00 2001 From: Eli Zaretskii Date: Mon, 17 Jan 2022 21:49:58 +0200 Subject: [PATCH] Fix minor inconsistencies in 'char-script-table' * admin/unidata/blocks.awk (name2alias): Map some obscure blocks to their native scripts, to follow Scripts.txt. * lisp/international/characters.el (char-script-table): Add few exceptions. * lisp/international/fontset.el (script-representative-chars): Remove scripts no longer used. --- admin/unidata/blocks.awk | 6 ++++-- lisp/international/characters.el | 4 ++++ lisp/international/fontset.el | 3 --- 3 files changed, 8 insertions(+), 5 deletions(-) diff --git a/admin/unidata/blocks.awk b/admin/unidata/blocks.awk index 48d8c873c7a..5f392b5ad35 100755 --- a/admin/unidata/blocks.awk +++ b/admin/unidata/blocks.awk @@ -98,7 +98,7 @@ function name2alias(name , w, w2) { else if (name ~ /arabic/) return "arabic" else if (name ~ /^greek/) return "greek" else if (name ~ /^coptic/) return "coptic" - else if (name ~ /cuneiform number/) return "cuneiform-numbers-and-punctuation" + else if (name ~ /cuneiform number/) return "cuneiform" else if (name ~ /cuneiform/) return "cuneiform" else if (name ~ /mathematical alphanumeric symbol/) return "mathematical" else if (name ~ /punctuation|mathematical|arrows|currency|superscript|small form variants|geometric|dingbats|enclosed|alchemical|pictograph|emoticon|transport/) return "symbol" @@ -113,9 +113,11 @@ function name2alias(name , w, w2) { else if (name ~/^(specials|tags)$/) return 0 else if (name ~ /linear b/) return "linear-b" else if (name ~ /aramaic/) return "aramaic" - else if (name ~ /rumi num/) return "rumi-number" + else if (name ~ /rumi num/) return "arabic" else if (name ~ /duployan|shorthand/) return "duployan-shorthand" else if (name ~ /sutton signwriting/) return "sutton-sign-writing" + else if (name ~ /sinhala archaic number/) return "sinhala" + else if (name ~ /tangut components/) return "tangut" sub(/^small /, "", name) sub(/ (extended|extensions*|supplement).*/, "", name) diff --git a/lisp/international/characters.el b/lisp/international/characters.el index 080e7898c47..3ff280f4802 100644 --- a/lisp/international/characters.el +++ b/lisp/international/characters.el @@ -1440,6 +1440,10 @@ Setup `char-width-table' appropriate for non-CJK language environment." (set-char-table-range char-script-table range 'tibetan)) 'tibetan) +;; Fix some exceptions that blocks.awk/Blocks.txt couldn't get right. +(set-char-table-range char-script-table '(#x2ea . #x2eb) 'bopomofo) +(set-char-table-range char-script-table #xab65 'greek) + ;;; Setting unicode-category-table. diff --git a/lisp/international/fontset.el b/lisp/international/fontset.el index a2e0838a427..cf825140955 100644 --- a/lisp/international/fontset.el +++ b/lisp/international/fontset.el @@ -231,7 +231,6 @@ (elymaic #x10FE0) (old-uyghur #x10F70) (mahajani #x11150) - (sinhala-archaic-number #x111E1) (khojki #x11200) (khudawadi #x112B0) (grantha #x11305) @@ -253,7 +252,6 @@ (gunjala-gondi #x11D60) (makasar #x11EE0) (cuneiform #x12000) - (cuneiform-numbers-and-punctuation #x12400) (cypro-minoan #x12F90) (egyptian #x13000) (mro #x16A40) @@ -262,7 +260,6 @@ (pahawh-hmong #x16B11) (medefaidrin #x16E40) (tangut #x17000) - (tangut-components #x18800) (khitan-small-script #x18B00) (nushu #x1B170) (duployan-shorthand #x1BC20) -- 2.39.2