Title: [ENH]: ContourSet.set_paths · Issue #26340 · matplotlib/matplotlib · GitHub
Open Graph Title: [ENH]: ContourSet.set_paths · Issue #26340 · matplotlib/matplotlib
X Title: [ENH]: ContourSet.set_paths · Issue #26340 · matplotlib/matplotlib
Description: Problem To get contour labelling working with its special transforms, Cartopy has a workaround where it replaces all the paths on the ContourSet with transformed versions. This currently looks like paths = cs.get_paths() paths[:] = trans...
Open Graph Description: Problem To get contour labelling working with its special transforms, Cartopy has a workaround where it replaces all the paths on the ContourSet with transformed versions. This currently looks like...
X Description: Problem To get contour labelling working with its special transforms, Cartopy has a workaround where it replaces all the paths on the ContourSet with transformed versions. This currently looks like...
Opengraph URL: https://github.com/matplotlib/matplotlib/issues/26340
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"[ENH]: ContourSet.set_paths","articleBody":"### Problem\n\nTo get contour labelling working with its special transforms, Cartopy has a [workaround](https://github.com/SciTools/cartopy/blob/2ed668c17b4e52421f15c5be3761719c75c5311a/lib/cartopy/mpl/contour.py#L89-L108) where it replaces all the paths on the `ContourSet` with transformed versions. This currently looks like\r\n\r\n```python\r\npaths = cs.get_paths()\r\npaths[:] = transformed_paths\r\n``` \r\n\r\nwhich doesn’t smell very good.\n\n### Proposed solution\n\nThe above would smell better as \r\n\r\n```python\r\ncs.set_paths(transformed_paths)\r\n``` ","author":{"url":"https://github.com/rcomer","@type":"Person","name":"rcomer"},"datePublished":"2023-07-18T06:15:21.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":3},"url":"https://github.com/26340/matplotlib/issues/26340"}
| 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:646393ab-9200-ab46-2a66-47a48626dbad |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | D8F8:381414:17CE3:1F785:6A532837 |
| html-safe-nonce | fc6bf6f0cc88c9b93d9f88650c726ac8944e0475dddaaa09b33f50aaed5171b5 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJEOEY4OjM4MTQxNDoxN0NFMzoxRjc4NTo2QTUzMjgzNyIsInZpc2l0b3JfaWQiOiI3NTU3MTc5NDg4MDcwNzQwMDIzIiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0= |
| visitor-hmac | 851b55de3e98036fc0c13d7fc7a55dec4dca5d6074afdd0f0ba8087db8067e77 |
| hovercard-subject-tag | issue:1809201497 |
| 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/26340/issue_layout |
| twitter:image | https://opengraph.githubassets.com/57065e84201ce8ddc8144d147a039332bd97d2366642bcc85bd25d48a46c3d69/matplotlib/matplotlib/issues/26340 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/57065e84201ce8ddc8144d147a039332bd97d2366642bcc85bd25d48a46c3d69/matplotlib/matplotlib/issues/26340 |
| og:image:alt | Problem To get contour labelling working with its special transforms, Cartopy has a workaround where it replaces all the paths on the ContourSet with transformed versions. This currently looks like... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | rcomer |
| hostname | github.com |
| expected-hostname | github.com |
| None | b9a586c06a05a7a86fc7e3f4dbd03e42f6869085879aa184aa6369456dbd50fb |
| 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 | 07a982c1d40157c619b364352b704c3ce66bb332 |
| ui-target | canary-1 |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width