MCPcopy Index your code
hub / github.com/matplotlib/matplotlib / test_usetex_is_copied

Function test_usetex_is_copied

lib/matplotlib/tests/test_text.py:595–606  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

593
594@needs_usetex
595def test_usetex_is_copied():
596 # Indirectly tests that update_from (which is used to copy tick label
597 # properties) copies usetex state.
598 fig = plt.figure()
599 plt.rcParams["text.usetex"] = False
600 ax1 = fig.add_subplot(121)
601 plt.rcParams["text.usetex"] = True
602 ax2 = fig.add_subplot(122)
603 fig.canvas.draw()
604 for ax, usetex in [(ax1, False), (ax2, True)]:
605 for t in ax.xaxis.majorTicks:
606 assert t.label1.get_usetex() == usetex
607
608
609@needs_usetex

Callers

nothing calls this directly

Calls 4

figureMethod · 0.80
add_subplotMethod · 0.80
drawMethod · 0.45
get_usetexMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…