plot([1,2,3], label="Label 1") plot([2,1,3], label="Long Label 2")
leg = legend() # swap_and_right_align_legend vp = leg._legend_box._children[-1]._children[0] for c in vp._children: c._children.reverse() vp.align="right" draw() Does this close to waht you want? -JJ On Wed, Dec 9, 2009 at 12:28 AM, Jason Heeris <jason.hee...@gmail.com> wrote: > Hi, > > Is it possible to right align the text and line samples in a legend box? > > That is, instead of: > > --- First plot > --- Second plot > > ...you get: > > First plot --- > Second plot --- > > (with a fixed width font, that last one displays the right edges of > the text perfectly aligned). > > Cheers, > Jason > > ------------------------------------------------------------------------------ > Return on Information: > Google Enterprise Search pays you back > Get the facts. > http://p.sf.net/sfu/google-dev2dev > _______________________________________________ > Matplotlib-users mailing list > Matplotlib-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/matplotlib-users > ------------------------------------------------------------------------------ Return on Information: Google Enterprise Search pays you back Get the facts. http://p.sf.net/sfu/google-dev2dev _______________________________________________ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users