bec-widgets 0.63.2__py3-none-any.whl → 0.64.1__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (36) hide show
  1. .gitlab-ci.yml +34 -27
  2. CHANGELOG.md +36 -42
  3. PKG-INFO +1 -1
  4. bec_widgets/cli/client.py +39 -9
  5. bec_widgets/cli/generate_cli.py +2 -48
  6. bec_widgets/examples/jupyter_console/jupyter_console_window.py +1 -1
  7. bec_widgets/utils/plugin_utils.py +48 -0
  8. bec_widgets/widgets/__init__.py +5 -5
  9. bec_widgets/widgets/dock/dock.py +1 -1
  10. bec_widgets/widgets/figure/figure.py +6 -0
  11. bec_widgets/widgets/figure/plots/plot_base.py +62 -6
  12. bec_widgets/widgets/figure/plots/waveform/waveform.py +2 -0
  13. {bec_widgets-0.63.2.dist-info → bec_widgets-0.64.1.dist-info}/METADATA +1 -1
  14. {bec_widgets-0.63.2.dist-info → bec_widgets-0.64.1.dist-info}/RECORD +36 -32
  15. docs/developer/developer.md +38 -10
  16. docs/developer/getting_started/development.md +27 -0
  17. docs/developer/getting_started/getting_started.md +12 -0
  18. docs/developer/widgets/widgets.md +12 -0
  19. docs/user/customisation.md +2 -2
  20. docs/user/getting_started/installation.md +1 -1
  21. docs/user/widgets/buttons.md +1 -1
  22. docs/user/widgets/text_box.md +1 -1
  23. pyproject.toml +1 -1
  24. tests/end-2-end/conftest.py +2 -1
  25. tests/unit_tests/test_bec_dock.py +1 -1
  26. tests/unit_tests/test_bec_figure.py +1 -1
  27. tests/unit_tests/test_generate_cli_client.py +0 -14
  28. tests/unit_tests/test_plot_base.py +27 -0
  29. tests/unit_tests/test_plugin_utils.py +14 -0
  30. tests/unit_tests/test_scan_control.py +1 -1
  31. tests/unit_tests/test_spiral_progress_bar.py +1 -1
  32. tests/unit_tests/test_stop_button.py +1 -1
  33. tests/unit_tests/test_waveform1d.py +25 -9
  34. {bec_widgets-0.63.2.dist-info → bec_widgets-0.64.1.dist-info}/WHEEL +0 -0
  35. {bec_widgets-0.63.2.dist-info → bec_widgets-0.64.1.dist-info}/entry_points.txt +0 -0
  36. {bec_widgets-0.63.2.dist-info → bec_widgets-0.64.1.dist-info}/licenses/LICENSE +0 -0
@@ -5,6 +5,8 @@ from typing import Literal, Optional
5
5
  import numpy as np
6
6
  import pyqtgraph as pg
7
7
  from pydantic import BaseModel, Field
8
+ from qtpy import QT_VERSION
9
+ from qtpy.QtGui import QFont, QFontDatabase, QFontInfo
8
10
  from qtpy.QtWidgets import QWidget
9
11
 
10
12
  from bec_widgets.utils import BECConnector, ConnectionConfig
@@ -12,8 +14,14 @@ from bec_widgets.utils import BECConnector, ConnectionConfig
12
14
 
13
15
  class AxisConfig(BaseModel):
14
16
  title: Optional[str] = Field(None, description="The title of the axes.")
17
+ title_size: Optional[int] = Field(None, description="The font size of the title.")
15
18
  x_label: Optional[str] = Field(None, description="The label for the x-axis.")
19
+ x_label_size: Optional[int] = Field(None, description="The font size of the x-axis label.")
16
20
  y_label: Optional[str] = Field(None, description="The label for the y-axis.")
21
+ y_label_size: Optional[int] = Field(None, description="The font size of the y-axis label.")
22
+ legend_label_size: Optional[int] = Field(
23
+ None, description="The font size of the legend labels."
24
+ )
17
25
  x_scale: Literal["linear", "log"] = Field("linear", description="The scale of the x-axis.")
18
26
  y_scale: Literal["linear", "log"] = Field("linear", description="The scale of the y-axis.")
19
27
  x_lim: Optional[tuple] = Field(None, description="The limits of the x-axis.")
@@ -50,6 +58,7 @@ class BECPlotBase(BECConnector, pg.GraphicsLayout):
50
58
  "set_grid",
51
59
  "lock_aspect_ratio",
52
60
  "remove",
61
+ "set_legend_label_size",
53
62
  ]
54
63
 
55
64
  def __init__(
@@ -85,6 +94,7 @@ class BECPlotBase(BECConnector, pg.GraphicsLayout):
85
94
  - y_scale: Literal["linear", "log"]
86
95
  - x_lim: tuple
87
96
  - y_lim: tuple
97
+ - legend_label_size: int
88
98
  """
89
99
  # Mapping of keywords to setter methods
90
100
  method_map = {
@@ -95,6 +105,7 @@ class BECPlotBase(BECConnector, pg.GraphicsLayout):
95
105
  "y_scale": self.set_y_scale,
96
106
  "x_lim": self.set_x_lim,
97
107
  "y_lim": self.set_y_lim,
108
+ "legend_label_size": self.set_legend_label_size,
98
109
  }
99
110
  for key, value in kwargs.items():
100
111
  if key in method_map:
@@ -116,34 +127,79 @@ class BECPlotBase(BECConnector, pg.GraphicsLayout):
116
127
 
117
128
  self.set(**{k: v for k, v in config_mappings.items() if v is not None})
118
129
 
119
- def set_title(self, title: str):
130
+ def set_legend_label_size(self, size: int = None):
131
+ """
132
+ Set the font size of the legend.
133
+
134
+ Args:
135
+ size(int): Font size of the legend.
136
+ """
137
+ if not self.plot_item.legend:
138
+ return
139
+ if self.config.axis.legend_label_size or size:
140
+ if size:
141
+ self.config.axis.legend_label_size = size
142
+ scale = (
143
+ size / 9
144
+ ) # 9 is the default font size of the legend, so we always scale it against 9
145
+ self.plot_item.legend.setScale(scale)
146
+
147
+ def get_text_color(self):
148
+ return "#FFF" if self.figure.config.theme == "dark" else "#000"
149
+
150
+ def set_title(self, title: str, size: int = None):
120
151
  """
121
152
  Set the title of the plot widget.
122
153
 
123
154
  Args:
124
155
  title(str): Title of the plot widget.
156
+ size(int): Font size of the title.
125
157
  """
126
- self.plot_item.setTitle(title)
158
+ if self.config.axis.title_size or size:
159
+ if size:
160
+ self.config.axis.title_size = size
161
+ style = {"color": self.get_text_color(), "size": f"{self.config.axis.title_size}pt"}
162
+ else:
163
+ style = {}
164
+ self.plot_item.setTitle(title, **style)
127
165
  self.config.axis.title = title
128
166
 
129
- def set_x_label(self, label: str):
167
+ def set_x_label(self, label: str, size: int = None):
130
168
  """
131
169
  Set the label of the x-axis.
132
170
 
133
171
  Args:
134
172
  label(str): Label of the x-axis.
173
+ size(int): Font size of the label.
135
174
  """
136
- self.plot_item.setLabel("bottom", label)
175
+ if self.config.axis.x_label_size or size:
176
+ if size:
177
+ self.config.axis.x_label_size = size
178
+ style = {
179
+ "color": self.get_text_color(),
180
+ "font-size": f"{self.config.axis.x_label_size}pt",
181
+ }
182
+ else:
183
+ style = {}
184
+ self.plot_item.setLabel("bottom", label, **style)
137
185
  self.config.axis.x_label = label
138
186
 
139
- def set_y_label(self, label: str):
187
+ def set_y_label(self, label: str, size: int = None):
140
188
  """
141
189
  Set the label of the y-axis.
142
190
 
143
191
  Args:
144
192
  label(str): Label of the y-axis.
193
+ size(int): Font size of the label.
145
194
  """
146
- self.plot_item.setLabel("left", label)
195
+ if self.config.axis.y_label_size or size:
196
+ if size:
197
+ self.config.axis.y_label_size = size
198
+ color = self.get_text_color()
199
+ style = {"color": color, "font-size": f"{self.config.axis.y_label_size}pt"}
200
+ else:
201
+ style = {}
202
+ self.plot_item.setLabel("left", label, **style)
147
203
  self.config.axis.y_label = label
148
204
 
149
205
  def set_x_scale(self, scale: Literal["linear", "log"] = "linear"):
@@ -54,6 +54,7 @@ class BECWaveform(BECPlotBase):
54
54
  "set_grid",
55
55
  "lock_aspect_ratio",
56
56
  "remove",
57
+ "set_legend_label_size",
57
58
  ]
58
59
  scan_signal_update = pyqtSignal()
59
60
 
@@ -401,6 +402,7 @@ class BECWaveform(BECPlotBase):
401
402
  self.config.curves[name] = curve.config
402
403
  if data is not None:
403
404
  curve.setData(data[0], data[1])
405
+ self.set_legend_label_size()
404
406
  return curve
405
407
 
406
408
  def _validate_signal_entries(
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.3
2
2
  Name: bec_widgets
3
- Version: 0.63.2
3
+ Version: 0.64.1
4
4
  Summary: BEC Widgets
5
5
  Project-URL: Bug Tracker, https://gitlab.psi.ch/bec/bec_widgets/issues
6
6
  Project-URL: Homepage, https://gitlab.psi.ch/bec/bec_widgets
@@ -1,12 +1,12 @@
1
1
  .gitignore,sha256=cMQ1MLmnoR88aMCCJwUyfoTnufzl4-ckmHtlFUqHcT4,3253
2
- .gitlab-ci.yml,sha256=3PU2LONUl10zIOD4UCPQgA6vVBtniabww1MQkTMce7I,7995
2
+ .gitlab-ci.yml,sha256=RnYDz4zKXjlqltTryprlB1s5vLXxI2-seW-Vb70NNF0,8162
3
3
  .pylintrc,sha256=OstrgmEyP0smNFBKoIN5_26-UmNZgMHnbjvAWX0UrLs,18535
4
4
  .readthedocs.yaml,sha256=aSOc277LqXcsTI6lgvm_JY80lMlr69GbPKgivua2cS0,603
5
- CHANGELOG.md,sha256=giASCkqBIkuIXlmChXud4DRYYvt4CqEKj_gKmtEqsZU,7107
5
+ CHANGELOG.md,sha256=CiX1BkEPv2s0UtwMEo98g9Mu67zdSg6avBtCa7paxzw,7301
6
6
  LICENSE,sha256=YRKe85CBRyP7UpEAWwU8_qSIyuy5-l_9C-HKg5Qm8MQ,1511
7
- PKG-INFO,sha256=7MgGM-dR2iIoVEq11DTeyYgoeOXbWchJg8b3iQClLN0,1302
7
+ PKG-INFO,sha256=9Ga4DFezrIGV0_RAKf4a3XCQmEVsHRIIfL1vGo6VOzI,1302
8
8
  README.md,sha256=y4jB6wvArS7N8_iTbKWnSM_oRAqLA2GqgzUR-FMh5sU,2645
9
- pyproject.toml,sha256=da8TkNzJjBLBfnpIEXECsteZlMVT8pIMtmDwdVz75G8,2162
9
+ pyproject.toml,sha256=KO9Z-fFDndEAUlqXC1CSy_FQeu5wZf-7tAJiqr49nDk,2162
10
10
  .git_hooks/pre-commit,sha256=n3RofIZHJl8zfJJIUomcMyYGFi_rwq4CC19z0snz3FI,286
11
11
  .gitlab/issue_templates/bug_report_template.md,sha256=gAuyEwl7XlnebBrkiJ9AqffSNOywmr8vygUFWKTuQeI,386
12
12
  .gitlab/issue_templates/documentation_update_template.md,sha256=FHLdb3TS_D9aL4CYZCjyXSulbaW5mrN2CmwTaeLPbNw,860
@@ -17,15 +17,15 @@ bec_widgets/assets/bec_widgets_icon.png,sha256=K8dgGwIjalDh9PRHUsSQBqgdX7a00nM3i
17
17
  bec_widgets/assets/terminal_icon.png,sha256=bJl7Tft4Fi2uxvuXI8o14uMHnI9eAWKSU2uftXCH9ws,3889
18
18
  bec_widgets/cli/__init__.py,sha256=d0Q6Fn44e7wFfLabDOBxpcJ1DPKWlFunGYDUBmO-4hA,22
19
19
  bec_widgets/cli/auto_updates.py,sha256=DyBV3HnjMSH-cvVkYNcDiYKVf0Xut4Qy2qGQqkW47Bw,4833
20
- bec_widgets/cli/client.py,sha256=PkKPeR4KJjJP-DOPTq3yYJIuWlwXLHjTyZunCYSsU1I,55332
20
+ bec_widgets/cli/client.py,sha256=GJRzys0DVHQp8X9QxociTrshPm4CvaPtEprxWEpEKCs,56446
21
21
  bec_widgets/cli/client_utils.py,sha256=ttEE3iyMpK-yEbIAJsI8rXGVn27UT4GYzyrAEZIqFks,11400
22
- bec_widgets/cli/generate_cli.py,sha256=DIaGz7nhwef3ebIaP4LtiUC3q7MoM1swJ_e0SgAO2jo,6901
22
+ bec_widgets/cli/generate_cli.py,sha256=Bi8HxHhge1I87vbdYHZUZiZwvbB-OSkLYS5Xfmwiz9M,4922
23
23
  bec_widgets/cli/rpc_register.py,sha256=QxXUZu5XNg00Yf5O3UHWOXg3-f_pzKjjoZYMOa-MOJc,2216
24
24
  bec_widgets/cli/rpc_wigdet_handler.py,sha256=1oE2TSbwQdfLEaZiscyDX2eExHsenp2BF5Lwy8PE6LA,1118
25
25
  bec_widgets/cli/server.py,sha256=1iHDbYxNcsUz-HxFEJ2aM1z4sut-quaftyp4EFeGLkw,5762
26
26
  bec_widgets/examples/__init__.py,sha256=WWQ0cu7m8sA4Ehy-DWdTIqSISjaHsbxhsNmNrMnhDZU,202
27
27
  bec_widgets/examples/jupyter_console/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
28
- bec_widgets/examples/jupyter_console/jupyter_console_window.py,sha256=AKIlwcOMBJ8UAIBEhPipc9lDwA25UmmBDEYAfC0L7kU,5338
28
+ bec_widgets/examples/jupyter_console/jupyter_console_window.py,sha256=FXf0q7oz9GyJSct8PAgeOalzNnIJjApiaRvNfXsZPs0,5345
29
29
  bec_widgets/examples/jupyter_console/jupyter_console_window.ui,sha256=2A2mNTUMZBYygz8K4qWzrcjnNqZBMVyeHm26iLZVRWI,1473
30
30
  bec_widgets/examples/motor_movement/__init__.py,sha256=LzPJkxLAxOsZCbXR-fRCPmeYobp7Yqds6tDxW4W1gSw,214
31
31
  bec_widgets/examples/motor_movement/motor_control_compilations.py,sha256=8rpA7a2xVZTDMrx7YQIj3IJew78J1gcVMkHvloS0U_Q,9055
@@ -39,24 +39,24 @@ bec_widgets/utils/container_utils.py,sha256=m3VUyAYmSWkEwApP9tBvKxPYVtc2kHw4toxI
39
39
  bec_widgets/utils/crosshair.py,sha256=SubY4FQCI6vUKsmMYGKHR7uYdGQJ6vhoYLuC1XlKS9I,9626
40
40
  bec_widgets/utils/entry_validator.py,sha256=IqmtResXQtnmMvWVSl8IrnggqSzXLp4cSggn6WdSTpE,1298
41
41
  bec_widgets/utils/layout_manager.py,sha256=H0nKsIMaPxRkof1MEXlSmW6w1dFxA6astaGzf4stI84,4727
42
- bec_widgets/utils/plugin_utils.py,sha256=wi5x7VVFee0PqAcP-EqPWjYfSe-LLhaK93y6qmnbLIw,1487
42
+ bec_widgets/utils/plugin_utils.py,sha256=tmZkUNvVlldPjHDfL_TbaV2jjAECgPjGsvLMmmyZcfc,3342
43
43
  bec_widgets/utils/rpc_decorator.py,sha256=pIvtqySQLnuS7l2Ti_UAe4WX7CRivZnsE5ZdKAihxh0,479
44
44
  bec_widgets/utils/thread_checker.py,sha256=rDNuA3X6KQyA7JPb67mccTg0z8YkInynLAENQDQpbuE,1607
45
45
  bec_widgets/utils/ui_loader.py,sha256=5NktcP1r1HQub7K82fW_jkj8rT2cqJQdMvDxwToLY4E,1650
46
46
  bec_widgets/utils/validator_delegate.py,sha256=Emj1WF6W8Ke1ruBWUfmHdVJpmOSPezuOt4zvQTay_44,442
47
47
  bec_widgets/utils/widget_io.py,sha256=f36198CvT_EzWQ_cg2G-4tRRsaMdJ3yVqsZWKJCQEfA,10880
48
48
  bec_widgets/utils/yaml_dialog.py,sha256=cMVif-39SB9WjwGH5FWBJcFs4tnfFJFs5cacydRyhy0,1853
49
- bec_widgets/widgets/__init__.py,sha256=2GykeIg8_dqly6ZYny8HC7OGNpmafXXV3WN61vYGvzk,204
49
+ bec_widgets/widgets/__init__.py,sha256=6RE9Pot2ud6BNJc_ZKiE--U-lgVRUff2IVR91lPcCbo,214
50
50
  bec_widgets/widgets/buttons/__init__.py,sha256=74ucIRU6-anoqQ-zT7wbrysmxhg_3_04xGhN_kllNUI,48
51
51
  bec_widgets/widgets/buttons/stop_button/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
52
52
  bec_widgets/widgets/buttons/stop_button/stop_button.py,sha256=x4a7RvlMkHzOd05zKOGYkyTmBza7Me7jgOL9WIgA_c4,906
53
53
  bec_widgets/widgets/dock/__init__.py,sha256=B7foHt02gnhM7mFksa7GJVwT7n0j_JvYDCt6wc6XR5g,61
54
- bec_widgets/widgets/dock/dock.py,sha256=WPanKj6nodVP6PiEFkRTCj5Lf0pUupmM7i-5qZA_ATY,7596
54
+ bec_widgets/widgets/dock/dock.py,sha256=z3NtfdtP_UHrjTKwZEOuWvh6azaiuYaFuEc260V6Jgg,7601
55
55
  bec_widgets/widgets/dock/dock_area.py,sha256=9c_tLzyBRllLfc4H5o9-4bvasWp5hWe1NWg4mupXVtU,7911
56
56
  bec_widgets/widgets/figure/__init__.py,sha256=3hGx_KOV7QHCYAV06aNuUgKq4QIYCjUTad-DrwkUaBM,44
57
- bec_widgets/widgets/figure/figure.py,sha256=O--r3dyeOPXndV2400wpE9lPdBezzd0ZUt7yA2u2n0A,31468
57
+ bec_widgets/widgets/figure/figure.py,sha256=3bf1TyzIE8kVRDgjLqdlvCoE4wrozyfbeCWLjCo1Fwo,31821
58
58
  bec_widgets/widgets/figure/plots/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
59
- bec_widgets/widgets/figure/plots/plot_base.py,sha256=XfOQaQUHA0qZheGiDs0CYdJswUAgQjBzjQM1XSdjo8k,8049
59
+ bec_widgets/widgets/figure/plots/plot_base.py,sha256=QdDMMuWwTK0f6kNN8aAPBM7jah7TpUbYrMrRTdb2EZY,10419
60
60
  bec_widgets/widgets/figure/plots/image/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
61
61
  bec_widgets/widgets/figure/plots/image/image.py,sha256=-rxCt1IXmS2XQu0dS0SSXAF8VaxacSmQ-_kDsFxbPm4,19653
62
62
  bec_widgets/widgets/figure/plots/image/image_item.py,sha256=1oytCY2IIgRbtS3GRrp9JV02KOif78O2-iaK0qYuHFU,9058
@@ -64,7 +64,7 @@ bec_widgets/widgets/figure/plots/image/image_processor.py,sha256=TOnHbdq9rK5--L5
64
64
  bec_widgets/widgets/figure/plots/motor_map/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
65
65
  bec_widgets/widgets/figure/plots/motor_map/motor_map.py,sha256=Ff2WoNHxO_A3ggsbSd_AVUP1JeOWMuJs-0GLskxn-94,15267
66
66
  bec_widgets/widgets/figure/plots/waveform/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
67
- bec_widgets/widgets/figure/plots/waveform/waveform.py,sha256=f9YpsNufcICvZyDgcVujzdszdsh0_9gzvnRbpwZroLA,23490
67
+ bec_widgets/widgets/figure/plots/waveform/waveform.py,sha256=Z0cgQitW4SvBnQHvhsTJvx-2yoOW231GulhrM4o0hbA,23560
68
68
  bec_widgets/widgets/figure/plots/waveform/waveform_curve.py,sha256=lTyeCydzvrcdvQXc89jEjoor-Uvo54i197-_M4VtqX8,7970
69
69
  bec_widgets/widgets/jupyter_console/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
70
70
  bec_widgets/widgets/jupyter_console/jupyter_console.py,sha256=ioLYJL31RdBoAOGFSS8PVSnUhkWPWmLC3tiKp7CouO8,2251
@@ -109,9 +109,12 @@ docs/assets/index_contribute.svg,sha256=OCjvYBw_JhcY_D5Zd7f1MctQvq1YNalYlqPNwB1X
109
109
  docs/assets/index_getting_started.svg,sha256=Www1OXmauYlouZD51AR6-VG2vxrEig8-jjuDPhzkNxc,3977
110
110
  docs/assets/index_user_guide.svg,sha256=sRjKwOHVJStBYIQUFVcnfmbeXd2qAp0HYjleSp66XCI,6429
111
111
  docs/assets/rocket_launch_48dp.svg,sha256=pdrPrBcKWUa5OlgWKM0B6TA6qAW7E57d7C7YW2r1OT8,1070
112
- docs/developer/developer.md,sha256=7Z6sfkk_7BgwZ2vaX4z5_cJrs0miyeAYSGpqMbyBmOI,415
112
+ docs/developer/developer.md,sha256=VUdMnQBsSRCawYMFCe0vya5oj1MimLML7Pd58kY6fYY,765
113
+ docs/developer/getting_started/development.md,sha256=aYLmuLMYpp5FcIXeDUqCfcStIV8veuiMBjOt5bTW_30,1406
114
+ docs/developer/getting_started/getting_started.md,sha256=My_K_6O7LLaXVB_eINrRku5o-jVx95lsmGgHxgZhT7A,378
115
+ docs/developer/widgets/widgets.md,sha256=O7v0DsgCr-IULxl0TJ7NIGN68wd5kouKz1Y5ZuEvaEU,529
113
116
  docs/introduction/introduction.md,sha256=wp7jmhkUtJnSnEnmIAZGUcau_3-5e5-FohvZb63khw4,1432
114
- docs/user/customisation.md,sha256=MXqbljqokDXF3VhCeia1PITZe1mx1J3FfLTJ66TlaUA,3172
117
+ docs/user/customisation.md,sha256=wCW8fAbqtlgGE3mURvXOrK67Xo0_B-lxfg0sYuQWB40,3186
115
118
  docs/user/user.md,sha256=uCTcjclIi6rdjYRQebko6bWFEVsjyfshsVU3BDYrC-Y,1403
116
119
  docs/user/api_reference/api_reference.md,sha256=q2Imc48Rq6GcAP0R4bS3KuW5ptZZdsV4wxGJb3JJQHg,174
117
120
  docs/user/applications/applications.md,sha256=yOECfaYRUEDIxF-O0duOwSJlG4f93RylrpMjbw1-8Dg,100
@@ -119,23 +122,23 @@ docs/user/getting_started/BECDockArea.png,sha256=t3vSm_rVRk371J5LOutbolETuEjStNc
119
122
  docs/user/getting_started/auto_updates.md,sha256=Gicx3lplI6JRBlnPj_VL6IhqOIcsWjYF4_EdZSCje2A,3754
120
123
  docs/user/getting_started/getting_started.md,sha256=lxZXCr6HAkM61oo5Bu-YjINSKo4wihWhAPJdotEAAVQ,358
121
124
  docs/user/getting_started/gui_complex_gui.gif,sha256=ovv9u371BGG5GqhzyBMl4mvqMHLfJS0ylr-dR0Ydwtw,6550393
122
- docs/user/getting_started/installation.md,sha256=nBl2Hfvo6ua3-tVZn1B-UG0hCTlrFY6_ibXHWnXeegs,1135
125
+ docs/user/getting_started/installation.md,sha256=gqMV44lh9-wkKtAtDckvnyX_d8oTBNinQxvriFQ9Sk4,1145
123
126
  docs/user/getting_started/quick_start.md,sha256=VGU880GwamcIZcBE8tjxuqX2syE-71jqZedtskCoBbA,9405
124
127
  docs/user/widgets/BECFigure.png,sha256=8dQr4u0uk_y0VV-R1Jh9yTR3Vidd9HDEno_07R0swaE,1605920
125
128
  docs/user/widgets/bec_figure.md,sha256=BwcumbhZd6a2zKmoHTvwKr8kG8WxBx9lS_QwxNiBMpQ,5155
126
- docs/user/widgets/buttons.md,sha256=SKxhLsu_gquNSG-zMAzVzz2d6bUwtZ9y259ILoMyCu0,1214
129
+ docs/user/widgets/buttons.md,sha256=LG-Csj9RL7hWur8Xgj19r-u2SuIFq912fyBVN6peLGY,1222
127
130
  docs/user/widgets/image_plot.gif,sha256=_mVFhMTXGqwDOcEtrBHMZj5Thn2sLhDAHEeL2XyHN-s,14098977
128
131
  docs/user/widgets/motor.gif,sha256=FtaWdRHx4UZaGJPpq8LNhMMgX4PFcAB6IZ93JCMEh_w,2280719
129
132
  docs/user/widgets/progress_bar.gif,sha256=5jh0Zw2BBGPuNxszV1DBLJCb4_6glIRX-U2ABjnsK2k,5263592
130
133
  docs/user/widgets/scatter_2D.gif,sha256=yHpsuAUseMafJjI_J5BcOhmE3nu9VFn_Xm9XHzJaH5I,13188862
131
134
  docs/user/widgets/spiral_progress_bar.md,sha256=QTgUDIl6XPuK_HwSfB6sNijZ4bss26biDg6B_mJ8Pxk,2208
132
- docs/user/widgets/text_box.md,sha256=i40AxKJP0PxrYW0x0up1VIovPFvemsaZoosGjOn4iZE,931
135
+ docs/user/widgets/text_box.md,sha256=_ST7RQWXl67MKLm6dTa995GjoughPUyK_hLnF8SPZcM,925
133
136
  docs/user/widgets/w1D.gif,sha256=tuHbleJpl6bJFNNC2OdndF5LF7IyfvlkFCMGZajrQPs,622773
134
137
  docs/user/widgets/website.md,sha256=wfudAupdtHX-Sfritg0xMWXZLLczJ4XwMLNWvu6ww-w,705
135
138
  docs/user/widgets/widgets.md,sha256=NzRfrgd4LWmZHa2Cs_1G59LeY5uAlFdy5aP00AtGAjk,380
136
139
  tests/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
137
140
  tests/end-2-end/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
138
- tests/end-2-end/conftest.py,sha256=taLqiYVzOhJjMre5ypgQjB7wzSXP4soKANW3XfAjems,1773
141
+ tests/end-2-end/conftest.py,sha256=j1O1SxXRJ8jcrunn6dcfbZLK2Jc-VUxyh9ZuCSc6Qj4,1816
139
142
  tests/end-2-end/test_bec_dock_rpc_e2e.py,sha256=8iJz4lITspY7eHdSgy9YvGUGTu3fsSperoVGBvTGT0U,9067
140
143
  tests/end-2-end/test_bec_figure_rpc_e2e.py,sha256=zTbB_F4Fs-QG8KhMK24xfsrCQBgZUAguMk3KFdEdP2o,5095
141
144
  tests/end-2-end/test_rpc_register_e2e.py,sha256=3dfCnSvdcRO92pzHt9WlCTK0vzTKAvPtliEoEKrtuzQ,1604
@@ -144,21 +147,22 @@ tests/unit_tests/client_mocks.py,sha256=ErrklY7446jXE2_XGKebs_a-2Pqif5ECOPvxVAKR
144
147
  tests/unit_tests/conftest.py,sha256=KrnktXPWmZhnKNue-xGWOLD1XGEvdz9Vf7V2eO3XQ3A,596
145
148
  tests/unit_tests/test_bec_connector.py,sha256=f2XXGGw3NoZLIUrDuZuEWwF_ttOYmmquCgUrV5XkIOY,1951
146
149
  tests/unit_tests/test_bec_dispatcher.py,sha256=rYPiRizHaswhGZw55IBMneDFxmPiCCLAZQBqjEkpdyY,3992
147
- tests/unit_tests/test_bec_dock.py,sha256=x1mgeNvgu9yVuZvgUkfD60F7FLANGQsXSBhF3n8kyIM,3606
148
- tests/unit_tests/test_bec_figure.py,sha256=xYAftY8bI_EH-SlNPD0Tjd7FS_47ouZ1E4hrpjPt7O4,8002
150
+ tests/unit_tests/test_bec_dock.py,sha256=BXKXpuyIYj-l6KSyhQtM_p3kRFCRECIoXLzvkcJZDlM,3611
151
+ tests/unit_tests/test_bec_figure.py,sha256=aEd2R8K6fU2ON8QvPemGWpql_LaaYLipRlvnjBY2qFA,8009
149
152
  tests/unit_tests/test_bec_motor_map.py,sha256=AfD_9-x6VV3TPnkQgNfFYRndPHDsGx-a_YknFeDr6hc,4588
150
153
  tests/unit_tests/test_client_utils.py,sha256=eViJ1Tz-HX9TkMvQH6W8cO-c3_1I8bUc4_Yen6LOc0E,830
151
154
  tests/unit_tests/test_color_validation.py,sha256=csdvVKAohENZIRY-JQ97Hv-TShb1erj4oKMX7QRwo78,1883
152
155
  tests/unit_tests/test_crosshair.py,sha256=3OMAJ2ZaISYXMOtkXf1rPdy94vCr8njeLi6uHblBL9Q,5045
153
- tests/unit_tests/test_generate_cli_client.py,sha256=GmCLpyRWx5aREb66Api9T-OUpYE1wKgI4hhjUepYrvg,3408
156
+ tests/unit_tests/test_generate_cli_client.py,sha256=adcMoXjWpFLVjpauCu0r31CMMibUY1LF1MMf8rO-6rw,2815
154
157
  tests/unit_tests/test_motor_control.py,sha256=NBekcGALo5mYkuyBJvBhvJkWiQDV82hI4GmsobRzjTI,20770
155
- tests/unit_tests/test_plot_base.py,sha256=bOdlgAxh9oKk5PwiQ_MSFmzr44uJ61Tlg242RCIhl5c,2610
158
+ tests/unit_tests/test_plot_base.py,sha256=Akr_JgglUCrtERtdtsMqWko_MLUYoAYRGzV2sum-YHo,3836
159
+ tests/unit_tests/test_plugin_utils.py,sha256=PonKNpu4fZaFmKbI2v0tZJjZrsTvBGSF96bPHvKJvrE,608
156
160
  tests/unit_tests/test_rpc_register.py,sha256=hECjZEimd440mwRrO0rg7L3PKN7__3DgjmESN6wx3bo,1179
157
- tests/unit_tests/test_scan_control.py,sha256=7dtGpE0g4FqUhhQeCkyJl-9o7NH3DFZJgEaqDmBYbBc,7551
158
- tests/unit_tests/test_spiral_progress_bar.py,sha256=yak3N9-TmEM3lQZPSROL4cAx9mior__se1XADlMScks,12418
159
- tests/unit_tests/test_stop_button.py,sha256=hOoWO0emkvd5bR_EExxCnKsiZgXKqf_uIGTwzWLxhDw,704
161
+ tests/unit_tests/test_scan_control.py,sha256=Xf8bGt8lRJobRwBoqUdVXxsHno8ejvC77FqprhF7Z6I,7564
162
+ tests/unit_tests/test_spiral_progress_bar.py,sha256=n5aLSZ2B6K5a1vQuKTERnCSmIz9hYGFyk7jP3TU0AwQ,12438
163
+ tests/unit_tests/test_stop_button.py,sha256=2OH9dhs_-S5QovPPgU-5hJoViE1YKZa0gxisb4vOY28,712
160
164
  tests/unit_tests/test_text_box_widget.py,sha256=cT0uEHt_6d-FwST0A_wE9sFW9E3F_nJbKhuBAeU4yHg,1862
161
- tests/unit_tests/test_waveform1d.py,sha256=j9-CCE0BkFVI3Gnv8pjV1gc9HwA5PYG0_ox1oZ60F6w,15272
165
+ tests/unit_tests/test_waveform1d.py,sha256=I3_pF0ieltcTWtweOBjICaOxJ8NCQ0-NWxpKg8Pas3E,15893
162
166
  tests/unit_tests/test_website_widget.py,sha256=fBADIJJBAHU4Ro7u95kdemFVNv196UOcuO9oLHuHt8A,761
163
167
  tests/unit_tests/test_widget_io.py,sha256=FeL3ZYSBQnRt6jxj8VGYw1cmcicRQyHKleahw7XIyR0,3475
164
168
  tests/unit_tests/test_yaml_dialog.py,sha256=HNrqferkdg02-9ieOhhI2mr2Qvt7GrYgXmQ061YCTbg,5794
@@ -167,8 +171,8 @@ tests/unit_tests/test_configs/config_device_no_entry.yaml,sha256=hdvue9KLc_kfNzG
167
171
  tests/unit_tests/test_configs/config_scan.yaml,sha256=vo484BbWOjA_e-h6bTjSV9k7QaQHrlAvx-z8wtY-P4E,1915
168
172
  tests/unit_tests/test_msgs/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
169
173
  tests/unit_tests/test_msgs/available_scans_message.py,sha256=m_z97hIrjHXXMa2Ex-UvsPmTxOYXfjxyJaGkIY6StTY,46532
170
- bec_widgets-0.63.2.dist-info/METADATA,sha256=7MgGM-dR2iIoVEq11DTeyYgoeOXbWchJg8b3iQClLN0,1302
171
- bec_widgets-0.63.2.dist-info/WHEEL,sha256=zEMcRr9Kr03x1ozGwg5v9NQBKn3kndp6LSoSlVg-jhU,87
172
- bec_widgets-0.63.2.dist-info/entry_points.txt,sha256=OvoqiNzNF9bizFQNhbAmmdc_njHrnVewLE-Kl-u9sh0,115
173
- bec_widgets-0.63.2.dist-info/licenses/LICENSE,sha256=YRKe85CBRyP7UpEAWwU8_qSIyuy5-l_9C-HKg5Qm8MQ,1511
174
- bec_widgets-0.63.2.dist-info/RECORD,,
174
+ bec_widgets-0.64.1.dist-info/METADATA,sha256=9Ga4DFezrIGV0_RAKf4a3XCQmEVsHRIIfL1vGo6VOzI,1302
175
+ bec_widgets-0.64.1.dist-info/WHEEL,sha256=zEMcRr9Kr03x1ozGwg5v9NQBKn3kndp6LSoSlVg-jhU,87
176
+ bec_widgets-0.64.1.dist-info/entry_points.txt,sha256=OvoqiNzNF9bizFQNhbAmmdc_njHrnVewLE-Kl-u9sh0,115
177
+ bec_widgets-0.64.1.dist-info/licenses/LICENSE,sha256=YRKe85CBRyP7UpEAWwU8_qSIyuy5-l_9C-HKg5Qm8MQ,1511
178
+ bec_widgets-0.64.1.dist-info/RECORD,,
@@ -1,18 +1,46 @@
1
1
  (developer)=
2
- # Development
2
+ # Developer
3
3
 
4
- To contribute to the development of BEC Widgets, start by setting up the development environment:
4
+ Welcome to the BEC Widgets developer guide! This section is intended for developers who want to contribute to the development of BEC Widgets.
5
5
 
6
- 1. **Clone the Repository**:
7
- ```bash
8
- git clone https://gitlab.psi.ch/bec/bec_widgets
9
- cd bec_widgets
6
+ ```{toctree}
7
+ ---
8
+ maxdepth: 2
9
+ hidden: true
10
+ ---
11
+
12
+ getting_started/getting_started.md
13
+ widgets/widgets.md
14
+ api_reference/api_reference.md
15
+ ```
16
+
17
+
18
+ ***
19
+
20
+ ````{grid} 2
21
+ :gutter: 5
22
+
23
+ ```{grid-item-card}
24
+ :link: developer.getting_started
25
+ :link-type: ref
26
+ :img-top: /assets/rocket_launch_48dp.svg
27
+ :text-align: center
28
+
29
+ ## Getting Started
30
+
31
+ Learn how to install BEC Widgets and get started with the framework.
10
32
  ```
11
- 2. **Install in Editable Mode**:
12
33
 
13
- Installing the package in editable mode allows you to make changes to the code and test them in real-time.
14
- ```bash
15
- pip install -e .[dev,pyqt6]
34
+ ```{grid-item-card}
35
+ :link: developer.widgets
36
+ :link-type: ref
37
+ :img-top: /assets/apps_48dp.svg
38
+ :text-align: center
39
+
40
+ ## Widgets
41
+
42
+ Learn about the building blocks of larger applications: widgets.
16
43
  ```
44
+ ````
17
45
 
18
46
 
@@ -0,0 +1,27 @@
1
+ (developer.development)=
2
+ # Development
3
+
4
+ If you like to contribute to the development of BEC Widgets, you can follow the steps below to set up your development environment.
5
+ BEC Widgets works in conjunction with [BEC](https://bec.readthedocs.io/en/latest/).
6
+ Therefore, we recommend that you install BEC first following the [developer instructions](https://bec.readthedocs.io/en/latest/developer/getting_started/install_developer_env.html) and include BEC Widgets.
7
+
8
+ If you already have a BEC environment set up, you can install BEC Widgets in editable mode into your BEC Python environment.
9
+
10
+ **Prerequisites**
11
+ 1. **Python Version:** BEC Widgets requires Python version 3.10 or higher. Verify your Python version to ensure compatibility.
12
+ 2. **BEC Installation:** BEC Widgets works in conjunction with BEC. While BEC is a dependency and will be installed automatically, you can find more information about BEC and its installation process in the [BEC documentation](https://beamline-experiment-control.readthedocs.io/en/latest/).
13
+
14
+ **Clone the Repository**:
15
+ ```bash
16
+ git clone https://gitlab.psi.ch/bec/bec_widgets
17
+ cd bec_widgets
18
+ ```
19
+ **Install in Editable Mode**:
20
+
21
+ Please install the package in editable mode into your BEC Python environemnt.
22
+ ```bash
23
+ pip install -e '.[dev,pyqt6]'
24
+ ```
25
+ This installs the package together with [PyQT6](https://www.riverbankcomputing.com/static/Docs/PyQt6/introduction.html).
26
+
27
+
@@ -0,0 +1,12 @@
1
+ (developer.getting_started)=
2
+ # Getting Started
3
+ This section provides valuable information for developers who want to contribute to the development of BEC Widgets. The guide will help you set up the development environment, understand the modular development concept of BEC Widgets, and contribute to the project.
4
+
5
+ ```{toctree}
6
+ ---
7
+ maxdepth: 2
8
+ hidden: false
9
+ ---
10
+
11
+ development/
12
+ ```
@@ -0,0 +1,12 @@
1
+ (developer.widgets)=
2
+ # Widgets
3
+ This section provides an introduction to the building blocks of BEC Widgets: widgets. Widgets are the basic components of the graphical user interface (GUI) and are used to create larger applications. We will cover key topics such as how to develop new widgets or how to customise existing widgets. For details on the already available widgets and their usage, please refer to user section about [widgets](#user.widgets)
4
+
5
+ ```{toctree}
6
+ ---
7
+ maxdepth: 2
8
+ hidden: false
9
+ ---
10
+
11
+ how_to_develop_a_widget/
12
+ ```
@@ -48,7 +48,7 @@ users to interact. BEC Widgets must be placed in the window:
48
48
 
49
49
  ```
50
50
  from qtpy.QWidgets import QMainWindow
51
- from bec_widgets.widgets import BECFigure
51
+ from bec_widgets.widgets.figure import BECFigure
52
52
 
53
53
  window = QMainWindow()
54
54
  bec_figure = BECFigure(gui_id="my_gui_app_id")
@@ -78,7 +78,7 @@ Final example:
78
78
  ```
79
79
  import sys
80
80
  from qtpy.QtWidgets import QMainWindow, QApplication
81
- from bec_widgets.widgets import BECFigure
81
+ from bec_widgets.widgets.figure import BECFigure
82
82
  from bec_widgets.utils.bec_dispatcher import BECDispatcher
83
83
 
84
84
  # creation of the Qt application
@@ -9,7 +9,7 @@ Before installing BEC Widgets, please ensure the following requirements are met:
9
9
 
10
10
  **Standard Installation**
11
11
 
12
- To install BEC Widgets using the pip package manager, execute the following command in your terminal for getting the default PyQT6 version in your python environment:
12
+ To install BEC Widgets using the pip package manager, execute the following command in your terminal for getting the default PyQT6 version into your python environment for BEC:
13
13
 
14
14
 
15
15
  ```bash
@@ -24,7 +24,7 @@ a `StopButton` within a GUI layout:
24
24
 
25
25
  ```python
26
26
  from qtpy.QtWidgets import QWidget, QVBoxLayout
27
- from bec_widgets.widgets import StopButton
27
+ from bec_widgets.widgets.buttons import StopButton
28
28
 
29
29
 
30
30
  class MyGui(QWidget):
@@ -1,5 +1,5 @@
1
1
  (user.widgets.text_box)=
2
- # [Text Box Widget](/api_reference/_autosummary/bec_widgets.cli.client.TextBoxWidget)
2
+ # [Text Box Widget](/api_reference/_autosummary/bec_widgets.cli.client.TextBox)
3
3
  **Purpose:**
4
4
 
5
5
  The Text Box Widget is a widget that allows you to display text within the BEC GUI. The widget can be used to display plain text or HTML text.
pyproject.toml CHANGED
@@ -4,7 +4,7 @@ build-backend = "hatchling.build"
4
4
 
5
5
  [project]
6
6
  name = "bec_widgets"
7
- version = "0.63.2"
7
+ version = "0.64.1"
8
8
  description = "BEC Widgets"
9
9
  requires-python = ">=3.10"
10
10
  classifiers = [
@@ -8,7 +8,8 @@ from bec_lib.endpoints import MessageEndpoints
8
8
  from bec_widgets.cli.client_utils import _start_plot_process
9
9
  from bec_widgets.cli.rpc_register import RPCRegister
10
10
  from bec_widgets.utils import BECDispatcher
11
- from bec_widgets.widgets import BECDockArea, BECFigure
11
+ from bec_widgets.widgets.dock import BECDockArea
12
+ from bec_widgets.widgets.figure import BECFigure
12
13
 
13
14
 
14
15
  # make threads check in autouse, **will be executed at the end**; better than
@@ -2,7 +2,7 @@
2
2
 
3
3
  import pytest
4
4
 
5
- from bec_widgets.widgets import BECDock, BECDockArea
5
+ from bec_widgets.widgets.dock import BECDock, BECDockArea
6
6
 
7
7
  from .client_mocks import mocked_client
8
8
 
@@ -3,7 +3,7 @@
3
3
  import numpy as np
4
4
  import pytest
5
5
 
6
- from bec_widgets.widgets import BECFigure
6
+ from bec_widgets.widgets.figure import BECFigure
7
7
  from bec_widgets.widgets.figure.plots.image.image import BECImageShow
8
8
  from bec_widgets.widgets.figure.plots.motor_map.motor_map import BECMotorMap
9
9
  from bec_widgets.widgets.figure.plots.waveform.waveform import BECWaveform
@@ -97,17 +97,3 @@ def test_client_generator_with_black_formatting():
97
97
  generated_output_formatted = isort.code(generated_output_formatted)
98
98
 
99
99
  assert expected_output_formatted == generated_output_formatted
100
-
101
-
102
- def test_client_generator_classes():
103
- generator = ClientGenerator()
104
- out = generator.get_rpc_classes("bec_widgets")
105
- assert list(out.keys()) == ["connector_classes", "top_level_classes"]
106
- connector_cls_names = [cls.__name__ for cls in out["connector_classes"]]
107
- top_level_cls_names = [cls.__name__ for cls in out["top_level_classes"]]
108
-
109
- assert "BECFigure" in connector_cls_names
110
- assert "BECWaveform" in connector_cls_names
111
- assert "BECDockArea" in top_level_cls_names
112
- assert "BECFigure" in top_level_cls_names
113
- assert "BECWaveform" not in top_level_cls_names
@@ -1,5 +1,8 @@
1
1
  # pylint: disable=missing-function-docstring, missing-module-docstring, unused-import
2
+ from unittest import mock
3
+
2
4
  import pytest
5
+ from qtpy.QtGui import QFontInfo
3
6
 
4
7
  from .client_mocks import mocked_client
5
8
  from .test_bec_figure import bec_figure
@@ -37,6 +40,30 @@ def test_plot_base_axes_by_separate_methods(bec_figure):
37
40
  assert plot_base.plot_item.ctrl.logXCheck.isChecked() == True
38
41
  assert plot_base.plot_item.ctrl.logYCheck.isChecked() == True
39
42
 
43
+ # Check the font size by mocking the set functions
44
+ # I struggled retrieving it from the QFont object directly
45
+ # thus I mocked the set functions to check internally the functionality
46
+ with (
47
+ mock.patch.object(plot_base.plot_item, "setLabel") as mock_set_label,
48
+ mock.patch.object(plot_base.plot_item, "setTitle") as mock_set_title,
49
+ ):
50
+ plot_base.set_x_label("Test x Label", 20)
51
+ plot_base.set_y_label("Test y Label", 16)
52
+ assert mock_set_label.call_count == 2
53
+ assert plot_base.config.axis.x_label_size == 20
54
+ assert plot_base.config.axis.y_label_size == 16
55
+ col = plot_base.get_text_color()
56
+ calls = []
57
+ style = {"color": col, "font-size": "20pt"}
58
+ calls.append(mock.call("bottom", "Test x Label", **style))
59
+ style = {"color": col, "font-size": "16pt"}
60
+ calls.append(mock.call("left", "Test y Label", **style))
61
+ assert mock_set_label.call_args_list == calls
62
+ plot_base.set_title("Test Title", 16)
63
+ style = {"color": col, "size": "16pt"}
64
+ call = mock.call("Test Title", **style)
65
+ assert mock_set_title.call_args == call
66
+
40
67
 
41
68
  def test_plot_base_axes_added_by_kwargs(bec_figure):
42
69
  plot_base = bec_figure.add_widget(widget_type="PlotBase", widget_id="test_plot")
@@ -0,0 +1,14 @@
1
+ from bec_widgets.utils.plugin_utils import get_rpc_classes
2
+
3
+
4
+ def test_client_generator_classes():
5
+ out = get_rpc_classes("bec_widgets")
6
+ assert list(out.keys()) == ["connector_classes", "top_level_classes"]
7
+ connector_cls_names = [cls.__name__ for cls in out["connector_classes"]]
8
+ top_level_cls_names = [cls.__name__ for cls in out["top_level_classes"]]
9
+
10
+ assert "BECFigure" in connector_cls_names
11
+ assert "BECWaveform" in connector_cls_names
12
+ assert "BECDockArea" in top_level_cls_names
13
+ assert "BECFigure" in top_level_cls_names
14
+ assert "BECWaveform" not in top_level_cls_names
@@ -5,7 +5,7 @@ import pytest
5
5
  from qtpy.QtWidgets import QLineEdit
6
6
 
7
7
  from bec_widgets.utils.widget_io import WidgetIO
8
- from bec_widgets.widgets import ScanControl
8
+ from bec_widgets.widgets.scan_control import ScanControl
9
9
  from tests.unit_tests.test_msgs.available_scans_message import available_scans_message
10
10
 
11
11
 
@@ -5,7 +5,7 @@ from bec_lib.endpoints import MessageEndpoints
5
5
  from pydantic import ValidationError
6
6
 
7
7
  from bec_widgets.utils import Colors
8
- from bec_widgets.widgets import SpiralProgressBar
8
+ from bec_widgets.widgets.spiral_progress_bar import SpiralProgressBar
9
9
  from bec_widgets.widgets.spiral_progress_bar.ring import RingConfig, RingConnections
10
10
  from bec_widgets.widgets.spiral_progress_bar.spiral_progress_bar import SpiralProgressBarConfig
11
11
 
@@ -2,7 +2,7 @@
2
2
 
3
3
  import pytest
4
4
 
5
- from bec_widgets.widgets import StopButton
5
+ from bec_widgets.widgets.buttons import StopButton
6
6
 
7
7
  from .client_mocks import mocked_client
8
8