Installation of Chinese fonts in Linux

Source: Internet
Author: User


1. Disable the xfs server first.
Run the Setup command to stop the xfs running with the system in the service item. The reason why xfs server is disabled is that xfs will automatically update the fonts. dir file in the font directory, thus affecting our modifications.
2. Copy the selected font to the relevant directory.
Simsun. ttf is generally used as the basic font (it is said that the font is the most refined Chinese font ). Copy these fonts to/usr/share/fonts/default/TrueType to generate the fonts. dir and fonts. scale files.
Run ttmkfdir> fonts. dir in the font directory. Edit the fonts. dir file and add two lines under simsun. ttf-misc-SimSun-medium-r-normal -- 0-0-0-0-p-0-ascii-0:
Simsun. ttf-misc-SimSun-medium-r-normal -- 0-0-0-0
P-0-gb2312.1980-0
Simsun. ttf-misc-SimSun-medium-r-normal -- 0-0-0-0
P-0-gbk-0
Also, change the number in the first line of the file and copy fonts. dir to fonts. scale.
3. Set the font path and load the server
Edit the/etc/X11/XF86Config-4 file (# represents the comment line ).
Section "Files"
# FontPath "unix //: 7100"
FontPath "/usr/X11R6/lib/X11/fonts/misc: unscaled"
FontPath "/usr/X11R6/lib/X11/fonts/75 dpi: unscaled"
FontPath "/usr/X11R6/lib/X11/fonts/misc"
FontPath "/usr/X11R6/lib/X11/fonts/Type1"
FontPath "/usr/X11R6/lib/X11/fonts/Speedo"
FontPath "/usr/X11R6/lib/X11/fonts/75 dpi"
FontPath "/usr/share/fonts/default/TrueType"
EndSection
Section "Module"
......
Load "xtt"
......
EndSection
Restart and set the font to simsun in the control center. OK.

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.