Chinese learning tool in Java

I found a Chinese dictionary/annotation tool written in Java called DimSum. I ran it on Windows and Solaris. Here's how I ran it on Solaris 10 x86 8/07.

  1. Download DimSum.jar from http://www.mandarintools.com/download/DimSum.jar
  2. DimSum uses public-domain Chinese-English dictionary called CEDICT. The dictionary's was just updated last week. So, replace the one in DimSum.jar with the latest one.

    $ curl http://www.mdbg.net/chindict/export/cedict/cedict_1_0_ts_utf-8_mdbg.txt.gz | gunzip > cedict_ds.u8
    $ jar uvf DimSum.jar cedict_ds.u8
    adding: cedict_ds.u8(in = 3481130) (out= 1436906)(deflated 58%)
  3. Now, I can run it just with 'java -jar'. But if one wants to annotate Chinese web page, start it like:
    $ BROWSER=firefox PATH=/usr/dt/bin:$PATH java -jar DimSum.jar &

  4. I annotated http://cn.sun.com/. It opened a new tab in Firefox. Notice the URL below. cn.sun.com's page was processed locally and served up from local host's port 4445. When I hover the mouse over Chinese word, translation box appears.




  5. Now, there's a small glitch. When the DimSum.jar starts browser, it does it by via /usr/dt/bin/sdtwebclient. Problem is that sdtwebclient doesn't exit even after successful launch so DimSum.jar hangs. Workaround is to kill sdtwebclient like:
    $ pkill sdtwebclient
web/text file annotation is not the only function of DimSum. There's also 'Dictionary' and 'Flashcards'. I'm thinking about adding Japanese translation to the dictionary.
Comments:

Thanks for the info. I tried your procedure, it sort worked but only half way. I am getting the pronunciation of a single Chinese character, but not the entire word (which is a collection of Chinese characters). Also I did not get the English translations, only question marks ??. Do I have to make modifications to my .bash_profile file? Thanks again.

Posted by W. Wayne Liauh on December 23, 2007 at 02:44 AM JST #

Thanks for the info. I tried your procedure, it sort worked but only half way. I am getting the pronunciation of a single Chinese character, but not the entire word (which is a collection of Chinese characters). Also I did not get the English translations, only question marks ??. Do I have to make modifications to my .bash_profile file? Thanks again.

Posted by W. Wayne Liauh on December 23, 2007 at 02:46 AM JST #

Wayne,

1. Are you trying to listen to sound? Sorry, I haven't tried sound.
2. I think question marks is Java version problem. I tested with 1.5.0_14 or so. Please check "java -version".

Posted by Katsumi INOUE on December 23, 2007 at 04:42 PM JST #

Did you install Chinese fonts? DimSum.jar outputs a lot of auto config info by default. It may tell something.

Posted by Katsumi INOUE on December 25, 2007 at 10:56 AM JST #

Post a Comment:
  • HTML Syntax: NOT allowed
About

The views expressed on this blog are my own and do not necessarily reflect the views of Oracle.

Search

Archives
« April 2014
SunMonTueWedThuFriSat
  
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
   
       
Today