LinuxQuestions.org
Register a domain and help support LQ
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices

Reply
 
Search this Thread
Old 06-14-2004, 02:59 AM   #1
carboncopy
Senior Member
 
Registered: Jan 2003
Location: Malaysia
Distribution: Fedora Core, Slackware, Mac OS X, Debian, OpenSUSE
Posts: 1,210
Blog Entries: 4

Rep: Reputation: 45
chinese character input and display -- need help


Hi!

I need to set up a Slackware system with chinese character input and display capable. I have no idea how to go about it. Please help me.

Thanks in advance.
 
Old 06-14-2004, 03:45 AM   #2
keefaz
Senior Member
 
Registered: Mar 2004
Distribution: Slackware
Posts: 4,546

Rep: Reputation: 119Reputation: 119
first go to /usr/share/kbd/consolefonts and figure out what is the china font for console, then modify /etc/rc.d/rc.font to suit it.

Go to /etc/profile.d, edit lang.sh and lang.csh and set the correct value for LANG, LANGUAGE, LC_MESSAGES, LC_ALL, LESSCHARSET variables.

Go to /usr/share/kbd/keymaps and try to find the keyboard map for china, once found, edit /etc/rc.d/rc.keymap with the correct value.

I can't say more I just know configure it for french

Last edited by keefaz; 06-14-2004 at 03:49 AM.
 
Old 06-14-2004, 05:39 AM   #3
JDW
Member
 
Registered: Feb 2003
Location: Melbourne, Australia
Distribution: Ubuntu 6.10, Slackware 11.0
Posts: 192

Rep: Reputation: 30
chinese character input and disaplay - need help

Hi,

I don't know much about how Slackware is setup, but I do know that looking at /usr/share/kbd/keymaps will not help you, because unlike French or Russian or English etc. , languages such as Chinese, Japanese & Korean have multi-byte encoding, and a regular keymap just won't cut it with literally thousands of characters to choose from.

However, to be able to type Chinese in a word processor such as Open Office Writer, you need to have a couple of things set up before hand.

Firstly, you need to make sure that you have the locale files installed for Chinese. Type "locale -a" at the prompt and this will list all the locale files installed on your system. If you have locale files called zh_CN, or zh_TW etc., then you are in business. If not, find the locale files on your distro CD or on the internet and install them.

Secondly, you will need Chinese fonts, the four Arphic fonts found with most popular distros are a great start.

Thirdly, if you plan to use KDE you will need to also install the kde-i18n files for Chinese, these should also be somewhere on your distro CDs.

Then you need to set the user locale to Chinese, but I don't know if Slackware is the same as Fedora/Red Hat/Mandrake etc. type distros, so I don't want to give you the wrong info, but this is how I do it ; I append the following lines in the .bashrc file in the user's home directory :-

export LANG=zh_CN
export LC_ALL=zh_CN
export LC_CTYPE=zh_CN
export XMODIFIERS=@im=scim

N.B. If you want Traditional Chinese, type zh_TW instead.
N.B. scim refers to one type of Input Method server program, others exist such as xcin, chinput and fcitx.

Hope this gets you started...

cheers,

jdw
 
Old 07-06-2004, 12:03 AM   #4
carboncopy
Senior Member
 
Registered: Jan 2003
Location: Malaysia
Distribution: Fedora Core, Slackware, Mac OS X, Debian, OpenSUSE
Posts: 1,210
Blog Entries: 4

Original Poster
Rep: Reputation: 45
Okay, Sorry I took so long to get back to this, but finally I got the hardware to set it up. i have two questions (other then setting up chinese support)

Question 1:
Is it okay if I have a seperate user for the chinese setup?
i don't want a system wide setup.

root will stay ENGLISH (please) ; I can't read and write chinese.


Question 2:
Where can I get chinese fonts?

On the side note, I have installed some chinese fonts on my system by putting them in /usr/local/fonts/ch and fc-cache it. When I go to chinese websites, some characters are still missing (looks like mahjong).
 
Old 07-06-2004, 05:28 PM   #5
JDW
Member
 
Registered: Feb 2003
Location: Melbourne, Australia
Distribution: Ubuntu 6.10, Slackware 11.0
Posts: 192

Rep: Reputation: 30
chinese character input and display -- need help

Hi,

1) Yes, you can make a separate user with Chinese settings. You should already have a normal English user (without root priveleges). Just create another user, and change the locale and XMODIFIER settings in that user's ~/.bashrc file.

I have never seen or tried Slackware (although I hope to in the not to distant future, Slack-users seem fairly proud of it), but I seem to remember something about Chinese support not being built-in by default, and that you have to set stuff up manually - my memory ain't clear on that, it may have been an old post about an older version of Slackware.

2) Most major distros would include the free arphic TT chinese fonts, but I'm not sure about Slack, however, I found this through googling - Chinese system setup in linux - which has a section on setting up in Slackware 9.0.

If you search the Net ("Chinese fonts download"), you will find plenty of sites with a wide variety of fonts...
 
Old 07-06-2004, 08:12 PM   #6
carboncopy
Senior Member
 
Registered: Jan 2003
Location: Malaysia
Distribution: Fedora Core, Slackware, Mac OS X, Debian, OpenSUSE
Posts: 1,210
Blog Entries: 4

Original Poster
Rep: Reputation: 45
Thanks!

This is what I have done,

1. locale -a (root)
shows

zh_CN
zh_CN.gb18030
zh_CN.gbk
zh_CN.utf8
zh_HK
zh_HK.utf8
zh_TW
zh_TW.euctw
zh_TW.utf8

2. Copied the downloaded chinese fonts to /usr/local/share/fonts
edit /etc/fonts/fonts.conf to include the path above.
run fc-cache

3. I have installed kde-i18n (chinese)
(the last time I start it (before I put in the fonts) I get mahjong character.

4. I edited /home/user/.bashrc

But when I log-in (ssh) as the user
and issue the comand locale, I get:
LANG=en_US
LC_CTYPE="en_US"
LC_NUMERIC="en_US"
LC_TIME="en_US"
LC_COLLATE=C
LC_MONETARY="en_US"
LC_MESSAGES="en_US"
LC_PAPER="en_US"
LC_NAME="en_US"
LC_ADDRESS="en_US"
LC_TELEPHONE="en_US"
LC_MEASUREMENT="en_US"
LC_IDENTIFICATION="en_US"
LC_ALL=

Will check out man locale
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Chinese input djib Debian 20 06-16-2008 01:41 AM
unzip seems failing to correctly handle chinese character haodongdong Linux - Software 3 04-23-2005 03:14 AM
Chinese input denning Slackware 16 02-24-2005 12:39 AM
Chinese Character display firefox/mozilla crnchyfrog Linux - Software 6 10-10-2004 10:30 PM
Need to get Chinese display and input on my computer BlueCarrot Linux - Software 17 02-26-2004 03:08 AM


All times are GMT -5. The time now is 10:52 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration