I'm working on some improvements to the mathtext engine on a branch.  
Feel free to join in if curious, but I expect to break lots of things as 
I go.

https://matplotlib.svn.sourceforge.net/svnroot/matplotlib/branches/mathtext_mgd/

I've collected a bunch of math expressions from the source tree for use 
in regression testing.  If you have any math strings of your own that 
you want to make sure I don't break, please send them to me (probably 
should be off-list to conserve noise).

Here's the preliminary TODO list I'm working with in no particular order 
(compiled from the TODO list in mathtext.py and the list of improvements 
in mathtext2.py):

1. Deal with nested sub/superscripts, such as $x_i_j$, equivalent to 
$x_{i_j}$
2. Make the font change tags (\cal, \tt, \rm etc.) behave more like TeX, 
e.g. use ${\rm sin}$ instead of $\rm{sin}$
3. Support roman function names, e.g. $\sin$ as a shortcut for ${\rm sin}$
4. Implement \frac
5. Other layout commands, like large \sqrt (I suspect there's a very 
large list of these things and they will have to be prioritized.)
6. Support kerning (probably best put off until we have good fonts with 
kerning information to use, e.g. STIX fonts)
...

(1 and 2 are already implemented in the branch.)

I don't want to start a long thread about all the desired features for 
mathtext -- I'm sure there are lots of them.  There will need to be some 
way to prioritize, which I leave up to those on this list who have been 
around long enough to have a sense of what features are more pressing 
than others.

In general, is the goal with mathtext to become as TeX-compatible as 
possible (for some subset of standard TeX math syntax?)  The reason I 
ask is, (1) above is not valid LaTeX and raises the error "Double 
subscript".  Task (2) will break backward compatibility with existing 
matplotlib plots.  In the long run, maintaining two codebases or two 
separate paths through the same codebase probably won't scale.

Cheers,
Mike

-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Matplotlib-devel mailing list
Matplotlib-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-devel

Reply via email to