Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit fb4929b

Browse files
committed
Fix what's new note for text
1 parent bff4681 commit fb4929b

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed
Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
``mathtext`` now supports ``\text``
22
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
33

4-
``\text`` can be used to obtain upright text within an equation.
4+
``\text`` can be used to obtain upright text within an equation and to get a plain -.
55

66
.. plot::
77
:include-source: true
88
:alt: Illustration of the newly added \text command, showing that it renders as normal text, including spaces, despite being part of an equation. Also show that a dash is not rendered as a minus when part of a \text command.
99

10-
import matplotlib.pyplot as plt
11-
plt.text(0.1, 0.5, r"$a = \sin(\phi) \text{ such that } \phi = \frac{x}{y}$")
12-
plt.text(0.1, 0.3, r"$\text{dashes (-) are retained}$")
10+
import matplotlib.pyplot as plt
11+
plt.text(0.1, 0.5, r"$a = \sin(\phi) \text{ such that } \phi = \frac{x}{y}$")
12+
plt.text(0.1, 0.3, r"$\text{dashes (-) are retained}$")

0 commit comments

Comments
 (0)