Skip to content

Commit 06606d4

Browse files
committed
Pass ints to Tk.Canvas.create_image
1 parent 1d33483 commit 06606d4

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/matplotlib/backends/backend_tkagg.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -185,7 +185,7 @@ def __init__(self, figure, master=None, resize_callback=None):
185185
master=master, width=w, height=h, borderwidth=4)
186186
self._tkphoto = Tk.PhotoImage(
187187
master=self._tkcanvas, width=w, height=h)
188-
self._tkcanvas.create_image(w/2, h/2, image=self._tkphoto)
188+
self._tkcanvas.create_image(w//2, h//2, image=self._tkphoto)
189189
self._resize_callback = resize_callback
190190
self._tkcanvas.bind("<Configure>", self.resize)
191191
self._tkcanvas.bind("<Key>", self.key_press)

0 commit comments

Comments
 (0)