File tree
3 files changed
+17
-4
lines changed- doc
- lib/matplotlib
- backends/qt4_editor
3 files changed
+17
-4
lines changedLines changed: 1 addition & 1 deletion
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
232 | 232 |
| |
233 | 233 |
| |
234 | 234 |
| |
235 |
| - | |
| 235 | + | |
236 | 236 |
| |
237 | 237 |
| |
238 | 238 |
| |
|
Lines changed: 11 additions & 2 deletions
@@ -762,6 +762,7 @@ def rc_params(fail_on_error=False):
762
762
763
763
# this is the instance used by the matplotlib classes
764
764
rcParams = rc_params()
765
+rcParamsOrig = rcParams.copy()
765
766
766
767
rcParamsDefault = RcParams([ (key, default) for key, (default, converter) in \
767
768
defaultParams.iteritems() ])
@@ -843,11 +844,19 @@ def rc(group, **kwargs):
843
844
844
845
def rcdefaults():
845
846
"""
846
- Restore the default rc params - the ones that were created at
847
- matplotlib load time.
847
+ Restore the default rc params - these are not the params loaded by
848
+ the rc file, but mpl's internal params. See rc_file_defaults for
849
+ reloading the default params from the rc file
848
850
"""
849
851
rcParams.update(rcParamsDefault)
850
852
853
+def rc_file_defaults():
854
+ """
855
+ Restore the default rc params from the original matplotlib rc that
856
+ was loaded
857
+ """
858
+ rcParams.update(rcParamsOrig)
859
+
851
860
_use_error_msg = """ This call to matplotlib.use() has no effect
852
861
because the the backend has already been chosen;
853
862
matplotlib.use() must be called *before* pylab, matplotlib.pyplot,
Lines changed: 5 additions & 1 deletion
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
272 | 272 |
| |
273 | 273 |
| |
274 | 274 |
| |
275 |
| - | |
| 275 | + | |
| 276 | + | |
| 277 | + | |
| 278 | + | |
| 279 | + | |
276 | 280 |
| |
277 | 281 |
| |
278 | 282 |
| |
|
0 commit comments