8000 Do not escape dollars if parse_math is True · matplotlib/matplotlib@9e9b8d5 · GitHub
[go: up one dir, main page]

Skip to content

Commit 9e9b8d5

Browse files
committed
Do not escape dollars if parse_math is True
1 parent 61792ca commit 9e9b8d5

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

lib/matplotlib/text.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1240,7 +1240,9 @@ def _preprocess_math(self, s):
12401240
if s == " ":
12411241
s = r"\ "
12421242
return s, "TeX"
1243-
elif self.get_parse_math() < 5AFC span class=pl-c1>and cbook.is_math_text(s):
1243+
elif not self.get_parse_math():
1244+
return s, False
1245+
elif cbook.is_math_text(s):
12441246
return s, True
12451247
else:
12461248
return s.replace(r"\$", "$"), False

0 commit comments

Comments
 (0)
0