From 7961de383f7fda33f5b320aba1268213c57224bb Mon Sep 17 00:00:00 2001 From: Antony Lee Date: Tue, 14 May 2019 12:41:54 +0200 Subject: [PATCH] Walk the artist tree when preparing for saving with tight bbox. --- lib/matplotlib/backend_bases.py | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/matplotlib/backend_bases.py b/lib/matplotlib/backend_bases.py index 6108f42774af..9922979c86b0 100644 --- a/lib/matplotlib/backend_bases.py +++ b/lib/matplotlib/backend_bases.py @@ -2067,6 +2067,7 @@ def print_figure(self, filename, dpi=None, facecolor=None, edgecolor=None, self.figure, functools.partial( print_method, dpi=dpi, orientation=orientation)) + self.figure.draw(renderer) bbox_artists = kwargs.pop("bbox_extra_artists", None) bbox_inches = self.figure.get_tightbbox(renderer, bbox_extra_artists=bbox_artists)