Skip to content

Commit

Permalink
Merge pull request #6176 from madphysicist/patch-1
Browse files Browse the repository at this point in the history
DOC: Updated docs for rc_context
  • Loading branch information
WeatherGod committed Mar 20, 2016
2 parents 4230879 + a64686e commit b8d8b1b
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion lib/matplotlib/__init__.py
Expand Up @@ -1285,7 +1285,15 @@ class rc_context(object):
plt.plot(x, a)
The 'rc' dictionary takes precedence over the settings loaded from
'fname'. Passing a dictionary only is also valid.
'fname'. Passing a dictionary only is also valid. For example a
common usage is::
with mpl.rc_context(rc={'interactive': False}):
fig, ax = plt.subplots()
ax.plot(range(3), range(3))
fig.savefig('A.png', format='png')
plt.close(fig)
"""

def __init__(self, rc=None, fname=None):
Expand Down

0 comments on commit b8d8b1b

Please sign in to comment.