vbox使用時にbaselineが揃っているようにしたい

名前: nori2
日時: 2014-01-31 09:46:21
IPアドレス: 180.32.104.*

お世話になります。 以下の様なマクロ(以前にネットからパクったものだと思いますが)において、 下線の下のテキストにj,gなどがあると下線に近づいてしまいます。(1a)と(4a) 過去ログを参考にして\vphantom{y}を付けてみると少し改善しました。(1b)と(4b) これ以上はベースラインを揃えることはできないのでしょうか。お教えいただければ 幸いです。よろしくお願いいたします。 \documentclass[b5paper]{jsarticle} \usepackage[normalem]{ulem} \newcommand{\mmhh}{{\hspace{1mm}}} \makeatletter % 下線を引いて、下に注を付ける \def\aabbtt#1#2{\leavevmode\vbox{\baselineskip\z@skip \lineskip-4.0ex \ialign{##\crcr\footnotesize\hfill#2\hfill\crcr\hfill\mmhh\uline{#1}\mmhh\hfill\crcr}}} \makeatother \makeatletter % 下線を引いて、下に注を付ける \vphantom{y}付き \def\aabbyy#1#2{\leavevmode\vbox{\baselineskip\z@skip \lineskip-4.0ex \ialign{##\crcr\footnotesize\hfill\vphantom{y}#2\hfill\crcr\hfill\mmhh\uline{#1}\mmhh\hfill\crcr}}} \makeatother \begin{document} ★ 下の文字の位置の比較 アルファベットのみ (1a) \aabbtt{test}{test}  (2a) \aabbtt{test}{testV}  (3a) \aabbtt{gtest}{gtestV}  (4a) \aabbtt{jtest}{jtestV} \vspace{1cm} ★ 下の文字の位置の比較 アルファベットのみ[vphantom{y}]付き (1b) \aabbyy{test}{test}  (2b) \aabbyy{test}{testV}  (3b) \aabbyy{gtest}{gtestV}  (4b) \aabbyy{jtest}{jtestV} \vspace{1cm} ★ 日本語も混在 (5) \aabbtt{test test}{テスト}  (6) \aabbtt{テスト}{test}  (7) \aabbtt{test test}{aテスト}   \vspace{1cm} (8) \aabbtt{test test}{gテスト}  (9) \aabbtt{test test}{jテスト} \end{document}

この書き込みへの返事:

お名前
題名 
メッセージ(タグは <a href="...">...</a> だけ使えます。適宜改行を入れてください)