Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Collection's contains method doesn't honour offset_position attribute #1973

Merged

Conversation

mdboom
Copy link
Member

@mdboom mdboom commented May 3, 2013

The contains method of Collection objects doesn't honour the newly introduced _offset_position attribute, making it fail when _offset_position == "data".
I noticed this when trying to add a pick_event handler to a hexbin plot, which does not work properly with matplotlob 1.2.x

@ghost ghost assigned mdboom May 3, 2013
@mdboom
Copy link
Member

mdboom commented May 3, 2013

@ChrMa: Can you confirm the attached patch fixes your bug?

@pelson
Copy link
Member

pelson commented May 3, 2013

Again - looks good but needs a small test. 👍

mdboom added a commit to mdboom/matplotlib that referenced this pull request May 3, 2013
@ChrMa
Copy link
Author

ChrMa commented May 3, 2013

@mdboom: Thank you for the quick response. The fix is working perfectly.

@ChrMa
Copy link
Author

ChrMa commented May 3, 2013

As for the test, you might want to add something like picker=1 to the hexbin call to avoid getting a UserWarning about picker being None.

mdboom added a commit that referenced this pull request May 3, 2013
…_position

Collection's contains method doesn't honour offset_position attribute
@mdboom mdboom merged commit eae5e43 into matplotlib:v1.2.x May 3, 2013
@mdboom mdboom deleted the pick_path_collection_data_offset_position branch August 7, 2014 13:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants