diff --git a/README.rst b/README.rst index c6d8829..e7f0881 100644 --- a/README.rst +++ b/README.rst @@ -88,7 +88,7 @@ To use the stylesheet, near the beginning your python script type :: for example :: from bg_mpl_stylesheets.styles import all_styles - plt.style.use(all_styles["bg_style"]) + plt.style.use(all_styles["bg-style"]) If you wish to use BillingeGroup stylesheet as the default style for all your plots, please follow these steps. @@ -132,7 +132,7 @@ You can also update style parameters locally by using the matplotlib style conte plt.ylabel('some numbers') plt.show() -Here are a snapshot of values in ``all_styles["bg_style"]`` sheet which you may override with ``rc.parms`` to fine tune things: :: +Here are a snapshot of values in ``all_styles["bg-style"]`` sheet which you may override with ``rc.parms`` to fine tune things: :: 'lines.linewidth': 2.50, 'lines.markeredgewidth': 0.25, diff --git a/example/color_cycles.py b/example/color_cycles.py index ac36cae..402f9ec 100644 --- a/example/color_cycles.py +++ b/example/color_cycles.py @@ -5,7 +5,7 @@ # please read the README about how to install the group plot style package # and how to import it and use -plt.style.use(all_styles["bg_style"]) +plt.style.use(all_styles["bg-style"]) x = np.arange(0, 1, 0.01) diff --git a/example/plot.py b/example/plot.py index fa2c52e..9464dea 100644 --- a/example/plot.py +++ b/example/plot.py @@ -5,7 +5,7 @@ # please read the README about how to install the group plot style package # and how to import it and use -plt.style.use(all_styles["bg_style"]) +plt.style.use(all_styles["bg-style"]) # load PDF data r, gcalc, dr, dg, gdiff = loadData("example/CdSe_data.fgr").T diff --git a/news/tutorial.rst b/news/tutorial.rst index b466c7f..6621d06 100644 --- a/news/tutorial.rst +++ b/news/tutorial.rst @@ -4,7 +4,7 @@ **Changed:** -* +* key name in the style dictionary from all_styles["bg_style"] to all_styles["bg-style"] **Deprecated:** @@ -16,7 +16,6 @@ **Fixed:** -* key name in the style dictionary from all_styles["bg-style"] to all_styles["bg_style"] in README.md * URLs referring to the organization in README.md **Security:** diff --git a/src/bg_mpl_stylesheets/styles.py b/src/bg_mpl_stylesheets/styles.py index e561759..b9e809d 100644 --- a/src/bg_mpl_stylesheets/styles.py +++ b/src/bg_mpl_stylesheets/styles.py @@ -102,7 +102,7 @@ def update_style_with_latex(style): return style -all_styles = {"bg_style": bg_style} +all_styles = {"bg-style": bg_style} for key, style in all_styles.items(): all_styles.update({key: update_style_with_latex(style)}) diff --git a/src/bg_mpl_stylesheets/tests/test_bg_mpl_stylesheet.py b/src/bg_mpl_stylesheets/tests/test_bg_mpl_stylesheet.py index f4980fb..fe5907f 100644 --- a/src/bg_mpl_stylesheets/tests/test_bg_mpl_stylesheet.py +++ b/src/bg_mpl_stylesheets/tests/test_bg_mpl_stylesheet.py @@ -4,7 +4,7 @@ def test_update_style_with_latex(): - actual = styles.update_style_with_latex(styles.all_styles["bg_style"]) + actual = styles.update_style_with_latex(styles.all_styles["bg-style"]) expected = expected_style assert expected == actual