Skip to content

Commit f06fd7c

Browse files
authored
Merge pull request #350 from nschloe/legend-opacity2
Legend opacity2
2 parents a670137 + 93326fa commit f06fd7c

File tree

3 files changed

+4
-6
lines changed

3 files changed

+4
-6
lines changed

Makefile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ tag:
99
@echo "Tagging v$(VERSION)..."
1010
git tag v$(VERSION)
1111
git push --tags
12+
curl -H "Authorization: token `cat $(HOME)/.github-access-token`" -d '{"tag_name": "$(VERSION)"}' https://api.github.com/repos/nschloe/tikzplotlib/releases
1213

1314
upload: setup.py
1415
@if [ "$(shell git rev-parse --abbrev-ref HEAD)" != "master" ]; then exit 1; fi

tikzplotlib/__about__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,5 @@
22
__email__ = "[email protected]"
33
__copyright__ = "Copyright (c) 2010-2019, {} <{}>".format(__author__, __email__)
44
__license__ = "License :: OSI Approved :: MIT License"
5-
__version__ = "0.8.6"
5+
__version__ = "0.8.7"
66
__status__ = "Development Status :: 5 - Production/Stable"

tikzplotlib/_legend.py

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -38,11 +38,8 @@ def draw_legend(data, obj):
3838
position = [bbox_center[0], bbox_center[1]]
3939

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

0 commit comments

Comments
 (0)