Skip to content

Commit

Permalink
Fix matplotlib api used
Browse files Browse the repository at this point in the history
The gui was not correctly opening due to an outdated matplotlib api usage.
  • Loading branch information
rbaltrusch committed Jun 22, 2024
1 parent 79604d1 commit ace52e6
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion bach_generator/gui/figure.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
from typing import Iterable, Optional

import matplotlib
import matplotlib.pyplot as plt
from matplotlib.backends.backend_tkagg import FigureCanvasTkAgg

warnings.filterwarnings("ignore")
Expand Down Expand Up @@ -60,7 +61,7 @@ def __init__(self, parent, bg_colour, axes_colour):
self.parent = parent
self.bg_colour = bg_colour
self.axes_colour = axes_colour
self.figure = matplotlib.figure.Figure()
self.figure = plt.figure()
self.axes = self.figure.add_subplot(111)
self.canvas = FigureCanvasTkAgg(self.figure, master=self.parent)
self.tk_widget = self.canvas.get_tk_widget()
Expand Down

0 comments on commit ace52e6

Please sign in to comment.