1、(此步骤仅适合Ubuntu 8.04,对于Ubuntu其他版本,请对应找到firefox的安装路径)
代码: 全选
sudo rm /usr/lib/firefox-3.0b5/plugins/libflashplayer.so
2、打开firefox的 编辑->首选项,切换到 内容标签栏,在字体&颜色那一栏点击高级,打开一个对话框,在对话框的下面将默认字符编码那一栏改为:简体中文(GB2312).注释:删除原有的flash插件,其他版本的Ubuntu下的firefox请找到对应路径
3、关闭所有选项卡和firefox,按照快速设置指南的步骤重新安装一边flash插件
4、此时,你会发现打开浏览器后,flash的右键菜单恢复正常了,但是flash标题文字还是乱码,别急,往下看!
5、重要的一步,请仔细阅读步骤说明!
输入如下代码:
代码: 全选
cd /etc/fonts/conf.d/
代码: 全选
sudo cp 49-sansserif.conf 49-sansserif.conf_backup
代码: 全选
sudo rm /etc/fonts/conf.d/49-49-sansserif.conf #删除修改后的文件
sudo cp /etc/fonts/conf.d/49-49-sansserif.conf_backup /etc/fonts/conf.d/49-49-sansserif.conf #备份还原
输入如下指令:
代码: 全选
sudo gedit ./49-sansserif.conf
如上所示,将其中的第1、2、4个<string>后面的sans-serif或者serif用你自己系统中支持中文的字体的名字代替,注意字体名字的大小写<?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>sans-serif</string>
</edit>
</match>
</fontconfig>
比如:我的系统中安装了ZhunYuan.ttf,我则用ZhunYuan代替上述所说的字段:
我的系统修改后的文件如下所示(注意:个人根据自己的实际情况修改)
以上是我综合了论坛中的多种方法在不删除49-sansserif.conf文件的前提下解决flash菜单乱码的问题的方法,若有不正确的地方请指正,注意各Ubuntu版本修改的区别,以上是基于Ubuntu 8.04的系统修改的方法,其他版本修改方法我已有简短的说明!<?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>ZhunYuan</string>
</test>
<test qual="all" name="family" compare="not_eq">
<string>ZhunYuan</string>
</test>
<test qual="all" name="family" compare="not_eq">
<string>monospace</string>
</test>
<edit name="family" mode="append_last">
<string>ZhunYuan</string>
</edit>
</match>
</fontconfig>
对应我blog该篇文章的地址:点此