We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 40ea023 commit c118579Copy full SHA for c118579
lib/matplotlib/backends/_backend_tk.py
@@ -258,8 +258,7 @@ def resize(self, event):
258
self.figure.set_size_inches(winch, hinch, forward=False)
259
260
self._tkcanvas.delete(self._tkcanvas_image_region)
261
- self._tkphoto = tk.PhotoImage(
262
- master=self._tkcanvas, width=int(width), height=int(height))
+ self._tkphoto.configure(width=int(width), height=int(height))
263
self._tkcanvas_image_region = self._tkcanvas.create_image(
264
int(width / 2), int(height / 2), image=self._tkphoto)
265
ResizeEvent("resize_event", self)._process()
0 commit comments