![阿萨姆语字体在 ubuntu 14 或 16 中显示不正确](https://linux22.com/image/885016/%E9%98%BF%E8%90%A8%E5%A7%86%E8%AF%AD%E5%AD%97%E4%BD%93%E5%9C%A8%20ubuntu%2014%20%E6%88%96%2016%20%E4%B8%AD%E6%98%BE%E7%A4%BA%E4%B8%8D%E6%AD%A3%E7%A1%AE.png)
答案1
这是 fontconfig 在我的计算机上提供的优先顺序:
$ fc-match -a | grep -i lohit
Lohit-Bengali.ttf: "Lohit Bengali" "Regular"
Lohit-Gujarati.ttf: "Lohit Gujarati" "Regular"
Lohit-Punjabi.ttf: "Lohit Punjabi" "Regular"
Lohit-Assamese.ttf: "Lohit Assamese" "Regular"
Lohit-Devanagari.ttf: "Lohit Devanagari" "Regular"
我添加了这个配置文件来提高阿萨姆语的优先级:
$ cat ~/.config/fontconfig/conf.d/90-prefer-assamese.conf
<?xml version="1.0"?>
<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
<fontconfig>
<alias>
<family>serif</family>
<prefer>
<family>Lohit Assamese</family>
</prefer>
</alias>
<alias>
<family>sans-serif</family>
<prefer>
<family>Lohit Assamese</family>
</prefer>
</alias>
<alias>
<family>monospace</family>
<prefer>
<family>Lohit Assamese</family>
</prefer>
</alias>
</fontconfig>
结果是:
$ fc-match -a | grep -i lohit
Lohit-Assamese.ttf: "Lohit Assamese" "Regular"
Lohit-Bengali.ttf: "Lohit Bengali" "Regular"
Lohit-Gujarati.ttf: "Lohit Gujarati" "Regular"
Lohit-Punjabi.ttf: "Lohit Punjabi" "Regular"
Lohit-Devanagari.ttf: "Lohit Devanagari" "Regular"