以linux下安装宋体,黑体为例,介绍字体安装方法:
第一步、拷贝
把对应字体的的ttf文件拷到/usr/share/fonts/的任意目录下,假设宋体已拷贝到/usr/share/fonts/chinese/simsun,黑体已拷贝到/usr/share/fonts/chinese/simhei。
第二步、安装
安装宋体:
cd /usr/share/fonts/chinese/simsun
mkfontscale
mkfontdir
fc-cache -fv
安装黑体:
cd /usr/share/fonts/chinese/simhei
mkfontscale
mkfontdir
fc-cache -fv
第三步、使其生效
重启系统或使用source命令
reboot
source /etc/profile
转自:http://yuanrufeng.cn/post/151