Re: [matplotlib-devel] Mathtext improvements (merging into trunk)

2007-08-29 Thread John Hunter
On 8/21/07, Michael Droettboom <[EMAIL PROTECTED]> wrote: > Darren Dale wrote: > >> I'm concerned about consistency and/or redundancy between this and the > >> new markup kwarg. I don't know whether or not "usetex" being > >> "all-or-nothing" is desirable. But we could meet in the middle by doing

Re: [matplotlib-devel] Mathtext improvements (merging into trunk)

2007-08-21 Thread Michael Droettboom
Darren Dale wrote: > On Monday 20 August 2007 10:18:27 am Michael Droettboom wrote: >> On a related note, there was a recent thread on matplotlib-users about >> usetex being a global setting: >> >> http://www.mail-archive.com/[EMAIL PROTECTED]/msg04101 >> .html >> >> I'm concerned about consistency

Re: [matplotlib-devel] Mathtext improvements (merging into trunk)

2007-08-21 Thread Darren Dale
On Monday 20 August 2007 10:18:27 am Michael Droettboom wrote: > On a related note, there was a recent thread on matplotlib-users about > usetex being a global setting: > > http://www.mail-archive.com/[EMAIL PROTECTED]/msg04101 >.html > > I'm concerned about consistency and/or redundancy between th

Re: [matplotlib-devel] Mathtext improvements (merging into trunk)

2007-08-20 Thread Michael Droettboom
Sorry for taking so long to respond -- I was at SciPy and wanted to make sure I had the time to sit down and look at this before responding. Paul Kienzle wrote: > On Thu, Aug 02, 2007 at 10:31:04AM -0400, Michael Droettboom wrote: >> I don't know if we ever reached consensus on how to specify mat

Re: [matplotlib-devel] Mathtext improvements (merging into trunk)

2007-08-14 Thread Paul Kienzle
On Thu, Aug 02, 2007 at 10:31:04AM -0400, Michael Droettboom wrote: > I don't know if we ever reached consensus on how to specify math text > vs. regular text. I agree with Eric that it's down to two options: > using a new kw argument (probably format="math" to be most future-proof) > or Math('

Re: [matplotlib-devel] Mathtext improvements (merging into trunk)

2007-08-02 Thread Eric Firing
Darren Dale wrote: [...] > > How about markup="TeX" then? "markup" is a good kwarg for this; it is descriptive and won't be confused with anything else. Eric > >> And yes, having a rcoption default seems like it could be handy. > ---

Re: [matplotlib-devel] Mathtext improvements (merging into trunk)

2007-08-02 Thread Darren Dale
On Thursday 02 August 2007 11:03:09 am Michael Droettboom wrote: > Darren Dale wrote: > > On Thursday 02 August 2007 10:42:17 am John Hunter wrote: > >> On 8/2/07, Michael Droettboom <[EMAIL PROTECTED]> wrote: > >>> I don't know if we ever reached consensus on how to specify math text > >>> vs. reg

Re: [matplotlib-devel] Mathtext improvements (merging into trunk)

2007-08-02 Thread Michael Droettboom
Darren Dale wrote: > On Thursday 02 August 2007 10:42:17 am John Hunter wrote: > >> On 8/2/07, Michael Droettboom <[EMAIL PROTECTED]> wrote: >> >>> I don't know if we ever reached consensus on how to specify math text >>> vs. regular text. I agree with Eric that it's down to two options: >

Re: [matplotlib-devel] Mathtext improvements (merging into trunk)

2007-08-02 Thread Darren Dale
On Thursday 02 August 2007 10:42:17 am John Hunter wrote: > On 8/2/07, Michael Droettboom <[EMAIL PROTECTED]> wrote: > > I don't know if we ever reached consensus on how to specify math text > > vs. regular text. I agree with Eric that it's down to two options: > > using a new kw argument (probabl

Re: [matplotlib-devel] Mathtext improvements (merging into trunk)

2007-08-02 Thread John Hunter
On 8/2/07, Michael Droettboom <[EMAIL PROTECTED]> wrote: > I don't know if we ever reached consensus on how to specify math text > vs. regular text. I agree with Eric that it's down to two options: > using a new kw argument (probably format="math" to be most future-proof) > or Math('string'). I d

Re: [matplotlib-devel] Mathtext improvements (merging into trunk)

2007-08-02 Thread Michael Droettboom
I don't know if we ever reached consensus on how to specify math text vs. regular text. I agree with Eric that it's down to two options: using a new kw argument (probably format="math" to be most future-proof) or Math('string'). I don't think I have enough "historical perspective" to really m

Re: [matplotlib-devel] Mathtext improvements (merging into trunk)

2007-07-27 Thread Eric Firing
John Hunter wrote: > On 7/26/07, Darren Dale <[EMAIL PROTECTED]> wrote: >>> where Math is a wrapper object that signals to "text" that its contents >>> are to be passed to the mathtext interpreter. >> I would like to voice my opinion against this idea. I think the backward >> imcompatibility will b

Re: [matplotlib-devel] Mathtext improvements (merging into trunk)

2007-07-27 Thread Darren Dale
On Friday 27 July 2007 08:38:49 am Michael Droettboom wrote: > If we go with another delimiter, there are others in TeX to choose > from. Plain TeX uses $$ for display math, and LaTeX uses \[, \]. Both > of these are less likely to be legitimate literals. While display math > normally implies th

Re: [matplotlib-devel] Mathtext improvements (merging into trunk)

2007-07-27 Thread Gael Varoquaux
On Fri, Jul 27, 2007 at 08:52:27AM -0400, Michael Droettboom wrote: > Using this "mathtext=True" option (as opposed to using a delimiter that > TeX doesn't understand) or something else entirely, would certainly make > it easier to make usetex vs. not usetex more consistent. I think so to. > Mo

Re: [matplotlib-devel] Mathtext improvements (merging into trunk)

2007-07-27 Thread Michael Droettboom
Gael Varoquaux wrote: > On Fri, Jul 27, 2007 at 08:38:49AM -0400, Michael Droettboom wrote: > >>> text(x, y, 'what is the $\sin(x)$', mathtext=True) >>> > > >> Except for the backward incompatibility, I like this because it is explicit. >> > > Juust a data point for the discussion

Re: [matplotlib-devel] Mathtext improvements (merging into trunk)

2007-07-27 Thread Gael Varoquaux
On Fri, Jul 27, 2007 at 08:38:49AM -0400, Michael Droettboom wrote: > > text(x, y, 'what is the $\sin(x)$', mathtext=True) > Except for the backward incompatibility, I like this because it is explicit. Juust a data point for the discussion. I think it would be very nice if a script gave the same

Re: [matplotlib-devel] Mathtext improvements (merging into trunk)

2007-07-27 Thread Michael Droettboom
John Hunter wrote: > Option 1 is to educate them, and require them to \$ > quote that symbol. Option 2 is to enable a text property eg mathtext, > and do > > text(x, y, 'what is the $\sin(x)$', mathtext=True) > Except for the backward incompatibility, I like this because it is explicit. > Optio

Re: [matplotlib-devel] Mathtext improvements (merging into trunk)

2007-07-27 Thread Jouni K . Seppänen
"John Hunter" <[EMAIL PROTECTED]> writes: > I'm on the fence as to how to handle this case. The majority of our > users will think of $ as the US currency symbol, and will have never > heard of TeX. Those users are probably also not so likely to want to use mathtext, so there could be an rc sett

Re: [matplotlib-devel] Mathtext improvements (merging into trunk)

2007-07-26 Thread Fernando Perez
On 7/26/07, Darren Dale <[EMAIL PROTECTED]> wrote: > On Thursday 26 July 2007 9:05:41 pm Fernando Perez wrote: > > This sounds to me like a good case for Guido's mantra of NOT putting > > keywords in functions and instead just making two separate functions. > > Why not just > > > > text(x,y,"This

Re: [matplotlib-devel] Mathtext improvements (merging into trunk)

2007-07-26 Thread Darren Dale
On Thursday 26 July 2007 9:05:41 pm Fernando Perez wrote: > [ That was meant for the list, sorry ] > > On 7/26/07, John Hunter <[EMAIL PROTECTED]> wrote: > > I'm on the fence as to how to handle this case. The majority of our > > users will think of $ as the US currency symbol, and will have never

Re: [matplotlib-devel] Mathtext improvements (merging into trunk)

2007-07-26 Thread Fernando Perez
[ That was meant for the list, sorry ] On 7/26/07, John Hunter <[EMAIL PROTECTED]> wrote: > I'm on the fence as to how to handle this case. The majority of our > users will think of $ as the US currency symbol, and will have never > heard of TeX. Option 1 is to educate them, and require them t

Re: [matplotlib-devel] Mathtext improvements (merging into trunk)

2007-07-26 Thread John Hunter
On 7/26/07, Darren Dale <[EMAIL PROTECTED]> wrote: > > where Math is a wrapper object that signals to "text" that its contents > > are to be passed to the mathtext interpreter. > > I would like to voice my opinion against this idea. I think the backward > imcompatibility will be rare, and does not

Re: [matplotlib-devel] Mathtext improvements (merging into trunk)

2007-07-26 Thread Darren Dale
On Thursday 26 July 2007 5:54:18 pm Jouni K. Seppänen wrote: > It seems that the improvements finally allow users to mix mathtext with > ordinary text, as in 'foo $a=b^c+d$ bar', which I believe has been > requested a lot. This is really cool, but I think it causes another > backward incompatibilit

Re: [matplotlib-devel] Mathtext improvements (merging into trunk)

2007-07-26 Thread Jouni K . Seppänen
It seems that the improvements finally allow users to mix mathtext with ordinary text, as in 'foo $a=b^c+d$ bar', which I believe has been requested a lot. This is really cool, but I think it causes another backward incompatibility: you could use dollar signs in text strings (except if you wanted a

Re: [matplotlib-devel] Mathtext improvements (merging into trunk)

2007-07-25 Thread Michael Droettboom
John Hunter wrote: > On 7/25/07, Michael Droettboom <[EMAIL PROTECTED]> wrote: > >> It's been fun working through this. You may want to check out >> mathtext_examples.py in my branch for examples that exercise other new >> features. > > Maybe you haven't committed it? Doh! Try now. Cheers, Mike

Re: [matplotlib-devel] Mathtext improvements (merging into trunk)

2007-07-25 Thread John Hunter
On 7/25/07, Michael Droettboom <[EMAIL PROTECTED]> wrote: > It's been fun working through this. You may want to check out > mathtext_examples.py in my branch for examples that exercise other new > features. Maybe you haven't committed it? [EMAIL PROTECTED]:examples> pwd /home/titan/johnh/pytho

Re: [matplotlib-devel] Mathtext improvements (merging into trunk)

2007-07-25 Thread Michael Droettboom
John Hunter wrote: > On 7/25/07, Michael Droettboom <[EMAIL PROTECTED]> wrote: >> The new mathtext with an underlying TeX-like box model is passing all >> unit tests for all backends. I'm now at a point where I'd like to merge >> this back into the trunk, but I'd like some feedback as to how to be

Re: [matplotlib-devel] Mathtext improvements (merging into trunk)

2007-07-25 Thread Jouni K . Seppänen
Gael Varoquaux <[EMAIL PROTECTED]> writes: > On Wed, Jul 25, 2007 at 11:36:17AM -0500, John Hunter wrote: >> * There is a lot of space between the \prod symbol and the rest of >> the expression and between the \mathcal{R} and the \prod symbol -- >> what controls this? It looks like it is being a

Re: [matplotlib-devel] Mathtext improvements (merging into trunk)

2007-07-25 Thread Jouni K . Seppänen
Michael Droettboom <[EMAIL PROTECTED]> writes: > In the existing mathtext implementation, font style changes affect the > following group. For example, in $\cal{R} x$, only the R will be in > calligraphic face. In TeX, however, font style markers stay in effect > until the next font style marker o

Re: [matplotlib-devel] Mathtext improvements (merging into trunk)

2007-07-25 Thread Gael Varoquaux
On Wed, Jul 25, 2007 at 11:36:17AM -0500, John Hunter wrote: > * There is a lot of space between the \prod symbol and the rest of > the expression and between the \mathcal{R} and the \prod symbol -- > what controls this? It looks like it is being affected by the wide > \prod subscript {i=\alpha_{

Re: [matplotlib-devel] Mathtext improvements (merging into trunk)

2007-07-25 Thread John Hunter
On 7/25/07, Michael Droettboom <[EMAIL PROTECTED]> wrote: > The new mathtext with an underlying TeX-like box model is passing all > unit tests for all backends. I'm now at a point where I'd like to merge > this back into the trunk, but I'd like some feedback as to how to best > deal with the backw

Re: [matplotlib-devel] Mathtext improvements

2007-07-16 Thread Christopher Barker
John Hunter wrote: > That or we simply adopt the TeX standard +1 TeX is widely used and well documented -- why have something almost the same? though I still think the real solution is to sue TeX itself to do the typesetting. not the way we do now, but: Parsing the DVI and laying out stuff

Re: [matplotlib-devel] Mathtext improvements

2007-07-16 Thread Darren Dale
On Monday 16 July 2007 02:32:30 pm John Hunter wrote: > On 7/16/07, Michael Droettboom <[EMAIL PROTECTED]> wrote: > > 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://matplotli

Re: [matplotlib-devel] Mathtext improvements

2007-07-16 Thread John Hunter
On 7/16/07, Michael Droettboom <[EMAIL PROTECTED]> wrote: > 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, > In general, is the goal with mathtext to become as TeX-compatible as > possible

Re: [matplotlib-devel] Mathtext improvements

2007-07-16 Thread Michael Droettboom
John Hunter wrote: > On 7/16/07, Michael Droettboom <[EMAIL PROTECTED]> wrote: >> 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

Re: [matplotlib-devel] Mathtext improvements

2007-07-16 Thread John Hunter
On 7/16/07, Michael Droettboom <[EMAIL PROTECTED]> wrote: > 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/ >