Skip to content

Commit

Permalink
Merge pull request #350 from nschloe/legend-opacity2
Browse files Browse the repository at this point in the history
Legend opacity2
  • Loading branch information
nschloe committed Nov 24, 2019
2 parents a670137 + 93326fa commit f06fd7c
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 6 deletions.
1 change: 1 addition & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ tag:
@echo "Tagging v$(VERSION)..."
git tag v$(VERSION)
git push --tags
curl -H "Authorization: token `cat $(HOME)/.github-access-token`" -d '{"tag_name": "$(VERSION)"}' https://api.github.com/repos/nschloe/tikzplotlib/releases

upload: setup.py
@if [ "$(shell git rev-parse --abbrev-ref HEAD)" != "master" ]; then exit 1; fi
Expand Down
2 changes: 1 addition & 1 deletion tikzplotlib/__about__.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,5 @@
__email__ = "nico.schloemer@gmail.com"
__copyright__ = "Copyright (c) 2010-2019, {} <{}>".format(__author__, __email__)
__license__ = "License :: OSI Approved :: MIT License"
__version__ = "0.8.6"
__version__ = "0.8.7"
__status__ = "Development Status :: 5 - Production/Stable"
7 changes: 2 additions & 5 deletions tikzplotlib/_legend.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,11 +38,8 @@ def draw_legend(data, obj):
position = [bbox_center[0], bbox_center[1]]

legend_style = [
# These are the mpl default setting for legends, see
# <https://matplotlib.org/3.1.1/api/legend_api.html#matplotlib.legend.Legend>.
# Keep an eye on <https://github.com/matplotlib/matplotlib/issues/15764> to see
# if we can get() the opacity from the legend object.
"fill opacity=0.8",
# https://github.com/matplotlib/matplotlib/issues/15764#issuecomment-557823370
"fill opacity={}".format(obj.get_frame().get_alpha()),
"draw opacity=1",
"text opacity=1",
]
Expand Down

0 comments on commit f06fd7c

Please sign in to comment.