Using a ^ outside math mode
There are good reasons for not using ^
in text mode. However, if you want to live dangerously,
\documentclass{article}
\catcode`^=\active
\protected\def^{\ifmmode\expandafter\sp\else\expandafter\textsuperscript\fi}
\begin{document}
Indulgence^2
$x^2$
\end{document}
I'll try to answer your second part of your question is there good reason why it is not default behavior. TeX works in horizontal mode or vertical mode or math mode. In horizontal mode (you call it as text mode), TeX puts typesetting material horizontally side by side. The exception from this horizontal direction is possible (by \lower
, \raise
primitives) but it is not common. In math mode, TeX puts typesetting material in very special way including special behavior when superscript or subscript is created. So, internally, this is always done in math mode by TeX. You can check in latex.ltx
that \textsuperscript
is defined in LaTeX using transition to math mode.