SourceForge logo
SourceForge logo
Menu

matplotlib-devel

From: Stan W. <sta...@nr...> - 2010年12月10日 21:07:22
Attachments: corners.png
import matplotlib.pyplot as plt
fig = plt.figure()
axes = fig.add_subplot(1, 1, 1)
for x in (12, -12):
 for y in (12, -12):
 axes.annotate('X', (x, y), xycoords='axes points', 
 color='r', ha='center', va='center')
plt.show()
From: Jae-Joon L. <lee...@gm...> - 2010年12月13日 10:24:40
Attachments: fix_annotation.diff
I believe this was recently introduced when I refactored the annotation code.
Attached is a preliminary fix. So, please test it if you can.
Since the change during the refactoring was rather significant, I'm
not 100% sure if this will restore the old behavior without affecting
the new functionality. The examples I tried (including yours) seem to
work fine. I'll test this myself a few more days, and commit to the
svn.
I personally think it is better to use "offset points" for these cases
which makes the internal logic much simpler.
Regards,
-JJ
On Sat, Dec 11, 2010 at 6:07 AM, Stan West <sta...@nr...> wrote:
> Hi. The docs for Annotation [1] say that negative coordinates given for [
> figure | axes ] [ points | pixels ] xycoords are to be interpreted relative
> to the top-right corner, but I found that they act relative to the
> bottom-left corner as for positive coordinates. This can be seen in the
> attached script and in the annotation_demo.py example [2], where the string
> "bottom right (points)" bleeds off the left edge of the figure.
>
> [1]
> http://matplotlib.sourceforge.net/api/artist_api.html#matplotlib.text.Annotation
>
> [2]
> http://matplotlib.sourceforge.net/examples/pylab_examples/annotation_demo.html
>
> ------------------------------------------------------------------------------
> Oracle to DB2 Conversion Guide: Learn learn about native support for PL/SQL,
> new data types, scalar functions, improved concurrency, built-in packages,
> OCI, SQL*Plus, data movement tools, best practices and more.
> http://p.sf.net/sfu/oracle-sfdev2dev
> _______________________________________________
> Matplotlib-devel mailing list
> Mat...@li...
> https://lists.sourceforge.net/lists/listinfo/matplotlib-devel
>
>
From: Stan W. <sta...@nr...> - 2010年12月22日 14:49:49
> From: Jae-Joon Lee [mailto:lee...@gm...] 
> Sent: Monday, December 13, 2010 05:24
> 
> Attached is a preliminary fix. So, please test it if you can.
Thank you. Your fix seems to do the trick.
> I personally think it is better to use "offset points" for these cases
> which makes the internal logic much simpler.
I can see that, and that's what I was using as a work-around.
From: Jae-Joon L. <lee...@gm...> - 2010年12月29日 02:56:59
The patch is applied to the maintenance branch (r8846) and the trunk (r8847).
-JJ
On Wed, Dec 22, 2010 at 11:49 PM, Stan West <sta...@nr...> wrote:
>> From: Jae-Joon Lee [mailto:lee...@gm...]
>> Sent: Monday, December 13, 2010 05:24
>>
>> Attached is a preliminary fix. So, please test it if you can.
>
> Thank you. Your fix seems to do the trick.
>
>> I personally think it is better to use "offset points" for these cases
>> which makes the internal logic much simpler.
>
> I can see that, and that's what I was using as a work-around.
>
>
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 によって変換されたページ (->オリジナル) /