Skip to content

Commit fa64e4d

Browse files
committed
Fix config metadata to use .tag()
1 parent 65faaa1 commit fa64e4d

File tree

1 file changed

+10
-10
lines changed

1 file changed

+10
-10
lines changed

config.py

+10-10
Original file line numberDiff line numberDiff line change
@@ -61,14 +61,14 @@ def _config_changed(self, name, old, new):
6161
'savefig.dpi': 72,
6262
# 10pt still needs a little more room on the xlabel:
6363
'figure.subplot.bottom' : .125
64-
}, config=True,
64+
},
6565
help="""Subset of matplotlib rcParams that should be different for the
6666
inline backend."""
67-
)
67+
).tag(config=True)
6868

69-
figure_formats = Set({'png'}, config=True,
69+
figure_formats = Set({'png'},
7070
help="""A set of figure formats to enable: 'png',
71-
'retina', 'jpeg', 'svg', 'pdf'.""")
71+
'retina', 'jpeg', 'svg', 'pdf'.""").tag(config=True)
7272

7373
def _update_figure_formatters(self):
7474
if self.shell is not None:
@@ -81,22 +81,22 @@ def _figure_formats_changed(self, name, old, new):
8181
raise TraitError("Requires PIL/Pillow for JPG figures")
8282
self._update_figure_formatters()
8383

84-
figure_format = Unicode(config=True, help="""The figure format to enable (deprecated
85-
use `figure_formats` instead)""")
84+
figure_format = Unicode(help="""The figure format to enable (deprecated
85+
use `figure_formats` instead)""").tag(config=True)
8686

8787
def _figure_format_changed(self, name, old, new):
8888
if new:
8989
self.figure_formats = {new}
9090

91-
print_figure_kwargs = Dict({'bbox_inches' : 'tight'}, config=True,
91+
print_figure_kwargs = Dict({'bbox_inches' : 'tight'},
9292
help="""Extra kwargs to be passed to fig.canvas.print_figure.
9393
9494
Logical examples include: bbox_inches, quality (for jpeg figures), etc.
9595
"""
96-
)
96+
).tag(config=True)
9797
_print_figure_kwargs_changed = _update_figure_formatters
9898

99-
close_figures = Bool(True, config=True,
99+
close_figures = Bool(True,
100100
help="""Close all figures at the end of each cell.
101101
102102
When True, ensures that each cell starts with no active figures, but it
@@ -111,7 +111,7 @@ def _figure_format_changed(self, name, old, new):
111111
iterative editing of figures, and behaves most consistently with
112112
other matplotlib backends, but figure barriers between cells must
113113
be explicit.
114-
""")
114+
""").tag(config=True)
115115

116116
shell = Instance('IPython.core.interactiveshell.InteractiveShellABC',
117117
allow_none=True)

0 commit comments

Comments
 (0)