Title: POC: make scaling optional in Collection.get_linestyle by rcomer · Pull Request #29304 · matplotlib/matplotlib · GitHub
Open Graph Title: POC: make scaling optional in Collection.get_linestyle by rcomer · Pull Request #29304 · matplotlib/matplotlib
X Title: POC: make scaling optional in Collection.get_linestyle by rcomer · Pull Request #29304 · matplotlib/matplotlib
Description: PR summary Currently Collection.get_linestyle() returns the scaled dash pattern, i.e. the pattern multiplied by the linewidth. This is inconsistent with the equivalent method on Line2D and Patch (#17316 (comment)). This PR introduces the scaled parameter, to make this behaviour optional. For now I have set the default to False to demonstrate that very little seems to be relying on the current scaled behaviour. Obviously we would need a deprecation period before we can do that for real. As shown by the new test, this allows us to fix the case noted at #28298 (comment). It does not fix the original case from that issue as we just move the error to here: matplotlib/lib/matplotlib/patches.py Line 603 in a23ef5a gc.set_dashes(*self._dash_pattern) So I think we need some version of #29302 for that case. PR checklist "closes #0000" is in the body of the PR description to link the related issue new and changed code is tested Plotting related features are demonstrated in an example New Features and API Changes are noted with a directive and release note Documentation complies with general and docstring guidelines
Open Graph Description: PR summary Currently Collection.get_linestyle() returns the scaled dash pattern, i.e. the pattern multiplied by the linewidth. This is inconsistent with the equivalent method on Line2D and Patch ...
X Description: PR summary Currently Collection.get_linestyle() returns the scaled dash pattern, i.e. the pattern multiplied by the linewidth. This is inconsistent with the equivalent method on Line2D and Patch ...
Opengraph URL: https://github.com/matplotlib/matplotlib/pull/29304
X: @github
Domain: github.com
| route-pattern | /:user_id/:repository/pull/:id/files(.:format) |
| route-controller | pull_requests |
| route-action | files |
| fetch-nonce | v2:23db9aec-8f78-05c3-caa5-f530a1e9fed3 |
| current-catalog-service-hash | ae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b |
| request-id | E232:69662:493EA72:663888B:6A4F8077 |
| html-safe-nonce | 00d09424eaa50468df4c85051c10e796302abed98ab8787cb3e36148a57bbabd |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJFMjMyOjY5NjYyOjQ5M0VBNzI6NjYzODg4Qjo2QTRGODA3NyIsInZpc2l0b3JfaWQiOiI2MTA5NDk4MjY5MTc5NTQzNjcxIiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0= |
| visitor-hmac | ba3e2d7558d7cd8412053ae96737ccd4868bb125f5f82eda6aed2cd0e2d1925d |
| hovercard-subject-tag | pull_request:2234511794 |
| github-keyboard-shortcuts | repository,pull-request-list,pull-request-conversation,pull-request-files-changed,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/matplotlib/matplotlib/pull/29304/files |
| twitter:image | https://avatars.githubusercontent.com/u/10599679?s=400&v=4 |
| twitter:card | summary_large_image |
| og:image | https://avatars.githubusercontent.com/u/10599679?s=400&v=4 |
| og:image:alt | PR summary Currently Collection.get_linestyle() returns the scaled dash pattern, i.e. the pattern multiplied by the linewidth. This is inconsistent with the equivalent method on Line2D and Patch ... |
| og:site_name | GitHub |
| og:type | object |
| hostname | github.com |
| expected-hostname | github.com |
| None | b92d11c0aa4a77d54ef4af1078b6a15fb5a70a215b30c4ecf28889d5a8e656d9 |
| turbo-cache-control | no-preview |
| diff-view | unified |
| 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 full-width |
| disable-turbo | true |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 4b249b445842943ed31549e027f57a8ade9881ed |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width