From: Jae-Joon L. <lee...@gm...> - 2009-10-07 16:13:20
|
Jason, This is now fixed in the svn. http://matplotlib.svn.sourceforge.net/viewvc/matplotlib/trunk/matplotlib/lib/matplotlib/patches.py?r1=7840&r2=7857 Meanwhile, you may use the following workaround. import matplotlib import pylab from matplotlib.path import Path if __name__ == '__main__': pylab.clf() ax = pylab.axes([0,0,1,1]) ax.add_line(matplotlib.lines.Line2D((2, 5), (0.75, 6))) arc = matplotlib.patches.Arc((2, 0), 1.5, 1.5, 0.0, 0, 180.0, fill=False) arc._path = Path.arc(arc.theta1, arc.theta2) ax.add_patch(arc) ax.axis('equal') Note that the current pathces.Arc may update its _path during draw(). So, you may need to do arc._path = Path.arc(arc.theta1, arc.theta2) whenever correct extent of the arc is required (i.e., before calling axis). Regards, -JJ On Sun, Oct 4, 2009 at 11:51 PM, Jason Sewall <jas...@gm...> wrote: > On Sun, Oct 4, 2009 at 11:45 PM, Eric Firing <ef...@ha...> wrote: >> Use the Axes.set_aspect() method for full control of the aspect ratio, and >> of what gets changed to preserve that aspect ratio. > > Thanks, that works great! Any ideas about Arc's effect on the 'tight' bounds? > > ------------------------------------------------------------------------------ > Come build with us! The BlackBerry® Developer Conference in SF, CA > is the only developer event you need to attend this year. Jumpstart your > developing skills, take BlackBerry mobile applications to market and stay > ahead of the curve. Join us from November 9-12, 2009. Register now! > http://p.sf.net/sfu/devconf > _______________________________________________ > Matplotlib-users mailing list > Mat...@li... > https://lists.sourceforge.net/lists/listinfo/matplotlib-users > |