57
57
58
58
def doall ():
59
59
# Colors used in Matplotlib online documentation.
60
- mpl_blue_rvb = (191. / 255. , 209. / 256. , 212. / 255. )
61
- mpl_orange_rvb = (202. / 255. , 121. / 256. , 0. / 255. )
62
- mpl_grey_rvb = (51. / 255. , 51. / 255. , 51. / 255. )
60
+ mpl_grey_rgb = (51 / 255 , 51 / 255 , 51 / 255 )
63
61
64
62
# Creating figure and axis.
65
63
fig = plt .figure (figsize = (6 , 7 ))
@@ -68,7 +66,7 @@ def doall():
68
66
ax .set_xlim (0 , 1 )
69
67
ax .set_ylim (0 , 1 )
70
68
ax .set_title ("Matplotlib's math rendering engine" ,
71
- color = mpl_grey_rvb , fontsize = 14 , weight = 'bold' )
69
+ color = mpl_grey_rgb , fontsize = 14 , weight = 'bold' )
72
70
ax .set_xticklabels ([])
73
71
ax .set_yticklabels ([])
74
72
@@ -79,24 +77,24 @@ def doall():
79
77
full_demo = mathext_demos [0 ]
80
78
ax .annotate (full_demo ,
81
79
xy = (0.5 , 1. - 0.59 * line_axesfrac ),
82
- color = mpl_orange_rvb , ha = 'center' , fontsize = 20 )
80
+ color = 'tab:orange' , ha = 'center' , fontsize = 20 )
83
81
84
82
# Plotting features demonstration formulae
85
83
for i_line in range (1 , n_lines ):
86
84
baseline = 1 - i_line * line_axesfrac
87
85
baseline_next = baseline - line_axesfrac
88
86
title = mathtext_titles [i_line ] + ":"
89
- fill_color = ['white' , mpl_blue_rvb ][i_line % 2 ]
87
+ fill_color = ['white' , 'tab:blue' ][i_line % 2 ]
90
88
ax .fill_between ([0 , 1 ], [baseline , baseline ],
91
89
[baseline_next , baseline_next ],
92
- color = fill_color , alpha = 0.5 )
90
+ color = fill_color , alpha = 0.2 )
93
91
ax .annotate (title ,
94
92
xy = (0.07 , baseline - 0.3 * line_axesfrac ),
95
- color = mpl_grey_rvb , weight = 'bold' )
93
+ color = mpl_grey_rgb , weight = 'bold' )
96
94
demo = mathext_demos [i_line ]
97
95
ax .annotate (demo ,
98
96
xy = (0.05 , baseline - 0.75 * line_axesfrac ),
99
- color = mpl_grey_rvb , fontsize = 16 )
97
+ color = mpl_grey_rgb , fontsize = 16 )
100
98
101
99
for i in range (n_lines ):
102
100
s = mathext_demos [i ]
0 commit comments