Entering Japanese Text
You can put any character (Japanese or otherwise) into a page if you know its Unicode number:
- in decimal: 碁 becomes 碁
- or in hexadecimal (base 16): 碁 becomes 碁.
Here are eight ways to find the Unicode number for a Japanese character:
- In some web browsers you can type or paste Japanese characters directly into the edit box and it will translate them into the appropriate HTML code.
SirLyric: I have verified that this works in Mozilla Firefox 0.8; when you paste you'll see the kanji in the edit box, but hitting preview you'll see it replaced by the appropriate HTML code.
- Type or paste text into http://www.garethrees.org/htmlify.cgi and press enter.
- Look it up in the WWWJDIC kanji finder. For example, with "Selection Type" set to "Japanese ON or KUN reading", type "Go" into the "Keyword" box and click on "Select Kanji". This brings up a page with 114 kanji that have go as a possible reading; the one you want is 碁 in the eighth row and fourth column; check the box to its left and click "Continue" to get a page of information about 碁. The fourth field says "U7881" which means the Unicode number is 7881 in hexadecimal and so you can write it as ỉ
- This site http://kanjidict.stc.cx/dict allows you to enter the word in romaji (wapuro) and it gives you the kanji which can be cut and pasted into the edit box on SL as described above.
- Look it up in Jeffrey's Japanese/English Dictionary
- On Mac OS X, enable the ことえり input method (on System Preferences → International → Input Menu) and select it from the Input menu (just right of the Help menu). This brings up a floating window for choosing what kind of characters to type; in this window click the button in the lower left to bring up the Character Palette. Search to find your character (in this case the radical is ishi 石 with 5 strokes and 碁 has a further 8 strokes), click on the character, and click on the arrow button in the lower left to open up an extra panel that gives the character code in hexadecimal.
- Safari: It seems that Safari now allows you to type in Japanese text directly like this 囲碁 (tested with version 3.1.2). Firefox works too. When you click Preview, the kanji you input turn into code in the edit window and appear as kanji in the preview window.
- Using SubEthaEdit : SubEthaEdit is a great little program that can take some of the hassle out of character conversions. Simply type (or paste) the desired text into a subethaedit window (promoting to UTF8 depending on your settings) and then "Copy as XHTML" (Command-Shift-C). Paste it and remove the surrounding xhtml tags, and what remains is the character code, ready to be submitted to SL.
- Find it in the Unihan database. For example, on the Unihan search page select "Japanese On" from the menu, type "go" into the box and click on "Lookup". This brings up a page with 367 kanji containing "go" in their onyomi. The one you want is the 231st in the list.
- In Windows, use the Character Map (Start → Programs → Accessories → System Tools → Character Map), choose an appropriate font (for example, MS Mincho has Japanese characters) and turn on the "Advanced view" checkbox. When you click on a character the code appears in the bottom left.
kokiri: you can cut and paste characters into the edit window, and it will convert them to unicode for you
Gareth: Only in some browsers. For example, Opera and iCab don't do it. Which browser do you use?
Bob McGuigan: Internet Explorer 6 allows this cutting and pasting.
SirLyric: On a related topic, can anyone recommend some free TrueType or Postscript (that is, Windows-compatible) Japanese fonts? Microsoft supplies MS Mincho, which is well drawn and well hinted for small text, but it's definitely blocky and unattractive at large sizes. Are there any more beautiful ones?
Bob McGuigan: I don't know whether it is freely available, but the font Kanji Hitsukaisyo looks good to me at large sizes.