From: Paul T. <pau...@gm...> - 2011-10-14 00:45:32
|
On 10/13/11 3:12 PM, Paul Tremblay wrote: > I have been off of this mailing list for a while, so sorry if this > topic has been covered. I notice that a math directive has been added, > and wondered if there are any plans on using ASCIImath in this directive? > > http://www.wjagray.co.uk/maths/ASCIIMathTutorial.html > > There is an excellent javascript script to convert ASCIImath for > webpages, but I can't find anything to convert them from a shell. > Ideally, there could be python code for converting ASCIImath to > MathML, though I understand such code would probably require a lot of > work and would not be trivial. I am simply trying to find out if this > has been considered. > > It does seems ASCIImath is ideas for restructredtext. > > It seems like someone has already done the work for asciimath to mathml: http://pypi.python.org/pypi/asciimathml/0.9.3 import markdown print markdown.markdown('$$ sqrt 2 $$', ['asciimathml']) <p> <math xmlns="http://www.w3.org/1998/Math/MathML"><mstyle><msqrt><mn>2</mn></msqrt></mstyle></math> </p> Any thoughts on using this library with the math directive? |