Skip to content

Commit 685131b

Browse files
committed
Show title of 3D plots in DBWindow using GroupBox
1 parent 39f8100 commit 685131b

File tree

3 files changed

+26
-4
lines changed

3 files changed

+26
-4
lines changed

res/layout/window_dynamical_bayesian.ui

Lines changed: 21 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -50,10 +50,28 @@
5050
<item>
5151
<layout class="QHBoxLayout" name="hbox_dual_plot">
5252
<item>
53-
<widget class="DBPlot3d" name="db3d_plot_left" native="true"/>
53+
<widget class="QGroupBox" name="db3d_grpbox_left">
54+
<property name="title">
55+
<string>Time-averaged Coupling Function (2-&gt;1)</string>
56+
</property>
57+
<layout class="QVBoxLayout" name="verticalLayout_10">
58+
<item>
59+
<widget class="DBPlot3d" name="db3d_plot_left" native="true"/>
60+
</item>
61+
</layout>
62+
</widget>
5463
</item>
5564
<item>
56-
<widget class="DBPlot3d" name="db3d_plot_right" native="true"/>
65+
<widget class="QGroupBox" name="db3d_grpbox_right">
66+
<property name="title">
67+
<string>Time-averaged Coupling Function (1-&gt;2)</string>
68+
</property>
69+
<layout class="QVBoxLayout" name="verticalLayout_12">
70+
<item>
71+
<widget class="DBPlot3d" name="db3d_plot_right" native="true"/>
72+
</item>
73+
</layout>
74+
</widget>
5775
</item>
5876
</layout>
5977
</item>
@@ -483,7 +501,7 @@
483501
</layout>
484502
</item>
485503
<item>
486-
<widget class="QGroupBox" name="">
504+
<widget class="QGroupBox" name="groupBox">
487505
<property name="title">
488506
<string>Coupling plot</string>
489507
</property>

src/gui/windows/bayesian/DBViewProperties.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -65,6 +65,10 @@ def __init__(self):
6565
self.db3d_plot_left: DBPlot3d = None
6666
self.db3d_plot_right: DBPlot3d = None
6767

68+
# The groupboxes containing the 3d plots.
69+
self.db3d_grpbox_left: QGroupBox = None
70+
self.db3d_grpbox_right: QGroupBox = None
71+
6872
# The button used to toggle between the 3-plot and 2-plot UI.
6973
self.btn_toggle_plots: QPushButton = None
7074

src/gui/windows/bayesian/DBWindow.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ def on_toggle_plots(self) -> None:
7676
is called when the user toggles between them.
7777
"""
7878
triple_plot = (self.db_plot_top, self.db_plot_middle, self.db_plot_bottom)
79-
dual_plot = (self.db3d_plot_left, self.db3d_plot_right)
79+
dual_plot = (self.db3d_grpbox_left, self.db3d_grpbox_right)
8080

8181
if self.is_triple_plot:
8282
self.set_visible(triple_plot, False)

0 commit comments

Comments
 (0)