Re: [matplotlib-devel] reimplemented legend class

2008-12-05 Thread Jae-Joon Lee
Tony, Sorry. It turned to be a bug I introduced during the update. It should be fixed in r6499. Thanks, -JJ On Fri, Dec 5, 2008 at 3:47 PM, Jae-Joon Lee <[EMAIL PROTECTED]> wrote: > Tony, > > I'll look at this problem. > Anyhow, it seems to me that it happens because the handle length is too s

Re: [matplotlib-devel] reimplemented legend class

2008-12-05 Thread Jae-Joon Lee
Tony, I'll look at this problem. Anyhow, it seems to me that it happens because the handle length is too short. Can you try longer handle length and see what happens? The code for drawing handles are mostly identical to the previous one. Regards, -JJ On Fri, Dec 5, 2008 at 1:46 PM, Tony Yu <[E

Re: [matplotlib-devel] reimplemented legend class

2008-12-05 Thread Tony Yu
On Dec 4, 2008, at 7:21 PM, Jae-Joon Lee wrote: John, I just committed changes to SVN that reflect most of your comments. I didn't add the optional transformation support yet though. I'm getting a truncated line when calling: >>> plt.legend(numpoints=1) In the legend, I see a short dashed

Re: [matplotlib-devel] reimplemented legend class

2008-12-04 Thread Jae-Joon Lee
John, I just committed changes to SVN that reflect most of your comments. I didn't add the optional transformation support yet though. On Tue, Dec 2, 2008 at 7:45 AM, John Hunter <[EMAIL PROTECTED]> wrote: > On Mon, Dec 1, 2008 at 6:00 PM, Jae-Joon Lee <[EMAIL PROTECTED]> wrote: > >> As implemen

Re: [matplotlib-devel] reimplemented legend class

2008-12-02 Thread Jae-Joon Lee
The patch is now applied to the SVN (r6479). -JJ On Tue, Dec 2, 2008 at 5:03 PM, Darren Dale <[EMAIL PROTECTED]> wrote: > This looks right to me, thank you Jae-Joon. > > > On Tue, Dec 2, 2008 at 4:55 PM, Jae-Joon Lee <[EMAIL PROTECTED]> wrote: >> >> Darren, >> >> Can you test the attached patch

Re: [matplotlib-devel] reimplemented legend class

2008-12-02 Thread Jae-Joon Lee
Darren, Can you test the attached patch and see if the legend is placed where you expected. Regards, -JJ Index: lib/matplotlib/legend.py === --- lib/matplotlib/legend.py (revision 6477) +++ lib/matplotlib/legend.py (working copy) @@

Re: [matplotlib-devel] reimplemented legend class

2008-12-02 Thread Jae-Joon Lee
I presume my changes currently only allow loc as a location code. I didn't know that loc can be a tuple (axes coordinate I guess?). But it won't be hard to fix this. I'll work on it. -JJ On Tue, Dec 2, 2008 at 4:04 PM, Darren Dale <[EMAIL PROTECTED]> wrote: > I think something broke with the rec

Re: [matplotlib-devel] reimplemented legend class

2008-12-02 Thread Darren Dale
I think something broke with the recent changes to legend. For example, in ipython -pylab: plot([1,2,3,4],label='test') legend(loc=(.1, .5)) ERROR: An unexpected error occurred while tokenizing input The following traceback may be corrupted or invalid The error message is: ('EOF in multi-line sta

Re: [matplotlib-devel] reimplemented legend class

2008-12-02 Thread John Hunter
On Mon, Dec 1, 2008 at 6:00 PM, Jae-Joon Lee <[EMAIL PROTECTED]> wrote: > As implementing an optional transformation should be trivial, I'll > just go ahead an work on it. But it seems not clear to me how to > approach this without any specific use case given. In another thread yesterday, someone

Re: [matplotlib-devel] reimplemented legend class

2008-12-01 Thread Jae-Joon Lee
Thanks John, I'll work on the revisions. > > +def set_offset(self, xy): > +""" > +set offset of the container. > + > +Accept : tuple of x,y cooridnate in display units. > > Is it worthwhile to allow other coordinate systems for the offsets > (points, data) or would thi

Re: [matplotlib-devel] reimplemented legend class

2008-12-01 Thread Andrew Straw
John Hunter wrote: > On Sun, Nov 30, 2008 at 11:53 AM, Jae-Joon Lee <[EMAIL PROTECTED]> wrote: > > >> I have been working on reimplementation of the legend class, and I >> guess it is mostly done. The biggest change is how each items are >> placed. For this, I made a simple container class("offs

Re: [matplotlib-devel] reimplemented legend class

2008-12-01 Thread John Hunter
On Sun, Nov 30, 2008 at 11:53 AM, Jae-Joon Lee <[EMAIL PROTECTED]> wrote: > I have been working on reimplementation of the legend class, and I > guess it is mostly done. The biggest change is how each items are > placed. For this, I made a simple container class("offsetbox.py"), > which can pack t