The following example code serves to show that siunitx
uses the ugly $^\circ$
construction as well (for compatibility reasons). Most fonts have a degree symbol for angles (U+00B0 DEGREE SIGN
) and some have a degree Celsius symbol for temperatures (U+2103 DEGREE CELSIUS
, output by \textcelsius
in my example) and these symbols usually would fit better to the line widths of the font.
My example also shows that the single degree symbol and the one included in the special degree Celsius glyph do not have to be the same, so I personally would redefine it accordingly when I'm using both in a piece of work, see the second line.
Compile with XeLaTeX or LuaLaTeX.
\documentclass{article}
\usepackage{fontspec}
\usepackage{siunitx}
\begin{document}
° % degree symbol
\si{\celsius} % ${}^{\circ}$
\textcelsius\ % special glyph of the font
\si{\degree} % angle unit
\sisetup{
math-celsius = °\text{C}, % for temperatures
text-celsius = °C,
math-degree = °, % for angles
text-degree = °
}
°
\si{\celsius} % now with the glyph
\textcelsius\ % special glyph of the font
\si{\degree} % angle unit
\end{document}
The angle is $30^\circ$.
, and the output is the same assiunitx
's.\degree
.siunitx
does that for compatibility reasons. So if one strives for better looks then redefining them is best.