title: Matplotlib mathtext: Glyph errors in tick labels
body: <p>I've observed errors when rendering math in matplotlib 2.0.2, when using the default <a href="https://matplotlib.org/1.5.1/users/mathtext.html#mathtext-tutorial" rel="nofollow noreferrer">mathtext</a> as opposed to the <a href="https://matplotlib.org/1.5.1/users/usetex.html#usetex-tutorial" rel="nofollow noreferrer">LaTeX</a> math rendering engine. It seems that some glyphs (in my case the minus and the multiplication sign) is not recognized by mathtext. What makes it really weird is that the error only occurs when these particular glyphs appear in tick labels. When I deliberately type some mathy expression into e.g. the figure title, it works fine.</p>
  <p>Consider the below example and the resultant image:</p>
  <pre><code>import matplotlib
  import matplotlib.pyplot as plt
  
  # Customize matplotlib
  matplotlib.rcParams.update({# Use mathtext, not LaTeX
                              'text.usetex': False,
                              # Use the Computer modern font
                              'font.family': 'serif',
                              'font.serif': 'cmr10',
                              'mathtext.fontset': 'cm',
                              })
  
  # Plot
  plt.semilogy([-0.03, 0.05], [0.3, 0.05])
  plt.title(r'$-6\times 10^{-2}$')
  plt.savefig('test.png')
  </code></pre>
  <p><a href="https://i.stack.imgur.com/o1asc.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/o1asc.png" alt="test.png" /></a></p>
  <p>As seen on the image, multiplication and some minus signs in the tick labels have been replaced with other characters. If I use LaTeX (by setting <code>'text.usetex'</code> to <code>True</code>), everything renders nicely. Why does this happen, and more importantly, how can I fix it without changing from mathtext to LaTeX?</p>
  <h3>Additional information</h3>
  <p>This is the warning which gets printed when running the example code:</p>
  <pre><code>mathtext.py:866: MathTextWarning: Font 'default' does not have a glyph for '\times' [U+d7]
    MathTextWarning)
  mathtext.py:867: MathTextWarning: Substituting with a dummy symbol.
    warn(&quot;Substituting with a dummy symbol.&quot;, MathTextWarning)
  </code></pre>
  <p>Note that the minus signs appearing in exponents get rendered correctly. These also do not render probably if I leave out <code>'mathtext.fontset': 'cm'</code>, producing another, similar warning:</p>
  <pre><code>mathtext.py:866: MathTextWarning: Font 'default' does not have a glyph for '-' [U+2212]
    MathTextWarning)
  mathtext.py:867: MathTextWarning: Substituting with a dummy symbol.
    warn(&quot;Substituting with a dummy symbol.&quot;, MathTextWarning)
  </code></pre>
  <p>Also, if I include <code>'axes.unicode_minus': False</code> in the <code>rcParams</code> (and keep <code>'mathtext.fontset': 'cm'</code>), all minus signs render properly, though the problem remains for the multiplication signs.</p>
  <p>The multiplication sign error do not seem to be a problem on older versions of matplotlib (I've tested 1.5.1, 1.4.3 and 1.3.1). However, these matplotib's insist on only producing tick labels at 10⁻², 10⁻¹, 1, 10, 10² etc., and so no multiplication sign is ever needed.</p>
  <h3>Bug report</h3>
  <p>This has been submitted as a <a href="https://github.com/matplotlib/matplotlib/issues/10029" rel="nofollow noreferrer">bug report</a> to Matplotlib.</p>