Skip to content

Commit

Permalink
Allow different (upper) cases, and remove accent more simply
Browse files Browse the repository at this point in the history
  • Loading branch information
moble committed Sep 30, 2013
1 parent 55d081d commit c45a00a
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions sympy/printing/latex.py
Original file line number Diff line number Diff line change
Expand Up @@ -1639,15 +1639,15 @@ def translate(s):
'''
# Process accents, if any, and recurse
for key in accent_keys:
if s.endswith(key):
if s.lower().endswith(key):
if(key in ['prime', 'prm']):
# MathJax can fail on primes without braces
return "{" + translate(s.rsplit(key,1)[0]) + "}'"
return "{" + translate(s[:-len(key)]) + "}'"
if(key=='bm'):
outkey = 'boldsymbol' # MathJax doesn't know \bm
else:
outkey = key
return "\\" + outkey + "{" + translate(s.rsplit(key,1)[0]) + "}"
return "\\" + outkey + "{" + translate(s[:-len(key)]) + "}"
# Process the rest
tex = tex_greek_dictionary.get(s)
if tex:
Expand Down

0 comments on commit c45a00a

Please sign in to comment.