In ubuntu10.04, geditopen windows‑based TXT file garbled

Source: Internet
Author: User
Environment: Ubuntu10.04 + Gnome has actually solved this problem by default in Ubuntu9.10. I did not expect this problem to occur again after the upgrade of 10.04. This is because gedit uses an encoding matching list. Only the encoding in this list is matched. Encoding not in this list is garbled. All you need to do is add GB18030 to the matching list. Follow these steps to make your gedit correctly display the Chinese encoding file. 1. Final

Environment: Ubuntu 10.04 + Gnome

In fact, this problem has been solved by default in Ubuntu 9.10. I did not expect this problem to occur again after upgrading 10.04.

This is because gedit uses an encoding matching list. Only the encoding in this list is matched. Encoding not in this list is garbled. All you need to do is add GB18030 to the matching list.

Follow these steps to make your gedit correctly display the Chinese encoding file.

1. Enter "gconf-editor" in the terminal, and press the Enter key to open "configuration editor ".

2. Expand the tree node on the left, find the/apps/gedit-2/preferences/encodings node, and click it.

3. Double-click the auto_detected key on the right to open the "Edit key" dialog box.

4. Click "add" on the right of the list, enter "GB18030", and click "OK.

5. A "GB18030" is added at the bottom of the list ".

Note: Some methods require you to click it and click the "up" button on the right until "GB18030" is at the top of the list. In fact, this is not necessary. If you do so, in Ubuntu10.04 (not verified in other versions), gedit cannot open blank files. Utf8 must be at the top.

6. Click OK to close the configuration editor.

Now, gedit should be able to smoothly open the GB18030 encoded text file.

Ps: if you are not at ease, you can add GBK and GB2312 encoding.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.