Fonts & Character SetsSub/Superscript dimensions

Information and discussion about fonts and character sets (e.g. how to use language specific characters)
Post Reply
mathsteak
Posts: 2
Joined: Mon Mar 09, 2009 1:12 am

Sub/Superscript dimensions

Post by mathsteak »

Hi. I'm new to this forum and I've just began (attempting) customization of my LaTeX. I'm still very novice when it comes to code, so I apologize ahead of time if this seems a bit trivial.

I'm trying to adjust the dimensions of the superscripts and subscripts in LaTeX. I've found some help as far as making the adjustments in plain TeX, namely by using the commands (which were obtained from http://www.math.cornell.edu/~hatcher/AT/typography.html

Code: Select all

\fontdimen16\textfont2=2.75pt
\fontdimen17\textfont2=2.75pt
\fontdimen14\textfont2=4.75pt
\fontdimen13\textfont2=4.75pt
However, when this is inputted in LaTeX, I get the following error.

Code: Select all

! Font \nullfont has only 7 fontdimen parameters.
<to be read again> 
                   =
l.5 \fontdimen16\textfont2=
                           2.75pt
? 
! Font \nullfont has only 7 fontdimen parameters.
<to be read again> 
                   =
l.6 \fontdimen17\textfont2=
                           2.75pt
? 
! Font \nullfont has only 7 fontdimen parameters.
<to be read again> 
                   =
l.7 \fontdimen14\textfont2=
                           4.75pt
? 
! Font \nullfont has only 7 fontdimen parameters.
<to be read again> 
                   =
l.8 \fontdimen13\textfont2=
                           4.75pt
Does anyone know a way to fix this?
~ Ben

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org
LaTeX Beginner's Guide LaTeX Cookbook LaTeX TikZ graphics TikZによるLaTeXグラフィックス
User avatar
Stefan Kottwitz
Site Admin
Posts: 10290
Joined: Mon Mar 10, 2008 9:44 pm

Re: Sub/Superscript dimensions

Post by Stefan Kottwitz »

Hi Ben,

welcome to the board!
Try the command \DeclareMathSizes, you will find information about that macro by using the forum search feature or a web search engine.

Stefan
LaTeX.org admin
mathsteak
Posts: 2
Joined: Mon Mar 09, 2009 1:12 am

Re: Sub/Superscript dimensions

Post by mathsteak »

Hi Stefan. Thanks for the reply and warm welcome.

It seems that the command you suggested (according to Google and other posts on this site) only adjusts the size of the fonts and not their position. Reading my original post over again, it seems I was a bit unclear. I'm looking to shift subscripts down and shift superscripts up, as with the Plain TeX commands listed in my original post. Is there another macro that will achieve this?
~ Ben
phi
Posts: 577
Joined: Tue Oct 21, 2008 8:10 pm

Sub/Superscript dimensions

Post by phi »

There is some reason why the first sentence on that page says, "The book is written in Plain TeX in order to maximize control over the output." If you try to set font parameters, then they will be overwritten at some point by LaTeX's font selection mechanism. It should work if you call \glb@settings (which initializes the math fonts) before changing the font parameters (and after \begin{document}), but only if you don't change any math fonts afterwards.
Post Reply