@@ -821,8 +821,10 @@ def gen_candidates():
821821 'axes.hold' : ('2.1' ,),
822822 'backend.qt4' : ('2.2' ,),
823823 'backend.qt5' : ('2.2' ,),
824+ 'text.latex.unicode' : ('3.0' ,),
824825}
825826
827+
826828_all_deprecated = {* _deprecated_map , * _deprecated_ignore_map }
827829
828830
@@ -882,7 +884,7 @@ def __setitem__(self, key, val):
882884 val = alt_val (val )
883885 elif key in _deprecated_remain_as_none and val is not None :
884886 version , = _deprecated_remain_as_none [key ]
885- addendum = None
887+ addendum = ''
886888 if key .startswith ('backend' ):
887889 addendum = (
888890 "In order to force the use of a specific Qt binding, "
@@ -1242,21 +1244,33 @@ def rcdefaults():
12421244 Use a specific style file. Call ``style.use('default')`` to restore
12431245 the default style.
12441246 """
1245- rcParams .clear ()
1246- rcParams .update (rcParamsDefault )
1247+ # Deprecation warnings were already handled when creating rcParamsDefault,
1248+ # no need to reemit them here.
1249+ with warnings .catch_warnings ():
1250+ warnings .simplefilter ("ignore" , mplDeprecation )
1251+ rcParams .clear ()
1252+ rcParams .update (rcParamsDefault )
12471253
12481254
12491255def rc_file_defaults ():
12501256 """Restore the rc params from the original rc file loaded by Matplotlib.
12511257 """
1252- rcParams .update (rcParamsOrig )
1258+ # Deprecation warnings were already handled when creating rcParamsOrig, no
1259+ # need to reemit them here.
1260+ with warnings .catch_warnings ():
1261+ warnings .simplefilter ("ignore" , mplDeprecation )
1262+ rcParams .update (rcParamsOrig )
12531263
12541264
12551265def rc_file (fname ):
12561266 """
12571267 Update rc params from file.
12581268 """
1259- rcParams .update (rc_params_from_file (fname ))
1269+ # Deprecation warnings were already handled in rc_params_from_file, no need
1270+ # to reemit them here.
1271+ with warnings .catch_warnings ():
1272+ warnings .simplefilter ("ignore" , mplDeprecation )
1273+ rcParams .update (rc_params_from_file (fname ))
12601274
12611275
12621276class rc_context :
0 commit comments