Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 89bcf96

Browse filesBrowse files
dstansbymeeseeksmachine
authored andcommitted
Backport PR #16929: tk: Resize the canvas, not the figure.
1 parent 2e92602 commit 89bcf96
Copy full SHA for 89bcf96

File tree

Expand file treeCollapse file tree

1 file changed

+1
-1
lines changed
Filter options
Expand file treeCollapse file tree

1 file changed

+1
-1
lines changed

‎lib/matplotlib/backends/_backend_tk.py

Copy file name to clipboardExpand all lines: lib/matplotlib/backends/_backend_tk.py
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -460,7 +460,7 @@ def _get_toolmanager(self):
460460
return toolmanager
461461

462462
def resize(self, width, height):
463-
self.canvas._tkcanvas.master.geometry("%dx%d" % (width, height))
463+
self.canvas._tkcanvas.configure(width=width, height=height)
464464

465465
if self.toolbar is not None:
466466
self.toolbar.configure(width=width)

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.