TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have followed Japanese Problem using MacTeX 2011 to set up Ruby Furigana with TeX.

I'm wondering if it is possible to set up Furigana both above and below the original character?

share|improve this question
Welcome to TeX.sx! – Peter Jansson Jan 28 '13 at 18:09
Thanks, I'm a total newbie in TeX, but furigana support totally sucks everywhere else, apparently... – Vasili Sviridov Jan 28 '13 at 18:38
Are Furigana really used both above and below? – egreg Jan 28 '13 at 18:40
W3C guidelines for Ruby text do suggest the ability for simultaneous usage, and wikipedia article on the subject also seem to have it in some way... But I want it to help with my studies, not for publishing purposes. – Vasili Sviridov Jan 28 '13 at 18:43
up vote 7 down vote accepted

It seems that you can set the \rubysep parameter to a negative value to get the effect you want.

%!TEX TS-program = xelatex

\setCJKmainfont{Hiragino Mincho Pro}

On this line \ruby{学}{がく}\ruby{生}{せい}


enter image description here

Here's a solution which seems to allow simultaneous top and bottom furigana

%!TEX TS-program = xelatex
\setCJKmainfont{Hiragino Kaku Gothic ProN}
    %% save the current baselinestretch
    %% and reset value to "1"
    %% reassign \rubysep to allow furigana below
    %% measure the width of the first argument
    %% move to the left by that distance
    %% restore the original \rubysep and \ baselinestretch
%% implement double spacing

たんぼの \eruby{畦道}{あぜみち}{footpath}に、\eruby{タンポポ}{tanpopo}{dandelion}が 
さいて いました。あまい においの する まっき
いろな 花です。そこへ ひらひらと 白い \eruby{チョウチョ}{chocho}{butterfly}が 
あそびに きて、「タンポポさん、あなたは はろの
 ブローチね。」 と いいました。白い チョウに そう いわれると、 「ほん
とうに そう 見えて。」 と、 タンポポも うれしく なりました。今度は、ヒ
バリが あそびに きて、「タンポポさん、 あなたは のはらの おほしさまみた
い。」 といいました。ヒバリに こう いわれると、 「まあ、 おほしさまだな
んで。」 と うれしく なりました。

    \eruby{畦道}{あぜみち}{footpath}に                    & along side a path  \\
    \eruby{タンポポ}{tanpopo}{dandelion}が さいて いました & a dandelion bloomed. 

This produces:

enter image description here

The idea is two first save the current \baselinestretch and then reset to 1. Then I call \ruby{...} twice, the second time using a \phantom argument and adding a negative width between the two calls to \ruby to give the appearance of two furiganas for one block of kanji or other kana.

Since ruby is scaling things vertically based upon baseline values, I think all your vertical scaling should do the same thing.

share|improve this answer
But is it possible to have them both simultaneously? I'm trying to have the kana above and the english version below the kanji characters, for my studies. – Vasili Sviridov Jan 28 '13 at 18:40
Thank you so much! – Vasili Sviridov Jan 29 '13 at 5:02
I've tried it out, but there are still some issues (possibly due to my misunderstanding of the TeX inner works). Could you take a look at gist.github.com/4662109? If I use the double spacing - it gets all screwed up. Which could be fixed by playing with the offsets, I guess. But it also pushes the following character to the right. Also, how would one change the type for the english portion? Japanese types have monospaced font for english letters. Thanks. – Vasili Sviridov Jan 29 '13 at 5:46
Cute story. I'll have to think about this one. I might not have an answer until later tomorrow. – A.Ellett Jan 29 '13 at 5:52
Thank you again, you are very helpful. – Vasili Sviridov Jan 29 '13 at 5:54

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.