From fbd71c131386508a9ec7bb5963afefc13f8b1618 Mon Sep 17 00:00:00 2001 From: wyzula-jan <133381102+wyzula-jan@users.noreply.github.com> Date: Fri, 1 Sep 2023 09:24:36 +0200 Subject: [PATCH] fix: add max number of columns according to the number of plots --- bec_widgets/examples/extreme/extreme.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/bec_widgets/examples/extreme/extreme.py b/bec_widgets/examples/extreme/extreme.py index 11dea6f5..b49154d3 100644 --- a/bec_widgets/examples/extreme/extreme.py +++ b/bec_widgets/examples/extreme/extreme.py @@ -76,6 +76,7 @@ class PlotApp(QWidget): # Initialize the UI self.init_ui(self.plot_settings["num_columns"]) self.spinBox_N_columns.setValue(self.plot_settings["num_columns"]) + self.spinBox_N_columns.setMaximum(len(self.plot_data)) self.splitter.setSizes([400, 100]) # Connect the update signal to the update plot method @@ -373,6 +374,7 @@ if __name__ == "__main__": plot_settings = config.get("plot_settings", {}) plot_data = config.get("plot_data", {}) + except FileNotFoundError: print(f"The file {args.config} was not found.") exit(1)