Ruby

2001-09-10

I found out about Rubys today. That's a ruby? It's the text that appears above or below some other text, kind of like a subscript or superscript. It's used in Japanese alot for pronounciation guides since there's know way to know the pronounciation of a word written in Kanji

For example the following sentence.

今日(きょう)(でん)(しゃ)()った.

If you can't read that because you're browser doesn't show Japanese here's an English example.

WWW(World Wide Web)

Try selecting the text. You'll see it's NOT made with tables. It does make parsing the text out of the HTML pretty complicated though. Here's the HTML for the English example.

<ruby>   <rb>WWW</rb>   <rp>(</rp><rt>World Wide Web</rt><rp>)</rp> </ruby>

<ruby> defines the whole section. <rb&gt defines the base (The main text). <rp> defines stuff that will NOT appear in a browser that understands the <ruby> tags. This is so older browsers will still display something readable. <rt&gt defines the actual ruby, the part that appears above the text. There are more details here.

I became aware of this feature by noticing it being used on this page that I found out about through an e−mail by it's author.

Comments
Mosque
FUCK!