VPLファイルについて

Re: VPLファイルについて

- しっぽ 愛好家 の投稿
返信数: 1

数式中において,補正対象の文字に「常に」アキを追加するのなら,次のような手も考えられます.

もっとも,\mathbf{f} のようなものに対してもアキが入ってしまいます(これは,\fam を調べて回避することも可能でしょうが)し, そもそも私自身はそのような補正を施したくなるのは開きのパーレンの直後のような特定の箇所のみですので (「f(x)」「p + q」のようなものには補正の必要を感じないので),私自身はむしろ(数式内では)手動での調整を行って, 下記のサンプルのような処理を実際に行うことはありませんが.

\documentclass{article}
\DeclareMathSymbol{\jinmath}{\mathalpha}{letters}{`j}
\DeclareMathSymbol{\finmath}{\mathalpha}{letters}{`f}
\DeclareMathSymbol{\pinmath}{\mathalpha}{letters}{`p}
\makeatletter
\begingroup
\toks@{\mathcode`j="8000\relax}
\lccode`\~=`j
\lowercase{\xdef\@init@mathchar{\the\toks@\def\noexpand~{{\mkern1.5mu\jinmath}}}}
\toks@\expandafter{\@init@mathchar \mathcode`f="8000\relax}
\lccode`\~=`f
\lowercase{\xdef\@init@mathchar{\the\toks@\def\noexpand~{{\mkern1.5mu\finmath}}}}
\toks@\expandafter{\@init@mathchar \mathcode`p="8000\relax}
%%% \endgroup に「p」が入っていることに注意
%%% あるいは,{,} でグルーピングしてもよい
\lccode`\~=`p
\lowercase{\xdef\@init@mathchar{\the\toks@\def\noexpand~{{\mkern.75mu\pinmath}}}}
\endgroup
\@init@mathchar
\makeatother

\begin{document}
$(f)$, $(j)$, $(p)$
\end{document}