Title: Request an inaxes method in Figure to calculate whether a point is in an axes. · Issue #9821 · matplotlib/matplotlib · GitHub
Open Graph Title: Request an inaxes method in Figure to calculate whether a point is in an axes. · Issue #9821 · matplotlib/matplotlib
X Title: Request an inaxes method in Figure to calculate whether a point is in an axes. · Issue #9821 · matplotlib/matplotlib
Description: Request an inaxes method in Figure to calculate whether a point is in an axes and return the axes. i.e. def inaxes(self, xy): axes_list = [a for a in self.get_axes() if a.patch.contains_point(xy)] if len(axes_list) == 0: axes = None elif...
Open Graph Description: Request an inaxes method in Figure to calculate whether a point is in an axes and return the axes. i.e. def inaxes(self, xy): axes_list = [a for a in self.get_axes() if a.patch.contains_point(xy)] ...
X Description: Request an inaxes method in Figure to calculate whether a point is in an axes and return the axes. i.e. def inaxes(self, xy): axes_list = [a for a in self.get_axes() if a.patch.contains_point(xy)] ...
Opengraph URL: https://github.com/matplotlib/matplotlib/issues/9821
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Request an inaxes method in Figure to calculate whether a point is in an axes.","articleBody":"Request an inaxes method in Figure to calculate whether a point is in an axes and return the axes. i.e.\r\n\r\n def inaxes(self, xy):\r\n axes_list = [a for a in self.get_axes() if a.patch.contains_point(xy)]\r\n\r\n if len(axes_list) == 0:\r\n axes = None\r\n elif len(axes_list) \u003e 1: # Overlap, get the highest zorder\r\n axes_list.sort(key=lambda x: x.zorder)\r\n axes = axes_list[-1] # Use the highest zorder\r\n else:\r\n axes = axes_list[0]\r\n\r\n return axes\r\n\r\nRational: This make it easier (in my opinion) to find a method that do the requested method. Alternative is to create a LocationEvent and use the inaxes attribute. Using the LocationEvent class may trigger axes_enter_event and axes_leave_event.\r\n\r\nIn any cases a good documentation on matplotlib's coordinate and how to convert different backends' coordinate to matplotlib, most of the time flip the y axis, is needed. ","author":{"url":"https://github.com/lkjell","@type":"Person","name":"lkjell"},"datePublished":"2017-11-21T02:17:20.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":9},"url":"https://github.com/9821/matplotlib/issues/9821"}
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:cd12ccd1-9c62-0778-ed77-46164a518ce4 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | C1C0:917E1:C5D4B:108676:6A57F40C |
| html-safe-nonce | 2f6a4efb0cde5b1f1b81dbd9b04e81b7a82794754c6371ad7cb25aed3fe8d2b7 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJDMUMwOjkxN0UxOkM1RDRCOjEwODY3Njo2QTU3RjQwQyIsInZpc2l0b3JfaWQiOiIyMjkxNzkxMDYzNDE2MzA0NjUyIiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0= |
| visitor-hmac | 994841b15e24a860cf2aa12e14229c9059561e6fdf74ed8e7f8833275bce6b9f |
| hovercard-subject-tag | issue:275562891 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/matplotlib/matplotlib/9821/issue_layout |
| twitter:image | https://opengraph.githubassets.com/87e3b3d322c0f923b7ba92b2fa53a004adbcf5db031f4cf02caf25068eac2cf4/matplotlib/matplotlib/issues/9821 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/87e3b3d322c0f923b7ba92b2fa53a004adbcf5db031f4cf02caf25068eac2cf4/matplotlib/matplotlib/issues/9821 |
| og:image:alt | Request an inaxes method in Figure to calculate whether a point is in an axes and return the axes. i.e. def inaxes(self, xy): axes_list = [a for a in self.get_axes() if a.patch.contains_point(xy)] ... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | lkjell |
| hostname | github.com |
| expected-hostname | github.com |
| None | 49c8c15fabcbf356d607a90ca115c13b273e42ff8b74155de050fd229a9b0121 |
| turbo-cache-control | no-preview |
| go-import | github.com/matplotlib/matplotlib git https://github.com/matplotlib/matplotlib.git |
| octolytics-dimension-user_id | 215947 |
| octolytics-dimension-user_login | matplotlib |
| octolytics-dimension-repository_id | 1385122 |
| octolytics-dimension-repository_nwo | matplotlib/matplotlib |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 1385122 |
| octolytics-dimension-repository_network_root_nwo | matplotlib/matplotlib |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 3fb1f684e7a833eb1b2d01d39875a2b52cb4fe9b |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width