[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Display Chinese in java under Linux



When I was reading the Faq... it reminded me a email that I forget to
reply long time ago.
I'm so sorry.. :)
Here we go

4.11 在Java中顯示中文 (hehe unofficeal, test first))

在Debian中用的Java VM還不太完美, 所暫時用Blackdown 或
Sun VM 代替. Java 使用UTF, 所以輸入中文不是問題 ( 可
用 xcin ). 顯示中文方面如下:

首先, 把字形裝好 ( 如若你可在X裹看到中文 ).
然後, 把locale調正,
把VM裹( $JAVA_HOME/jre/lib/ )的font.properties.(你的locale) 改正為
我所提供的檔桉(現只有Big5板). 主要是改相當的字形及轉換方法.
詳情參看Sun i18n 的綱址.
---- example /usr/java/j2sdk1.4.0/jre/lib/font.properties.zh_TW ---
這是我寫的Demo可供參考
File may be too big here is the (temp) link 
http://alex.dpcgroup.com/~alex/temp/demo.tgz

tar -zxvf demo.tgz
cd Testing
cp font.properties.zh_TW $JAVA_HOME/jre/lib/
$JAVA_HOME/bin/javac Testing.java
$JAVA_HOME/bin/java Testing &
export LC_CTYPE=zh_TW.Big5
$JAVA_HOME/bin/java Testing &

p.s I don't know how to type simplfly, so I can't test my demo. If
someone could do that
it will be great. I only need the unicode file e.g Testing_zh_cn.properties
then I can post the font.properties for simplfly

Thanks
Alex



>Yu Guanghui :
>
>  
>
>>hi
>> Could you write down how to set up? I am glad to to add it to _Debian_Chinese_FAQ. ;-)
>> Thanks.
>>				Yu Guanghui
>>
>> 
>>
>>    
>>
>>>-----Original Message-----
>>>From: Shao Zhang [mailto:shaoz@asia.com]
>>>Sent: Wednesday, April 03, 2002 11:37 AM
>>>To: Alex Lau
>>>Cc: debian-chinese-big5@lists.debian.org
>>>Subject: Re: Display Chinese in java under Linux
>>>
>>>
>>>Hi,
>>>
>>>Actually, after install additional fonts, I got it working :)
>>>However, I still cannot get it to display Chinese through the plugin.
>>>
>>>Can anyone get java working for this site: 
>>>http://weiqi.tom.com/home.php
>>>
>>>Just click on one of the go games, and it will bring up a 
>>>java app with
>>>Chinese in it.
>>>
>>>Regards,
>>>
>>>Shao.
>>>
>>>On [Thu, 28 Mar 2002 16:42:04 -0600], Alex Lau 
>>><alex@dentonlive.com> wrote:
>>>   
>>>
>>>      
>>>
>>>>Sorry it take me so long to answer your question :)
>>>>Busy...
>>>>Here is your sample of font.properties plus a testing program
>>>>it include zh_TW and zh_HK local... which is the same in my setting
>>>>because still only get one way to decode right now...
>>>>let me know it is working for you.
>>>>Good luck
>>>>Alex
>>>>
>>>>
>>>>Shao Zhang wrote:
>>>>
>>>>     
>>>>
>>>>        
>>>>
>>>>>Hi,
>>>>>
>>>>>Just wondering if anyone can display Chinese in java apps 
>>>>>       
>>>>>
>>>>>          
>>>>>
>>>under Linux.
>>>   
>>>
>>>      
>>>
>>>>>I read something on java.sun.com, and it only mentions to modify the
>>>>>font.properties file. But I still get no where.
>>>>>
>>>>>Thanks for any help in advance.
>>>>>
>>>>>Regards,
>>>>>
>>>>>Shao.
>>>>>       
>>>>>
>>>>>          
>>>>>
>>>-- 
>>>To UNSUBSCRIBE, email to debian-chinese-big5-request@lists.debian.org
>>>with a subject of "unsubscribe". Trouble? Contact 
>>>listmaster@lists.debian.org
>>>
>>>
>>>   
>>>
>>>      
>>>
>> 
>>
>>    
>>
>
>
>  
>



Reply to: