Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 9c7ff84

Browse files
committed
do not convert None labels to 'None' (now in container.py)
1 parent fe63689 commit 9c7ff84

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

lib/matplotlib/container.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,10 @@ def set_label(self, s):
4444
4545
ACCEPTS: string or anything printable with '%s' conversion.
4646
"""
47-
self._label = '%s' % (s, )
47+
if s is not None:
48+
self._label = '%s' % (s, )
49+
else:
50+
self._label = None
4851
self.pchanged()
4952

5053
def add_callback(self, func):

0 commit comments

Comments
 (0)