SourceForge logo
SourceForge logo
Menu

matplotlib-devel

From: Maria K. <mar...@ut...> - 2005年07月21日 16:00:08
Hi,
I was creating a legend with the location variable being set to 'best'. However
when my graph contained only one point, the matplotlib code produced an error. I
found that the branch that handles the "one point case" passes the arguments to
the bbox.contains call incorrectly. I am using cvs version of the library.
The following is the patch for the problem: (Note that I edited the installed file)
--- legend.py 2005年05月20日 12:18:34.000000000 -0400
+++ /usr/lib/python2.4/site-packages/matplotlib/legend.py 2005年07月21日
11:25:08.576508496 -0400
@@ -51,7 +51,7 @@
 return False
 if n == 1:
- return bbox.contains(line[0])
+ return bbox.contains(line[0][0], line[0][1])
 p1 = line[0]
 for p2 in line[1:]:
Best regards,
Maria Khomenko
Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.
Thanks for helping keep SourceForge clean.
X





Briefly describe the problem (required):
Upload screenshot of ad (required):
Select a file, or drag & drop file here.
Screenshot instructions:

Click URL instructions:
Right-click on the ad, choose "Copy Link", then paste here →
(This may not be possible with some types of ads)

More information about our ad policies

Ad destination/click URL:

AltStyle によって変換されたページ (->オリジナル) /