Skip to content

Commit c629ec0

Browse files
authored
Update main.py
fixed matplotlib exit error on Windows machines
1 parent 3347bac commit c629ec0

1 file changed

Lines changed: 5 additions & 1 deletion

File tree

src/main.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -163,7 +163,11 @@ def __about(self):
163163
f.pack(padx=50, pady=20)
164164

165165
def destroy(self):
166-
try: self.r.destroy()
166+
try:
167+
self.r.destroy()
168+
self.plot_root.destroy()
169+
plt.close('all')
170+
del self.plot_fig
167171
except: pass
168172
super().destroy()
169173
self.root.destroy()

0 commit comments

Comments
 (0)