Output pgf macros for drawing the figure so it can be included and rendered in latex documents.
(self, fname_or_fh, **kwargs)
| 821 | _writeln(fh, r"\endgroup") |
| 822 | |
| 823 | def print_pgf(self, fname_or_fh, **kwargs): |
| 824 | """ |
| 825 | Output pgf macros for drawing the figure so it can be included and |
| 826 | rendered in latex documents. |
| 827 | """ |
| 828 | with cbook.open_file_cm(fname_or_fh, "w", encoding="utf-8") as file: |
| 829 | if not cbook.file_requires_unicode(file): |
| 830 | file = codecs.getwriter("utf-8")(file) |
| 831 | self._print_pgf_to_fh(file, **kwargs) |
| 832 | |
| 833 | def print_pdf(self, fname_or_fh, *, metadata=None, **kwargs): |
| 834 | """Use LaTeX to compile a pgf generated figure to pdf.""" |
no test coverage detected