BUG 1594 Render a hyphen in a formula as − in HTML
authorJens Frank <jeluf@users.mediawiki.org>
Sun, 13 Mar 2005 10:59:04 +0000 (10:59 +0000)
committerJens Frank <jeluf@users.mediawiki.org>
Sun, 13 Mar 2005 10:59:04 +0000 (10:59 +0000)
math/lexer.mll

index c56c30b..a08677c 100644 (file)
@@ -47,6 +47,7 @@ rule token = parse
   | literal_mn                 { let str = Lexing.lexeme lexbuf in LITERAL (MHTMLABLEC (FONT_RM, str,str,MN,str)) }
   | literal_uf_lt              { let str = Lexing.lexeme lexbuf in LITERAL (HTMLABLEC (FONT_UFH, str,str)) }
   | delimiter_uf_lt            { let str = Lexing.lexeme lexbuf in DELIMITER (HTMLABLEC (FONT_UFH, str,str)) }
+  | "-"                                { LITERAL (HTMLABLE (FONT_UFH,"-"," &minus; "))}
   | literal_uf_op              { let str = Lexing.lexeme lexbuf in LITERAL (MHTMLABLEC (FONT_UFH, str," "^str^" ",MO,str)) }
   | delimiter_uf_op            { let str = Lexing.lexeme lexbuf in DELIMITER (MHTMLABLEC (FONT_UFH, str," "^str^" ",MO,str)) }
   | "\\" alpha +               { Texutil.find (Lexing.lexeme lexbuf) }