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

Re-rename builtin seaborn styles to not include a dot. by anntzer · Pull Request #23674 · matplotlib/matplotlib · GitHub

Repository navigation

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension .mplstyle  (16) .py  (3) .rst  (1) All 3 file types selected
Viewed files
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Unified
Split
Hide whitespace
Diff view
Unified
Split
Hide whitespace
4 changes: 2 additions & 2 deletions doc/api/next_api_changes/deprecations/22317-AL.rst
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
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,6 @@ seaborn styles renamed
Matplotlib currently ships many style files inspired from the seaborn
library ("seaborn", "seaborn-bright", "seaborn-colorblind", etc.) but they
have gone out of sync with the library itself since the release of seaborn
0.9. To prevent confusion, the style files have been renamed "seaborn0.8",
"seaborn0.8-bright", "seaborn0.8-colorblind", etc. Users are encouraged to
0.9. To prevent confusion, the style files have been renamed "seaborn-v0_8",
"seaborn-v0_8-bright", "seaborn-v0_8-colorblind", etc. Users are encouraged to
directly use seaborn to access the up-to-date styles.
4 changes: 2 additions & 2 deletions lib/matplotlib/style/core.py
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
Original file line number Diff line number Diff line change
Expand Up @@ -135,9 +135,9 @@ def fix_style(s):
"3.6", message="The seaborn styles shipped by Matplotlib "
"are deprecated since %(since)s, as they no longer "
"correspond to the styles shipped by seaborn. However, "
"they will remain available as 'seaborn0.8-<style>'. "
"they will remain available as 'seaborn-v0_8-<style>'. "
"Alternatively, directly use the seaborn API instead.")
s = s.replace("seaborn", "seaborn0.8")
s = s.replace("seaborn", "seaborn-v0_8")
return s

for style in map(fix_style, styles):
Expand Down
2 changes: 1 addition & 1 deletion lib/matplotlib/tests/test_style.py
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
Original file line number Diff line number Diff line change
Expand Up @@ -178,7 +178,7 @@ def test_xkcd_cm():


def test_deprecated_seaborn_styles():
with mpl.style.context("seaborn0.8-bright"):
with mpl.style.context("seaborn-v0_8-bright"):
seaborn_bright = mpl.rcParams.copy()
assert mpl.rcParams != seaborn_bright
with pytest.warns(mpl._api.MatplotlibDeprecationWarning):
Expand Down
2 changes: 1 addition & 1 deletion tutorials/colors/colors.py
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
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ def demo(sty):


demo('default')
demo('seaborn0.8')
demo('seaborn-v0_8')

###############################################################################
# The first color ``'C0'`` is the title. Each plot uses the second and third
Expand Down

Back | FazBrowse Home | New Git URL