Solution to failure to display Chinese Characters in Ubuntu/Linux PDF files or square in Chinese

Source: Internet
Author: User

 

Ubuntu1004. Some PDF files cannot display Chinese characters. The solution is as follows:

 

1. First install the font

A.Sudo apt-Get install xpdf-Chinese-simplified;

B. sudo apt-Get install xpdf-Chinese-traditional.

 

 

2. Open the PDF file after installation. Chinese characters are not displayed. Continue to install the file:

C.Sudo apt-Get install poppler-Data

 

 

At this time, the PDF file can display Chinese characters, but the problem arises again. In some files, Chinese characters are square characters. What should I do?

 

The following is a solution provided by others. It has been tried and is feasible:

 

Some Chinese PDF files in xpdf are displayed in squares. After reading a lot of webpages, the font problem is found. You can try to change the following file.

Sudo gedit/etc/fonts/CONF. d/69-language-selector-zh-cn.conf

Some Chinese PDF files are displayed in squares, you can change the first item of the second large block in the above file to Chinese (<string> ar PL uming CN <string> if not, you can change it to <string> wenquanyi Zen Hei </string> ), you can solve the problem:

 

 

# The following is my 69-language-selector-zh-cn.conf file <br/> <fontconfig> <br/> <match target = "pattern"> <br/> <Test qual = "any" name =" family "> <br/> <string> serif </string> <br/> </test> <br/> <edit name =" family "mode =" prepend "binding = "strong"> <br/> <string> Microsoft yahei </string> <br/> <string> ar PL uming CN </string> <br/> <string> ar PL shanheisun uni </string> <br/> <string> wenquanyi bitmap song </string> <br/> <string> bitstream Vera serif </string> <br/> <string> dejavu serif </string> <br/> <string> ar PL Ukai CN </string> <br/> <string> ar PL zenkai uni </string> <br/> </Edit> <br/> </match> <br/> <match target = "pattern"> <br/> <Test qual = "any" name = "Family"> <br/> <string> sans-serif </string> <br/> </test> <br/> <edit name = "family" mode =" prepend "binding =" strong "> <br/> <string> ar PL uming CN <string> <br/> <string> Microsoft yahei </string> <br/> <string> bitstream Vera sans </string> <br/> <string> dejavu sans </string> <br/> <string> wenquanyi Zen Hei </string> <br/> <string> ar PL uming CN </string> <br/> <string> ar PL shanheisun uni </string> <br/> <string> wenquanyi bitmap song </string> <br/> <string> ar PL Ukai CN </string> <br/> <string> ar PL zenkai uni </string> <br/> </Edit> <br /> </match> <br/> <match target = "pattern"> <br/> <Test qual = "any" name = "family"> <br/> <string> monospace </string> <br/> </test> <br/> <edit name = "family" mode = "prepend" binding = "strong"> <br/> <string> Microsoft yahei </string> <br/> <string> bitstream Vera sans mono </string> <br/> <string> dejavu sans mono </string> <br/> <string> wenquanyi Zen Hei </string> <br/> <string> ar PL uming CN </string> <br/> <string> ar PL shanheisun uni </string> <br/> <string> wenquanyi bitmap song </string> <br/> <string> ar PL Ukai CN </string> <br/> <string> ar PL zenkai uni </string> <br/> </Edit> <br/> </match> <br/> </fontconfig>

 

 

 

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.