编码格式不同,fedora打开windows下的文本文件经常出现乱码。在终端执行命令,或安装dconf-editor可以解决
终端输入命令:
$ gsettings set org.gnome.gedit.preferences.encodings auto-detected “[‘UTF-8’, ‘GB18030’, ‘GB2312’, ‘GBK’, ‘ISO-8859-15′,’BIG5’, ‘CURRENT’, ‘UTF-16’]”
$ gsettings set org.gnome.gedit.preferences.encodings shown-in-menu “[‘UTF-8’, ‘GB18030’, ‘GB2312’, ‘GBK’,’ISO-8859-15′, ‘BIG5’, ‘CURRENT’, ‘UTF-16’]”
安装 dconf-editor
yum install dconf-editor
解决 gedit 中文乱码
打开 dconf-editor
找到 org –> gonme –> gedit –> preferences –> encoding
在 auto-detected 选项中添加 GB2312、GB18030 编码