Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 627d292

Browse files
committed
Merge pull request #4530 from WeatherGod/tkwindow_fix
STY: Get rid of annoying border for Tk Canvases
2 parents 8609886 + 0cfb4fe commit 627d292

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

lib/matplotlib/backends/backend_tkagg.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -225,7 +225,8 @@ def __init__(self, figure, master=None, resize_callback=None):
225225
t1,t2,w,h = self.figure.bbox.bounds
226226
w, h = int(w), int(h)
227227
self._tkcanvas = Tk.Canvas(
228-
master=master, width=w, height=h, borderwidth=4)
228+
master=master, width=w, height=h, borderwidth=0,
229+
highlightthickness=0)
229230
self._tkphoto = Tk.PhotoImage(
230231
master=self._tkcanvas, width=w, height=h)
231232
self._tkcanvas.create_image(w//2, h//2, image=self._tkphoto)

0 commit comments

Comments
 (0)