-
Notifications
You must be signed in to change notification settings - Fork 29
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #65 from bobleesj/recut
Recookiecut
- Loading branch information
Showing
23 changed files
with
231 additions
and
246 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains 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 |
---|---|---|
@@ -0,0 +1,12 @@ | ||
name: Check for News | ||
|
||
on: | ||
pull_request_target: | ||
branches: | ||
- main | ||
|
||
jobs: | ||
build: | ||
uses: Billingegroup/release-scripts/.github/workflows/_check-news-item.yml@v0 | ||
with: | ||
project: bg-mpl-stylesheets |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains 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 |
---|---|---|
@@ -0,0 +1,21 @@ | ||
name: CI | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
release: | ||
types: | ||
- prereleased | ||
- published | ||
workflow_dispatch: | ||
|
||
jobs: | ||
coverage: | ||
uses: Billingegroup/release-scripts/.github/workflows/_matrix-and-codecov-on-merge-to-main.yml@v0 | ||
with: | ||
project: bg-mpl-stylesheets | ||
c_extension: false | ||
headless: false | ||
secrets: | ||
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }} |
This file contains 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 |
---|---|---|
@@ -0,0 +1,14 @@ | ||
name: Build and Deploy Docs | ||
|
||
on: | ||
release: | ||
types: | ||
- published | ||
workflow_dispatch: | ||
|
||
jobs: | ||
docs: | ||
uses: Billingegroup/release-scripts/.github/workflows/_publish-docs-on-release.yml@v0 | ||
with: | ||
project: bg-mpl-stylesheets | ||
c_extension: false |
This file contains 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 |
---|---|---|
@@ -0,0 +1,16 @@ | ||
name: Tests on PR | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
pull_request: | ||
workflow_dispatch: | ||
|
||
jobs: | ||
validate: | ||
uses: Billingegroup/release-scripts/.github/workflows/_tests-on-pr.yml@v0 | ||
with: | ||
project: bg-mpl-stylesheets | ||
c_extension: false | ||
headless: false |
This file contains 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
This file contains 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
This file contains 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 |
---|---|---|
@@ -1,10 +1,10 @@ | ||
Authors | ||
======= | ||
|
||
Billinge Group and community contibutors. | ||
Billinge Group and community contributors. | ||
|
||
Contributors | ||
------------ | ||
|
||
For a list of contributors, visit | ||
https://github.com/bg-mpl-stylesheets/bg-mpl-stylesheets/graphs/contributors | ||
https://github.com/billingegroup/bg-mpl-stylesheets/graphs/contributors |
This file contains 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 |
---|---|---|
@@ -1,14 +1,12 @@ | ||
include AUTHORS.rst | ||
include LICENSE | ||
include README.rst | ||
include requirements.txt | ||
|
||
recursive-exclude * __pycache__ | ||
recursive-exclude * *.py[co] | ||
|
||
recursive-include docs *.rst conf.py Makefile make.bat | ||
|
||
include bg_mpl_stylesheets/version.py | ||
|
||
# If including data files in the package, add them like: | ||
# include path/to/data_file | ||
graft src | ||
graft tests | ||
graft requirements | ||
|
||
include AUTHORS.rst LICENSE*.rst README.rst | ||
|
||
# Exclude all bytecode files and __pycache__ directories | ||
global-exclude *.py[cod] # Exclude all .pyc, .pyo, and .pyd files. | ||
global-exclude .DS_Store # Exclude Mac filesystem artifacts. | ||
global-exclude __pycache__ # Exclude Python cache directories. | ||
global-exclude .git* # Exclude git files and directories. | ||
global-exclude .idea # Exclude PyCharm project settings. |
This file contains 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 |
---|---|---|
@@ -1,15 +1,25 @@ | ||
bg-mpl-stylesheets | ||
================== | ||
|Icon| |title|_ | ||
=============== | ||
|
||
.. |title| replace:: bg-mpl-stylesheets | ||
.. _title: https://billingegroup.github.io/bg-mpl-stylesheets | ||
|
||
.. |Icon| image:: https://avatars.githubusercontent.com/billingegroup | ||
:target: https://billingegroup.github.io/bg-mpl-stylesheets | ||
:height: 100px | ||
|
||
|PyPi| |Forge| |PythonVersion| |PR| | ||
|
||
|Codecov| |Black| |Tracking| | ||
|CI| |Codecov| |Black| |Tracking| | ||
|
||
.. |Black| image:: https://img.shields.io/badge/code_style-black-black | ||
:target: https://github.com/psf/black | ||
|
||
.. |Codecov| image:: https://codecov.io/gh/Billingegroup/bg-mpl-stylesheets/branch/main/graph/badge.svg | ||
:target: https://codecov.io/gh/Billingegroup/bg-mpl-stylesheets | ||
.. |CI| image:: https://github.com/billingegroup/bg-mpl-stylesheets/actions/workflows/matrix-and-codecov-on-merge-to-main.yml/badge.svg | ||
:target: https://github.com/billingegroup/bg-mpl-stylesheets/actions/workflows/matrix-and-codecov-on-merge-to-main.yml | ||
|
||
.. |Codecov| image:: https://codecov.io/gh/billingegroup/bg-mpl-stylesheets/branch/main/graph/badge.svg | ||
:target: https://codecov.io/gh/billingegroup/bg-mpl-stylesheets | ||
|
||
.. |Forge| image:: https://img.shields.io/conda/vn/conda-forge/bg-mpl-stylesheets | ||
:target: https://anaconda.org/conda-forge/bg-mpl-stylesheets | ||
|
@@ -23,11 +33,11 @@ bg-mpl-stylesheets | |
:target: https://pypi.org/project/bg-mpl-stylesheets/ | ||
|
||
.. |Tracking| image:: https://img.shields.io/badge/issue_tracking-github-blue | ||
:target: https://github.com/Billingegroup/bg-mpl-stylesheets/issues | ||
:target: https://github.com/billingegroup/bg-mpl-stylesheets/issues | ||
|
||
A package for using Billinge group style files | ||
|
||
* bg-mpl-stylesheets is a Python software package that creates a standardized matplotlib figure format. This includes specialized fonts, figure border, color cycle, tick parameters, and more. | ||
* bg-mpl-stylesheets is a Python software package that creates a standardized matplotlib figure format. This includes specialized fonts, figure border, color cycle, tick parameters, and more. | ||
|
||
Citation | ||
-------- | ||
|
@@ -60,16 +70,12 @@ Then, to fully install ``bg-mpl-stylesheets`` in our active environment, run :: | |
|
||
Another option is to use ``pip`` to download and install the latest release from | ||
`Python Package Index <https://pypi.python.org>`_. | ||
To install using ``pip`` into your ``bg-mpl-stylesheets_env`` environment, we will also have to install dependencies :: | ||
|
||
pip install -r https://raw.githubusercontent.com/billingegroup/bg-mpl-stylesheets/main/requirements/run.txt | ||
|
||
and then install the package :: | ||
To install using ``pip`` into your ``bg-mpl-stylesheets_env`` environment, type :: | ||
|
||
pip install bg-mpl-stylesheets | ||
|
||
If you prefer to install from sources, after installing the dependencies, obtain the source archive from | ||
`GitHub <https://github.com/Billingegroup/bg-mpl-stylesheets/>`_. Once installed, ``cd`` into your ``bg-mpl-stylesheets`` directory | ||
`GitHub <https://github.com/billingegroup/bg-mpl-stylesheets/>`_. Once installed, ``cd`` into your ``bg-mpl-stylesheets`` directory | ||
and run the following :: | ||
|
||
pip install . | ||
|
@@ -81,7 +87,7 @@ Usage | |
By default the package uses LaTeX fonts for mathematical symbols. This feature requires a Latex package on your computer. It is not required for the use of the style-sheet but gives better results for things like angstrom symbols. Matplotlib will look for your installed latex package, for example TeXLive or MikTex. If it can't find a latex package it will look for non-latex font replacements. | ||
|
||
To use the stylesheet, near the beginning your python script type :: | ||
|
||
from bg_mpl_stylesheets.styles import all_styles | ||
plt.style.use(all_styles["<style-name>"]) | ||
|
||
|
@@ -113,7 +119,7 @@ Not that the ``rcParams`` are global. It can get very confusing if these are upd | |
import matplotlib.pyplot as plt | ||
|
||
@mpl.rc_context({'lines.linewidth': 1, 'axes.linewidth': 0.7, 'xtick.major.size': | ||
0.7, 'xtick.major.width': 0.7, 'xtick.labelsize': 5, 'legend.frameon': False, | ||
0.7, 'xtick.major.width': 0.7, 'xtick.labelsize': 5, 'legend.frameon': False, | ||
'legend.loc': 'best', 'font.size': 5, 'axes.labelsize': 5, 'ytick.left': False, | ||
'ytick.labelleft': False, 'ytick.right': False | ||
}) | ||
|
@@ -210,7 +216,7 @@ You may select a specific color to plot from `Colors`: :: | |
# if you know the hex and need the name. E.g., you want to make the plot shown here | ||
for i, hex in enumerate(cycle): | ||
ax.plot(x, y + offset * i, label=Colors(hex).name, color=hex, linestyle="-") | ||
|
||
Color list | ||
---------------- | ||
|
||
|
@@ -271,7 +277,7 @@ Support and Contribute | |
|
||
`Diffpy user group <https://groups.google.com/g/diffpy-users>`_ is the discussion forum for general questions and discussions about the use of bg-mpl-stylesheets. Please join the bg-mpl-stylesheets users community by joining the Google group. The bg-mpl-stylesheets project welcomes your expertise and enthusiasm! | ||
|
||
If you see a bug or want to request a feature, please `report it as an issue <https://github.com/Billingegroup/bg-mpl-stylesheets/issues>`_ and/or `submit a fix as a PR <https://github.com/Billingegroup/bg-mpl-stylesheets/pulls>`_. You can also post it to the `Diffpy user group <https://groups.google.com/g/diffpy-users>`_. | ||
If you see a bug or want to request a feature, please `report it as an issue <https://github.com/billingegroup/bg-mpl-stylesheets/issues>`_ and/or `submit a fix as a PR <https://github.com/billingegroup/bg-mpl-stylesheets/pulls>`_. You can also post it to the `Diffpy user group <https://groups.google.com/g/diffpy-users>`_. | ||
|
||
Feel free to fork the project and contribute. To install bg-mpl-stylesheets | ||
in a development mode, with its sources being directly used by Python | ||
|
@@ -294,11 +300,9 @@ trying to commit again. | |
|
||
Improvements and fixes are always appreciated. | ||
|
||
Before contribuing, please read our `Code of Conduct <https://github.com/Billingegroup/bg-mpl-stylesheets/blob/main/CODE_OF_CONDUCT.rst>`_. | ||
|
||
|
||
Before contribuing, please read our `Code of Conduct <https://github.com/billingegroup/bg-mpl-stylesheets/blob/main/CODE_OF_CONDUCT.rst>`_. | ||
|
||
Contact | ||
------- | ||
|
||
For more information on bg-mpl-stylesheets please email Prof. Simon Billinge at [email protected]. | ||
For more information on bg-mpl-stylesheets please visit the project `web-page <https://billingegroup.github.io/>`_ or email Prof. Simon Billinge at [email protected]. |
Oops, something went wrong.