Title: [Bug]: LineCollection, set_linestyle does not work · Issue #28545 · matplotlib/matplotlib · GitHub
Open Graph Title: [Bug]: LineCollection, set_linestyle does not work · Issue #28545 · matplotlib/matplotlib
X Title: [Bug]: LineCollection, set_linestyle does not work · Issue #28545 · matplotlib/matplotlib
Description: Bug summary in the class LineCollection, the argument linestyle has no effect neither if set directly or if set afterwards with set_linestyle or with set(linestyle='--') set_color does work. maybe its just linestyle that doesnt. Code for...
Open Graph Description: Bug summary in the class LineCollection, the argument linestyle has no effect neither if set directly or if set afterwards with set_linestyle or with set(linestyle='--') set_color does work. maybe ...
X Description: Bug summary in the class LineCollection, the argument linestyle has no effect neither if set directly or if set afterwards with set_linestyle or with set(linestyle='--') set_color does work...
Opengraph URL: https://github.com/matplotlib/matplotlib/issues/28545
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"[Bug]: LineCollection, set_linestyle does not work","articleBody":"### Bug summary\r\n\r\nin the class LineCollection, the argument linestyle has no effect neither if set directly or if set afterwards with set_linestyle or with set(linestyle='--')\r\nset_color does work. maybe its just linestyle that doesnt.\r\n\r\n### Code for reproduction\r\n\r\n```Python\r\ncoord_start = np.column_stack((x_midpts[:-1], y_midpts[:-1]))[:, np.newaxis, :]\r\ncoord_mid = np.column_stack((x, y))[:, np.newaxis, :]\r\ncoord_end = np.column_stack((x_midpts[1:], y_midpts[1:]))[:, np.newaxis, :]\r\nsegments = np.concatenate((coord_start, coord_mid, coord_end), axis=1)\r\n\r\nlc = LineCollection(segments, **default_kwargs)\r\n#lc.set_array(values) # set the colors of each segment\r\n#lc.set_linestyle(':')\r\n#lc.set_color(c)\r\nlc.set(color=c, linestyle='--')\r\n```\r\n\r\n\r\n### Actual outcome\r\n\r\nlinestyle doesnt change\r\n\r\n### Expected outcome\r\n\r\nlinestyle should change to the type i gave as input\r\n\r\n### Additional information\r\n\r\n_No response_\r\n\r\n### Operating system\r\n\r\n_No response_\r\n\r\n### Matplotlib Version\r\n\r\n3.5.3 and 3.9.1\r\n\r\n### Matplotlib Backend\r\n\r\n_No response_\r\n\r\n### Python version\r\n\r\n_No response_\r\n\r\n### Jupyter version\r\n\r\n_No response_\r\n\r\n### Installation\r\n\r\nNone","author":{"url":"https://github.com/jonpro142","@type":"Person","name":"jonpro142"},"datePublished":"2024-07-12T08:11:23.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":3},"url":"https://github.com/28545/matplotlib/issues/28545"}
| 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:8df2a122-a020-079d-006a-12f60d5739ed |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | BD6A:94837:B9F67D:FBF367:6A51EF79 |
| html-safe-nonce | 12770c1c868bc21d162c204f92402fc60f0c82d2d0381f28216973aa262202cb |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJCRDZBOjk0ODM3OkI5RjY3RDpGQkYzNjc6NkE1MUVGNzkiLCJ2aXNpdG9yX2lkIjoiNTYwMzI1OTYxMzY5MDU4OTA0OSIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | 6190a50f363fa9285039be17aa4ac363d5828afa0fc280a25e0b40129a13ccc6 |
| hovercard-subject-tag | issue:2405010486 |
| 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/28545/issue_layout |
| twitter:image | https://opengraph.githubassets.com/af0fe7358791cc17d0813a4712f640a442a73b5af8b6938665fdb8e994e4ba40/matplotlib/matplotlib/issues/28545 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/af0fe7358791cc17d0813a4712f640a442a73b5af8b6938665fdb8e994e4ba40/matplotlib/matplotlib/issues/28545 |
| og:image:alt | Bug summary in the class LineCollection, the argument linestyle has no effect neither if set directly or if set afterwards with set_linestyle or with set(linestyle='--') set_color does work. maybe ... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | jonpro142 |
| 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 | 7aed05249554b889eb33d002851a973eebcc7e91 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width