debian7解决chrome中文乱码

1、安装wqy-zenhei字体

sudo apt-get install ttf-wqy-zenhei

2、修改系统字体配置文件/etc/fonts/conf.d/49-sansserif.conf

打开/etc/fonts/conf.d/49-sansserif.conf这个文件:

sudo gedit /etc/fonts/conf.d/49-sansserif.conf


然后修改倒数第四行的字体为WenQuanYi Zen Hei,如下:

<?xml version="1.0"?>
<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
<fontconfig>
<!--
If the font still has no generic name, add sans-serif
-->
<match target="pattern">
<test qual="all" name="family" compare="not_eq">
<string>sans-serif</string>
</test>
<test qual="all" name="family" compare="not_eq">
<string>serif</string>
</test>
<test qual="all" name="family" compare="not_eq">
<string>monospace</string>
</test>
<edit name="family" mode="append_last">
<string>WenQuanYi Zen Hei</string>
</edit>
</match>
</fontconfig>

3、重启chrome,OK!!!

你可能感兴趣的:(debian7解决chrome中文乱码)