8000 ENH: support 'gray' alternative for xkcd colors · matplotlib/matplotlib@e0c6dcf · GitHub
[go: up one dir, main page]

Skip to content

Commit e0c6dcf

Browse files
committed
ENH: support 'gray' alternative for xkcd colors
1 parent 9a2ed5f commit e0c6dcf

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

lib/matplotlib/_color_data.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -991,7 +991,9 @@
991991
'blue': '#0343df',
992992
'green': '#15b01a',
993993
'purple': '#7e1e9c'}
994-
994+
for k, v in list(XKCD_COLORS.items()):
995+
if 'grey' in k:
996+
XKCD_COLORS[k.replace('grey', 'gray')] = v
995997

996998
# Normalize name to "xkcd:<name>" to avoid name collisions.
997999
XKCD_COLORS = {'xkcd:' + name: value for name, value in XKCD_COLORS.items()}

0 commit comments

Comments
 (0)
0