Keyboard Entry of Subscripts and Superscripts

The Send-a-Smile and Send-a-Frown feedback from Office beta users is very useful for finding out where we’ve done right and wrong things with the new Office. From time to time I’ll post thoughts on some of the feedback that pertains to the math facility. The present post discusses the hot keys for entering subscripts and superscripts in ordinary text and how they might be implemented in math zones.

First please note that the quickest way to enter z with a subscript q in a math zone is to type z_q followed by a space or operator like +. This inserts a math subscript object with z as the base and q as the subscript. The terminating space is deleted, but an operator remains. This notation is partly borrowed from TeX, but can differ as to what gets put into the subscript. For example, a_12 puts 12 into the subscript, whereas in TeX only the 1 ends up in the subscript. A detailed discussion is given in Chapter 2 of the linear format paper. Similarly, to enter “z squared”, type z^2 followed by a space or operator. For example, the Pythagorean Theorem can be entered by typing a^2+b^2=c^2<space>. This approach allows you to enter subscripted or superscripted subscripts and superscripts, etc., that is, they are nestable (multilevel), unlike in ordinary text. You can also have expressions like z sub 0 squared (type z_0^2), with the superscript 2 displayed above the subscript 0. In ordinary text, one script has to follow the other.

Some users automatically used this handy keyboard approach, possibly because TeX is in their fingers. Generally such users are quite happy with the results. Others tried the math ribbon structures and/or the subscript/superscript hot keys. Some of those users were less happy and even frowned L. The ribbon structure entry will be the topic of a future post.

The subscript and superscript hot keys are ctrl+= and ctrl+shift+=, respectively. They’ve been in Word for a long time, certainly back through Word 2 (circa 1993), which is when I started using Word. Basically these hot keys change the character formatting of the selected text or the insertion point. They act as toggles, so ctrl+= followed by ctrl+= leaves the text unchanged. They can also be used to change a subscript into a superscript and vice versa. For example, if you select the 2 in the expression z squared and type ctrl+=, you convert to z with a subscript 2.

These hot keys are handy and well worth trying out. In fact, I’ve used them a lot over the years. They can lead to surprises if you type them by mistake, since they cause the subsequent text to be about 70% as large as the base text. Meanwhile the font size appearing in the ribbon continues to display what the base text size is. Also for some reason they mess up the line spacing when I paste them into these blog posts, although they look correct in Word.

Since these hot keys were designed for “single-level” subscripts and superscripts, we figured they wouldn’t be useful in math zones and they are ignored in Office 2007/2010 math zones. But challenged by the Send-a-Frown feedback, I realized they can be implemented to insert/remove/change the math subscript and superscript objects. I prototyped them over the weekend and have pretty much matched their behavior in ordinary text. My prototype has one generalization: if you select only part of a subscript or superscript and type one of the hot keys, a corresponding nested subscript or superscript is entered. This “higher-level” script isn’t available except in math zones. But since it’s a fairly common thing to have in math zones, it seems worthwhile to generalize the hot keys accordingly.

Since these hot keys don’t work in Office 2007/1010 math zones, please use the _, ^, and _^ entry instead. This is also more convenient than using the math ribbon subscript/superscript structures, as a future post will discuss. Or you can write your equations by hand using the Windows 7 Math Input Panel, which recognizes subscripts and superscripts (see David Carlisle’s post for an example).



Comments (6)

  1. Nali says:

    Excel 2010 and Powerpoint 2010 both support (textstyle) supercripts and subscripts inside a math zone (Font dialog must be used, offset can be set). But the hotkeys  ctrl+= and ctrl+shift+= also do not work.

  2. Nicolas says:

    How is it possible to have just a superscript before a variable?

  3. Dan says:

    I actually have the same problem. I would like to enter a superscript then the base and then a subscript like that:


    But this doesn't give any results… any idea how to do?


  4. Nali says:


    You should use following notation:


  5. MANIK SARKAR says:

    very useful tutorial for everyone.