Title: Mark artist property aliases explicitly by timhoffm · Pull Request #22749 · matplotlib/matplotlib · GitHub
Open Graph Title: Mark artist property aliases explicitly by timhoffm · Pull Request #22749 · matplotlib/matplotlib
X Title: Mark artist property aliases explicitly by timhoffm · Pull Request #22749 · matplotlib/matplotlib
Description: PR Summary This is a first step for making artist properties explicit. Overall goal We call the variables associated with getters and setters of Artists artist properties. e.g. linestyle is an artist property of Line2D. Artist properties can have aliases and are often used as keyword arguments to artist factory functions. Issue: We don't don't declare artist properties explicitly, but instead try to infer them based on heuristic rules, mainly in ArtistInspector. This is cumbersome and fragile because people might not be aware of these rules when they add new properties or change existing ones. Solution: The setters and getters assoicated with artist properties should be explicitly marked as such by adding an attribute _artist_property to these methods, usually via a decorator. This PR introduces the _artist_property attribute, and the underlying datastructure ArtistPropertyInfo. The datastructure already contains kwdoc (c.f. #22699) and is_alias. uses the is_alias info to replicate ArtistInsprector.is_alias() Later PRs will replace more and more of the ArtistInspector logic, such as get_setters(), get_valid_values() / kwdocs; properties(). But for that we have to massively introduce the decorator and therefore it's better to do it step by step.
Open Graph Description: PR Summary This is a first step for making artist properties explicit. Overall goal We call the variables associated with getters and setters of Artists artist properties. e.g. linestyle is an arti...
X Description: PR Summary This is a first step for making artist properties explicit. Overall goal We call the variables associated with getters and setters of Artists artist properties. e.g. linestyle is an arti...
Opengraph URL: https://github.com/matplotlib/matplotlib/pull/22749
X: @github
Domain: github.com
| route-pattern | /:user_id/:repository/pull/:id/files(.:format) |
| route-controller | pull_requests |
| route-action | files |
| fetch-nonce | v2:5b28f7c4-66e8-9e91-9805-75fd237c67a2 |
| current-catalog-service-hash | ae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b |
| request-id | 80D2:B6C89:9E628F0:DD84068:6A50B85E |
| html-safe-nonce | 09322657bd1baa919320bfd51c6db76d1198b1a64e1fdcc55190addbc65cedb8 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI4MEQyOkI2Qzg5OjlFNjI4RjA6REQ4NDA2ODo2QTUwQjg1RSIsInZpc2l0b3JfaWQiOiI2NDI4NjE3MzExMzg5NzkyMzUwIiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0= |
| visitor-hmac | 57c79fa1be820ba1e4d5a009bed4cb1d43df6a51d36d6a103b2fbd6e0c8fe1c5 |
| hovercard-subject-tag | pull_request:896629329 |
| 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/22749/files |
| twitter:image | https://avatars.githubusercontent.com/u/2836374?s=400&v=4 |
| twitter:card | summary_large_image |
| og:image | https://avatars.githubusercontent.com/u/2836374?s=400&v=4 |
| og:image:alt | PR Summary This is a first step for making artist properties explicit. Overall goal We call the variables associated with getters and setters of Artists artist properties. e.g. linestyle is an arti... |
| og:site_name | GitHub |
| og:type | object |
| hostname | github.com |
| expected-hostname | github.com |
| None | 63772747707af4093f0d5fc7aa1bb3bb55f412a9865207c4f421aa34c64cc404 |
| 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 | ded53fe94e3ff1bb4dbf8cc77e285396c92580fb |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width