FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

MNT: Discourage alternate strings for 'none' linestyle by timhoffm · Pull Request #29343 · matplotlib/matplotlib · GitHub

Repository navigation

MNT: Discourage alternate strings for 'none' linestyle - #29343

Merged
story645 merged 1 commit into
matplotlib:mainfrom
timhoffm:mnt-discourage-linestyle
Dec 19, 2024
Merged

story645 merged 1 commit into
matplotlib:mainfrom
timhoffm:mnt-discourage-linestyle

Conversation

timhoffm commented Dec 18, 2024 •
edited
Loading

Copy link
Copy Markdown
Member

Inspired by but independent of the discussion around the representation of linestyles #29304.

For other linestyles we have a short visual representation (e.g. "--") and a name (e.g."dashed"). "No linestyle" currently has four accepted writings "", " ", "none", "None".

This PR recommends only to use "" (visual representation) and "none" (named representation). It discourages " " and "None". This should guide users towards more canonical usage. We may later decide whether to deprecate the alternatives.

Note also, that we have not used the alternatives in examples.

timhoffm added Maintenance API: consistency Consistency of the matplotlib API, including naming, behavior, defaults, … labels Dec 18, 2024
Comment thread lib/matplotlib/inset.py Outdated
Inspired by but independent of the discussion around the representation of linestyles matplotlib#29304.

For other linestyles we have a short visual representation (e.g. "--") and a name (dashed "dashed"). No linestyle currently has four accepted writings "", " ", "none", "None".

This PR recommends only to use "" (visual representation) and "none" (named representation). It discourages " " and "None".  This should guide users towards more canonical usage. We may later decide whether to deprecate the alternatives.

Note also, that we have not used the alternatives in examples.
timhoffm force-pushed the mnt-discourage-linestyle branch from 39c609f to 55320d3 Compare December 19, 2024 08:26
QuLogic added this to the v3.11.0 milestone Dec 19, 2024
story645 merged commit a18354a into matplotlib:main Dec 19, 2024
timhoffm deleted the mnt-discourage-linestyle branch December 19, 2024 12:04
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

API: consistency Consistency of the matplotlib API, including naming, behavior, defaults, … Maintenance

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants


Back | FazBrowse Home | New Git URL