Kanji Fuda

Well, what was supposed to be a quick weekend project back in March is finally on it’s way to the iPhone App Store; and for the second time no less.

“Kanji Fuda” is a simple Japanese kanji learning game reminiscent of ComCul’s excellent Kanji for Fun. Between work and baby management, I’ve been cobbling it together in fits and starts over the last couple of months. Even have the fancy shmancy website that seems to be prerequisite for releasing any kind of mobile app.

Now that the basic version is done and “released” — assuming that I am able to get it by the App Store gate keepers — I’m working on an advanced version specifically to help study for the year-end Japanese Language Proficiency Test (JLPT). I’ve always wanted to go after Level One, but given how little I actually use my Japanese these days, it’s going to be a stretch… hence Kanji Fuda.

Nihongo of the Day: 成らぬ堪忍するが堪忍

Have been watching 日本語で遊ぼ (literally, “Playing in Japanese”) with Layla every day.  It’s an awesome show that highlights elements of traditional culture and language in a format that’s fun for kids and interesting to parents (or, at least, interesting to one gaijin dad).

The Japanese introduced is often lesser used, if not bordering on archaic.   Today we learned “成らぬ堪忍するが堪忍”, which in English would — I think — roughly translate to “Damned if you do, damned if you don’t… so just put up with the status quo.”

I can’t tell you how many times I could have used this phrase while living in Japan.  Like, say, when the wealthy yet crazy neighbor would come over and shower me with junk (old pots, broken plates, flat bicycle tires, etc.) because she thought I might find it useful.

I couldn’t refuse the junk.. that would upset her and cause trouble in the neighborhood.  But I also couldn’t throw it away again; she would notice, get upset, and that would… cause trouble in the neighborhood.

So I hid two years worth of slowly accumulating junk under the house I was renting.

成らぬ堪忍するが堪忍・・・

Emacs Japanese Input

If you ever find yourself stuck relying on the IME built-into Emacs (rather than the IME native to your OS), here are the essential key strokes you’ll need to know.

  • C-\:  toggle input mode (ime on or off)
  • C-h:  shows conversion options if used when in conversion mode
  • SPC: transform input to kanji, or show the next conversion candidate
  • DEL:  abort conversion
  • C-n: show the next conversion candidate
  • C-p: show the previous conversion candidate
  • C-o: lengthen conversion bunsetsu
  • C-i, TAB: shorten conversion bunsetsu
  • Shift-k:  toggle between hiragana and katakana
  • qq:  toggle between alphabet and kanji modes
  • qz:  turn on zenkaku alphabet mode
  • qh:  turn off zenkaku alphabet mode

Also useful:

  • C-x RET l:  set the buffer language environment
  • C-x RET f: select the encoding
  • C-x RET C-\:  select the input method

Configuring Debian for UTF-8

Easier to configure than I thought it would be. The defacto document on this lists a series of convoluted steps to get UTF-8 working.  All you really need to do is as follows:

  1. Launch the local configurator via # dpkg-reconfigure locales
  2. Select the locales you would like to support. I need Japanese support so I selected ja_JP.EUC, ja_JP.UTF-8, and en_US.UTF-8 in addition to already available locales. Click “Ok”.
  3. Choose the default locale from the list; make sure it is a UTF-8 locale. Click “Ok”.
  4. Login to another shell.

That’s it!

# locale charmap should now return “UTF-8”.

Nihongo of the Day

My wife and I have been playing a word-of-the-day game on and off for a year or so. Though the pace is slow, it’s probably been one of the most effective ways of picking and retaining new vocabulary I’ve used; especially now that we’ve moved back to the US.

Yesterday’s word came up while watching Karei Naru Ichizoku, a Kimutaku drama about Japanese business and power in post-WWII Japan.

徹底的(tetteiteiki) — exhaustive

Lots of tetteiteki this and that in Karei Naru Ichizoku. Business, politics, power. Lawyers. Lawyers and exhaustive research into the nether regions of business.  徹底的な研究 of some such product, 徹底的な検査 to prepare for the upcoming trial.. yada, yada. As for me, the drama kind of induced me to 徹底的に寝る。

How to segfault Apache 2+ with mod_security

Build mod_security against the wrong set of headers, and Apache 2 will mysteriously begin to segfault in a persistent manner. Check which version you’re running with dpkg --get-selections | grep apache2.

Seems my shiny new Debian distro running the prefork version of Apache had the threaded (worker) headers installed against it. Duh. apt-get install apache2-prefork-dev reinstalled the correct prefork headers and Apache is happy again.

Mathiew Dessus has a great article about installing mod_securty on Debian for those interested.

The Mystery of Shift Caps Lock

Sheesh. For the last, say, eight years I’ve wondered why Japanese keyboards required one to punch both Shift and Caps Lock to turn caps lock on. And now that I’m on mostly English OS’s these days, I think I know: Caps Lock is (was?) an alternative to the henkan key. Probably before there were Japanese keyboards, there was Caps Lock Henkan. And I guess Alt-` emerged for people who had become accustomed to the having a real henkan key.

Anyway, for anyone else out there suffering through Japanese emails on English windows, here are some useful key combinations:

Alt-Shift: Toggle Input Language
Caps Lock: Henkan (while in Japanese input mode)

And beware of installing both English and Japanese keyboards under the installed default keyboard settings. The keyboard layout will change randomly and drive you bonkers.

Rules of thumb for creating HTML emails (in Japanese)

This always turns out to be much more difficult than it should be. Part of the problem is that there are many, many more email clients out there in common use than there are web browsers. And all of these email clients either use their own subset of HTML or, in the case of webmail, special filters that attempt to convert HTML-ized messages into a “sanitized” format.

Here’s some basic rules of thumb to follow:

  • Drop the doctype and head section.
  • Keep it simple. No fancy table nesting.
  • However, do use tables for positioning, rather than CSS.
  • If using CSS, keep it inline, or better yet avoid CSS altogether and use tags to apply style. (Pretend that it’s 1998 and stylesheets don’t exist.)
  • Avoid background images.
  • Call images from the server; don’t attach.
  • Don’t link to documents secured by SSL.
  • Use images as links if you want them to stand out in a color other than blue.
  • Encode Japanese in JIS (iso-2022) for widest email client support.
  • Before you hit that send button, test, check, test and check again, and.. Pray.

Unlike a correction to a web page, you can’t do a quick edit and “take back” what you just put out there. And because you’re pushing information at people rather than allowing them to pull it on their own terms, if the information is not relevant and easy to see, some folks could even become a bit angry. Or potentially very.. very… angry. Expect a call or two. Hoo boy.

For more information, Xavier Frennette has a terrific blog post outlining the types of CSS support in various webmail clients. The folks at Campaign Monitor have followed up with an increadibly thorough chart of all the popular clients. Definitely worth a look.

Finally, consider marketing webmail service. I am. More and more of these are popping up; for a small fee you can offload much of this heavy design lifting to them.

Oga’s Japanese Cuisine

An authentic Japanese bento is the last thing I expected to find in Natick.

Oga’s Japanese Cuisine

Following a seminar about the crazy healthcare reform laws that have befallen Massaschusetts, we decided to stop by Oga’s in Natick to see what the rest of the Boston Japanese community was raving about. Wow, we weren’t disappointed.

Oga’s Sushi BentoThough Oga’s looks pricey for dinner, a formal (read: “fancy-ish”) bento box lunch was only about $12. I had a fairly good tonkatsu pork bento (complete with cabbage and sauce), and Miho a really spectacular sushi box lunch.

Oga’s can be a bit far out of Boston on the highway, but worth the trip. Best bento I’ve ever had in the US.