10000 Define 'metadata' as kwarg in _print_figure_tex for consistency · matplotlib/matplotlib@6916e77 · GitHub
[go: up one dir, main page]

Skip to content

Commit 6916e77

Browse files
committed
Define 'metadata' as kwarg in _print_figure_tex for consistency
1 parent 06ad9fb commit 6916e77

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

lib/matplotlib/backends/backend_ps.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1197,12 +1197,15 @@ def do_nothing():
11971197
os.chmod(outfile, mode)
11981198

11991199
def _print_figure_tex(self, outfile, format, dpi, facecolor, edgecolor,
1200-
orientation, isLandscape, papertype,
1200+
orientation, isLandscape, papertype, metadata=None,
12011201
**kwargs):
12021202
"""
12031203
If text.usetex is True in rc, a temporary pair of tex/eps files
12041204
are created to allow tex to manage the text layout via the PSFrags
12051205
package. These files are processed to yield the final ps or eps file.
1206+
1207+
metadata must be a dictionary. Currently, only the value for
1208+
the key 'Creator' is used.
12061209
"""
12071210
isEPSF = format == 'eps'
12081211
if is_string_like(outfile):
@@ -1258,7 +1261,6 @@ def write(self, *kl, **kwargs):
12581261
self.figure.set_edgecolor(origedgecolor)
12591262

12601263
# check for custom metadata
1261-
metadata = kwargs.pop("metadata", None)
12621264
if metadata is not None and 'Creator' in metadata:
12631265
creator_str = metadata['Creator']
12641266
else:

0 commit comments

Comments
 (0)
0