分页: 1 / 1

请教:误删除 /etc/fonts/fonts.conf 怎么办?

发表于 : 2007-05-31 2:33
xiejs
弄了一晚上都没解决
我试过如下2种下操作,都不能解决问题:
1、sudo cp ~/fonts.conf /etc/fonts(提示~/fonts.conf 找不到)

2、sudo apt-get install --reinstall fontconfig提示如下:

xiejs@xiejs-desktop:/etc/fonts$ sudo apt-get install --reinstall fontconfig
正在读取软件包列表... 完成
正在分析软件包的依赖关系树
Reading state information... 完成
The following packages were automatically installed and are no longer required:
libxvidcore4 libmp4v2-0 libggi2 libgii1 libgii1-target-x libmpcdec3 liblame0
libfaac0
使用 'apt-get autoremove' 来删除它们。
共升级了 0 个软件包,新安装了 0 个软件包,共重新安装了 1 个软件包,要卸载 0 个软件包,有 0 个软件未被升级。
需要下载 0B/136kB 的软件包。
解压缩后会消耗掉 0B 的额外空间。
您希望继续执行吗?[Y/n]y
(正在读取数据库 ... 系统当前总共安装有 120141 个文件和目录。)
正预备替换 fontconfig 2.4.2-1ubuntu1 (使用 .../fontconfig_2.4.2-1ubuntu1_i386.deb) ...
Cleaning up font configuration of fontconfig...
Cleaning up category cid..
Cleaning up category truetype..
Cleaning up category type1..
Fontconfig error: Cannot load default config file
Fontconfig error: Cannot load default config file
正在解压缩将用于更替的包文件 fontconfig ...
正在设置 fontconfig (2.4.2-1ubuntu1) ...
Updating font configuration of fontconfig...
Cleaning up category cid..
Cleaning up category truetype..
Cleaning up category type1..
Updating category type1..
Updating category truetype..
Updating category cid..
Fontconfig error: Cannot load default config file
Fontconfig error: Cannot load default config file
Regenerating fonts cache... done.

希望高手指点

发表于 : 2007-05-31 3:23
jupengfei
1 查看~下有没有.fonts.conf文件,一般是没有的

2重新安装下几个字体,应该会重新写fonts.conf的

发表于 : 2007-05-31 12:48
xiejs
有没有什么命令从新生成fonts.conf

Re: 请教:误删除 /etc/fonts/fonts.conf 怎么办?

发表于 : 2020-08-25 10:57
hjjdebug
fonts.conf 属于 fontconfig-config 包, 只要重安装该包即可:
sudo apt-get install fontconfig-config