lxgw / LxgwWenKai

An open-source Chinese font derived from Fontworks' Klee One. 一款开源中文字体,基于 FONTWORKS 出品字体 Klee One 衍生。
https://lxgw.github.io/2021/01/28/Klee-Simpchin/
SIL Open Font License 1.1
17.34k stars 503 forks source link

cmap 似乎损坏了 #141

Open Mistsink opened 2 months ago

Mistsink commented 2 months ago

使用python程序使用该字体是需要查询cmap来检查是否支持某个字符,但是检测时发现cmap损坏了,程序一直运行错误。 下面的程序结果验证了cmap的损坏情况:

$ python -m ots LXGWWenKai-Regular.ttf 
ERROR: cmap: Failed to read segment start range 441
ERROR: cmap: Failed to parse format 4 cmap subtable 0
ERROR: cmap: Failed to parse table
Failed to sanitize file!
spencer246 commented 1 month ago

fontTools.ttLib cannot parse the cmap table as well.

Interestingly, fontTools has no problem in parsing the TC version of the font, although these fonts are released on the same day.

lxgw commented 1 month ago

后续会像 TC 版那样优化构建流程,届时可能会解决这个问题。

Mistsink commented 1 month ago

非常感谢,那修好了再close这个issue吧,期待您的消息!