4

Why doesn't the \fontdimen-command change anything with XeTeX?

\input pgffor
\def\chfndims#1{\foreach\dim in{13,...,19}{\fontdimen\dim#1=20pt}}
\font\mymathfn="XITS Math:script=math" at 10pt \chfndims\mymathfn
\font\mymathfns="XITS Math:script=math;+ssty=0" at 7pt \chfndims\mymathfns
\font\mymathfnss="XITS Math:script=math;+ssty=1" at 5pt \chfndims\mymathfnss
\textfont0=\mymathfn \scriptfont0=\mymathfns \scriptscriptfont0=\mymathfnss
\textfont1=\mymathfn \scriptfont1=\mymathfns \scriptscriptfont1=\mymathfnss
\textfont2=\mymathfn \scriptfont2=\mymathfns \scriptscriptfont2=\mymathfnss
\textfont3=\mymathfn \scriptfont3=\mymathfns \scriptscriptfont3=\mymathfnss
\textfont4=\mymathfn \scriptfont4=\mymathfns \scriptscriptfont4=\mymathfnss
\textfont5=\mymathfn \scriptfont5=\mymathfns \scriptscriptfont5=\mymathfnss
\textfont6=\mymathfn \scriptfont6=\mymathfns \scriptscriptfont6=\mymathfnss
$ a^b \, c_d \, e^1 \, f_2 $
\bye

Nothing changes.

I would like to change the horizontal space before a superscript.

  • I don't think that there's a fontdimen for that. Not among the 22 fontdimen parameters of the font in family 2. There's \scriptspace for the space after a sub/superscript. – egreg May 29 '11 at 17:55
4

There's no font dimension parameter that controls the spacing before a subscript/superscript: they are attached to the atom they refer, possibly shifted horizontally based on the information provided by the atom, if it's a character box. The parameter \scriptspace controls the space after them.

  • Thanks for the info. Do you know if XeTeX does not support setting fontdimens related to maths (ie. sub-/superscript height)? – morbusg Jun 3 '11 at 12:48
  • I've tried the chemical formula example in the TeXbook and it doesn't work like advertised. :( Perhaps Will is more expert in the matter. – egreg Jun 3 '11 at 13:01

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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