bec-widgets 0.52.0__py3-none-any.whl → 0.53.0__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 (85) hide show
  1. .git_hooks/pre-commit +3 -0
  2. .gitignore +177 -0
  3. .gitlab/issue_templates/bug_report_template.md +17 -0
  4. .gitlab/issue_templates/documentation_update_template.md +27 -0
  5. .gitlab/issue_templates/feature_request_template.md +40 -0
  6. .gitlab/merge_request_templates/default.md +28 -0
  7. .gitlab-ci.yml +225 -0
  8. .pylintrc +581 -0
  9. .readthedocs.yaml +25 -0
  10. CHANGELOG.md +176 -0
  11. PKG-INFO +33 -0
  12. bec_widgets-0.52.0.dist-info/METADATA → README.md +6 -42
  13. bec_widgets/cli/client.py +132 -17
  14. bec_widgets/cli/client_utils.py +1 -0
  15. bec_widgets/cli/generate_cli.py +1 -0
  16. bec_widgets/cli/rpc_register.py +4 -0
  17. bec_widgets/cli/rpc_wigdet_handler.py +2 -3
  18. bec_widgets/examples/modular_app/modular.ui +92 -0
  19. bec_widgets/examples/modular_app/modular_app.py +197 -0
  20. bec_widgets/examples/motor_movement/motor_control_compilations.py +1 -1
  21. bec_widgets/examples/motor_movement/motor_example.py +3 -12
  22. bec_widgets/utils/bec_connector.py +7 -0
  23. bec_widgets/utils/bec_dispatcher.py +1 -3
  24. bec_widgets/utils/bec_table.py +1 -0
  25. bec_widgets/utils/container_utils.py +3 -0
  26. bec_widgets/utils/crosshair.py +1 -0
  27. bec_widgets/utils/entry_validator.py +2 -0
  28. bec_widgets/utils/layout_manager.py +4 -0
  29. bec_widgets/utils/widget_io.py +5 -0
  30. bec_widgets/utils/yaml_dialog.py +2 -0
  31. bec_widgets/validation/monitor_config_validator.py +2 -1
  32. bec_widgets/widgets/dock/dock_area.py +6 -4
  33. bec_widgets/widgets/figure/figure.py +15 -15
  34. bec_widgets/widgets/monitor/config_dialog.py +3 -19
  35. bec_widgets/widgets/monitor/example_configs/config_device.yaml +60 -0
  36. bec_widgets/widgets/monitor/example_configs/config_scans.yaml +92 -0
  37. bec_widgets/widgets/motor_map/motor_map.py +3 -14
  38. bec_widgets/widgets/plots/image.py +41 -0
  39. bec_widgets/widgets/plots/motor_map.py +16 -9
  40. bec_widgets/widgets/plots/plot_base.py +10 -0
  41. bec_widgets/widgets/plots/waveform.py +31 -0
  42. bec_widgets/widgets/scan_control/scan_control.py +11 -5
  43. bec_widgets/widgets/toolbar/toolbar.py +1 -0
  44. bec_widgets-0.53.0.dist-info/METADATA +33 -0
  45. bec_widgets-0.53.0.dist-info/RECORD +156 -0
  46. {bec_widgets-0.52.0.dist-info → bec_widgets-0.53.0.dist-info}/WHEEL +1 -2
  47. bec_widgets-0.53.0.dist-info/licenses/LICENSE +29 -0
  48. docs/Makefile +20 -0
  49. docs/_templates/custom-class-template.rst +34 -0
  50. docs/_templates/custom-module-template.rst +66 -0
  51. docs/conf.py +81 -0
  52. docs/developer/developer.md +26 -0
  53. docs/developer/reference.md +10 -0
  54. docs/index.md +39 -0
  55. docs/introduction/introduction.md +18 -0
  56. docs/make.bat +35 -0
  57. docs/requirements.txt +10 -0
  58. docs/user/apps/modular_app.md +6 -0
  59. docs/user/apps/motor_app.md +34 -0
  60. docs/user/apps/motor_app_10fps.gif +0 -0
  61. docs/user/apps/plot_app.md +6 -0
  62. docs/user/apps.md +39 -0
  63. docs/user/customisation.md +13 -0
  64. docs/user/installation.md +46 -0
  65. docs/user/user.md +38 -0
  66. docs/user/widgets/motor.gif +0 -0
  67. docs/user/widgets/scatter_2D.gif +0 -0
  68. docs/user/widgets/w1D.gif +0 -0
  69. docs/user/widgets.md +41 -0
  70. pyproject.toml +94 -0
  71. tests/unit_tests/test_bec_dispatcher.py +3 -26
  72. tests/unit_tests/test_bec_figure.py +1 -5
  73. tests/unit_tests/test_bec_motor_map.py +1 -4
  74. tests/unit_tests/test_config_dialog.py +1 -5
  75. tests/unit_tests/test_configs/config_device.yaml +33 -0
  76. tests/unit_tests/test_configs/config_device_no_entry.yaml +27 -0
  77. tests/unit_tests/test_configs/config_scan.yaml +82 -0
  78. tests/unit_tests/test_motor_control.py +1 -1
  79. tests/unit_tests/test_motor_map.py +5 -20
  80. tests/unit_tests/test_stream_plot.py +2 -12
  81. bec_widgets/utils/ctrl_c.py +0 -39
  82. bec_widgets-0.52.0.dist-info/RECORD +0 -115
  83. bec_widgets-0.52.0.dist-info/top_level.txt +0 -2
  84. /bec_widgets-0.52.0.dist-info/LICENSE → /LICENSE +0 -0
  85. /bec_widgets/{simulations/__init__.py → examples/modular_app/___init__.py} +0 -0
@@ -102,6 +102,7 @@ class BECMotorMap(BECPlotBase):
102
102
  ) -> None:
103
103
  """
104
104
  Change the active motors for the plot.
105
+
105
106
  Args:
106
107
  motor_x(str): Motor name for the X axis.
107
108
  motor_y(str): Motor name for the Y axis.
@@ -135,16 +136,14 @@ class BECMotorMap(BECPlotBase):
135
136
  Returns:
136
137
  dict: Data of the motor map.
137
138
  """
138
- data = {
139
- "x": self.database_buffer["x"],
140
- "y": self.database_buffer["y"],
141
- }
139
+ data = {"x": self.database_buffer["x"], "y": self.database_buffer["y"]}
142
140
  return data
143
141
 
144
142
  # TODO setup all visual properties
145
143
  def set_max_points(self, max_points: int) -> None:
146
144
  """
147
145
  Set the maximum number of points to display.
146
+
148
147
  Args:
149
148
  max_points(int): Maximum number of points to display.
150
149
  """
@@ -153,6 +152,7 @@ class BECMotorMap(BECPlotBase):
153
152
  def set_precision(self, precision: int) -> None:
154
153
  """
155
154
  Set the decimal precision of the motor position.
155
+
156
156
  Args:
157
157
  precision(int): Decimal precision of the motor position.
158
158
  """
@@ -161,6 +161,7 @@ class BECMotorMap(BECPlotBase):
161
161
  def set_num_dim_points(self, num_dim_points: int) -> None:
162
162
  """
163
163
  Set the number of dim points for the motor map.
164
+
164
165
  Args:
165
166
  num_dim_points(int): Number of dim points.
166
167
  """
@@ -169,6 +170,7 @@ class BECMotorMap(BECPlotBase):
169
170
  def set_background_value(self, background_value: int) -> None:
170
171
  """
171
172
  Set the background value of the motor map.
173
+
172
174
  Args:
173
175
  background_value(int): Background value of the motor map.
174
176
  """
@@ -177,6 +179,7 @@ class BECMotorMap(BECPlotBase):
177
179
  def set_scatter_size(self, scatter_size: int) -> None:
178
180
  """
179
181
  Set the scatter size of the motor map plot.
182
+
180
183
  Args:
181
184
  scatter_size(int): Size of the scatter points.
182
185
  """
@@ -247,6 +250,7 @@ class BECMotorMap(BECPlotBase):
247
250
  def _add_coordinantes_crosshair(self, x: float, y: float) -> None:
248
251
  """
249
252
  Add crosshair to the plot to highlight the current position.
253
+
250
254
  Args:
251
255
  x(float): X coordinate.
252
256
  y(float): Y coordinate.
@@ -274,6 +278,7 @@ class BECMotorMap(BECPlotBase):
274
278
  def _make_limit_map(self, limits_x: list, limits_y: list) -> pg.ImageItem:
275
279
  """
276
280
  Create a limit map for the motor map plot.
281
+
277
282
  Args:
278
283
  limits_x(list): Motor limits for the x axis.
279
284
  limits_y(list): Motor limits for the y axis.
@@ -303,10 +308,12 @@ class BECMotorMap(BECPlotBase):
303
308
  def _get_motor_init_position(self, name: str, entry: str, precision: int) -> float:
304
309
  """
305
310
  Get the motor initial position from the config.
311
+
306
312
  Args:
307
313
  name(str): Motor name.
308
314
  entry(str): Motor entry.
309
315
  precision(int): Decimal precision of the motor position.
316
+
310
317
  Returns:
311
318
  float: Motor initial position.
312
319
  """
@@ -323,12 +330,14 @@ class BECMotorMap(BECPlotBase):
323
330
  ) -> tuple[str, str]:
324
331
  """
325
332
  Validate the signal name and entry.
333
+
326
334
  Args:
327
335
  x_name(str): Name of the x signal.
328
336
  y_name(str): Name of the y signal.
329
337
  x_entry(str|None): Entry of the x signal.
330
338
  y_entry(str|None): Entry of the y signal.
331
339
  validate_bec(bool, optional): If True, validate the signal with BEC. Defaults to True.
340
+
332
341
  Returns:
333
342
  tuple[str,str]: Validated x and y entries.
334
343
  """
@@ -343,6 +352,7 @@ class BECMotorMap(BECPlotBase):
343
352
  def _get_motor_limit(self, motor: str) -> Union[list | None]: # TODO check if works correctly
344
353
  """
345
354
  Get the motor limit from the config.
355
+
346
356
  Args:
347
357
  motor(str): Motor name.
348
358
 
@@ -378,11 +388,7 @@ class BECMotorMap(BECPlotBase):
378
388
 
379
389
  # Update the scatter plot
380
390
  self.plot_components["scatter"].setData(
381
- x=x,
382
- y=y,
383
- brush=brushes,
384
- pen=None,
385
- size=scatter_size,
391
+ x=x, y=y, brush=brushes, pen=None, size=scatter_size
386
392
  )
387
393
 
388
394
  # Get last know position for crosshair
@@ -404,6 +410,7 @@ class BECMotorMap(BECPlotBase):
404
410
  def on_device_readback(self, msg: dict) -> None:
405
411
  """
406
412
  Update the motor map plot with the new motor position.
413
+
407
414
  Args:
408
415
  msg(dict): Message from the device readback.
409
416
  """
@@ -73,8 +73,10 @@ class BECPlotBase(BECConnector, pg.GraphicsLayout):
73
73
  def set(self, **kwargs) -> None:
74
74
  """
75
75
  Set the properties of the plot widget.
76
+
76
77
  Args:
77
78
  **kwargs: Keyword arguments for the properties to be set.
79
+
78
80
  Possible properties:
79
81
  - title: str
80
82
  - x_label: str
@@ -117,6 +119,7 @@ class BECPlotBase(BECConnector, pg.GraphicsLayout):
117
119
  def set_title(self, title: str):
118
120
  """
119
121
  Set the title of the plot widget.
122
+
120
123
  Args:
121
124
  title(str): Title of the plot widget.
122
125
  """
@@ -126,6 +129,7 @@ class BECPlotBase(BECConnector, pg.GraphicsLayout):
126
129
  def set_x_label(self, label: str):
127
130
  """
128
131
  Set the label of the x-axis.
132
+
129
133
  Args:
130
134
  label(str): Label of the x-axis.
131
135
  """
@@ -135,6 +139,7 @@ class BECPlotBase(BECConnector, pg.GraphicsLayout):
135
139
  def set_y_label(self, label: str):
136
140
  """
137
141
  Set the label of the y-axis.
142
+
138
143
  Args:
139
144
  label(str): Label of the y-axis.
140
145
  """
@@ -144,6 +149,7 @@ class BECPlotBase(BECConnector, pg.GraphicsLayout):
144
149
  def set_x_scale(self, scale: Literal["linear", "log"] = "linear"):
145
150
  """
146
151
  Set the scale of the x-axis.
152
+
147
153
  Args:
148
154
  scale(Literal["linear", "log"]): Scale of the x-axis.
149
155
  """
@@ -153,6 +159,7 @@ class BECPlotBase(BECConnector, pg.GraphicsLayout):
153
159
  def set_y_scale(self, scale: Literal["linear", "log"] = "linear"):
154
160
  """
155
161
  Set the scale of the y-axis.
162
+
156
163
  Args:
157
164
  scale(Literal["linear", "log"]): Scale of the y-axis.
158
165
  """
@@ -208,6 +215,7 @@ class BECPlotBase(BECConnector, pg.GraphicsLayout):
208
215
  def set_grid(self, x: bool = False, y: bool = False):
209
216
  """
210
217
  Set the grid of the plot widget.
218
+
211
219
  Args:
212
220
  x(bool): Show grid on the x-axis.
213
221
  y(bool): Show grid on the y-axis.
@@ -223,6 +231,7 @@ class BECPlotBase(BECConnector, pg.GraphicsLayout):
223
231
  def lock_aspect_ratio(self, lock):
224
232
  """
225
233
  Lock aspect ratio.
234
+
226
235
  Args:
227
236
  lock(bool): True to lock, False to unlock.
228
237
  """
@@ -231,6 +240,7 @@ class BECPlotBase(BECConnector, pg.GraphicsLayout):
231
240
  def plot(self, data_x: list | np.ndarray, data_y: list | np.ndarray, **kwargs):
232
241
  """
233
242
  Plot custom data on the plot widget. These data are not saved in config.
243
+
234
244
  Args:
235
245
  data_x(list|np.ndarray): x-axis data
236
246
  data_y(list|np.ndarray): y-axis data
@@ -129,8 +129,10 @@ class BECCurve(BECConnector, pg.PlotDataItem):
129
129
  def set(self, **kwargs):
130
130
  """
131
131
  Set the properties of the curve.
132
+
132
133
  Args:
133
134
  **kwargs: Keyword arguments for the properties to be set.
135
+
134
136
  Possible properties:
135
137
  - color: str
136
138
  - symbol: str
@@ -159,6 +161,7 @@ class BECCurve(BECConnector, pg.PlotDataItem):
159
161
  def set_color(self, color: str, symbol_color: Optional[str] = None):
160
162
  """
161
163
  Change the color of the curve.
164
+
162
165
  Args:
163
166
  color(str): Color of the curve.
164
167
  symbol_color(str, optional): Color of the symbol. Defaults to None.
@@ -170,6 +173,7 @@ class BECCurve(BECConnector, pg.PlotDataItem):
170
173
  def set_symbol(self, symbol: str):
171
174
  """
172
175
  Change the symbol of the curve.
176
+
173
177
  Args:
174
178
  symbol(str): Symbol of the curve.
175
179
  """
@@ -179,6 +183,7 @@ class BECCurve(BECConnector, pg.PlotDataItem):
179
183
  def set_symbol_color(self, symbol_color: str):
180
184
  """
181
185
  Change the symbol color of the curve.
186
+
182
187
  Args:
183
188
  symbol_color(str): Color of the symbol.
184
189
  """
@@ -188,6 +193,7 @@ class BECCurve(BECConnector, pg.PlotDataItem):
188
193
  def set_symbol_size(self, symbol_size: int):
189
194
  """
190
195
  Change the symbol size of the curve.
196
+
191
197
  Args:
192
198
  symbol_size(int): Size of the symbol.
193
199
  """
@@ -197,6 +203,7 @@ class BECCurve(BECConnector, pg.PlotDataItem):
197
203
  def set_pen_width(self, pen_width: int):
198
204
  """
199
205
  Change the pen width of the curve.
206
+
200
207
  Args:
201
208
  pen_width(int): Width of the pen.
202
209
  """
@@ -206,6 +213,7 @@ class BECCurve(BECConnector, pg.PlotDataItem):
206
213
  def set_pen_style(self, pen_style: Literal["solid", "dash", "dot", "dashdot"]):
207
214
  """
208
215
  Change the pen style of the curve.
216
+
209
217
  Args:
210
218
  pen_style(Literal["solid", "dash", "dot", "dashdot"]): Style of the pen.
211
219
  """
@@ -215,6 +223,7 @@ class BECCurve(BECConnector, pg.PlotDataItem):
215
223
  def set_colormap(self, colormap: str):
216
224
  """
217
225
  Set the colormap for the scatter plot z gradient.
226
+
218
227
  Args:
219
228
  colormap(str): Colormap for the scatter plot.
220
229
  """
@@ -299,6 +308,7 @@ class BECWaveform(BECPlotBase):
299
308
  def apply_config(self, config: dict | SubplotConfig, replot_last_scan: bool = False):
300
309
  """
301
310
  Apply the configuration to the 1D waveform widget.
311
+
302
312
  Args:
303
313
  config(dict|SubplotConfig): Configuration settings.
304
314
  replot_last_scan(bool, optional): If True, replot the last scan. Defaults to False.
@@ -339,8 +349,10 @@ class BECWaveform(BECPlotBase):
339
349
  def add_curve_by_config(self, curve_config: CurveConfig | dict) -> BECCurve:
340
350
  """
341
351
  Add a curve to the plot widget by its configuration.
352
+
342
353
  Args:
343
354
  curve_config(CurveConfig|dict): Configuration of the curve to be added.
355
+
344
356
  Returns:
345
357
  BECCurve: The curve object.
346
358
  """
@@ -354,8 +366,10 @@ class BECWaveform(BECPlotBase):
354
366
  def get_curve_config(self, curve_id: str, dict_output: bool = True) -> CurveConfig | dict:
355
367
  """
356
368
  Get the configuration of a curve by its ID.
369
+
357
370
  Args:
358
371
  curve_id(str): ID of the curve.
372
+
359
373
  Returns:
360
374
  CurveConfig|dict: Configuration of the curve.
361
375
  """
@@ -382,8 +396,10 @@ class BECWaveform(BECPlotBase):
382
396
  def get_curve(self, identifier) -> BECCurve:
383
397
  """
384
398
  Get the curve by its index or ID.
399
+
385
400
  Args:
386
401
  identifier(int|str): Identifier of the curve. Can be either an integer (index) or a string (curve_id).
402
+
387
403
  Returns:
388
404
  BECCurve: The curve object.
389
405
  """
@@ -407,6 +423,7 @@ class BECWaveform(BECPlotBase):
407
423
  ) -> BECCurve:
408
424
  """
409
425
  Add a custom data curve to the plot widget.
426
+
410
427
  Args:
411
428
  x(list|np.ndarray): X data of the curve.
412
429
  y(list|np.ndarray): Y data of the curve.
@@ -457,11 +474,13 @@ class BECWaveform(BECPlotBase):
457
474
  ) -> BECCurve:
458
475
  """
459
476
  Add a curve object to the plot widget.
477
+
460
478
  Args:
461
479
  name(str): ID of the curve.
462
480
  source(str): Source of the curve.
463
481
  config(CurveConfig): Configuration of the curve.
464
482
  data(tuple[list|np.ndarray,list|np.ndarray], optional): Data (x,y) to be plotted. Defaults to None.
483
+
465
484
  Returns:
466
485
  BECCurve: The curve object.
467
486
  """
@@ -489,6 +508,7 @@ class BECWaveform(BECPlotBase):
489
508
  ) -> BECCurve:
490
509
  """
491
510
  Add a curve to the plot widget from the scan segment.
511
+
492
512
  Args:
493
513
  x_name(str): Name of the x signal.
494
514
  x_entry(str): Entry of the x signal.
@@ -559,6 +579,7 @@ class BECWaveform(BECPlotBase):
559
579
  ) -> tuple[str, str, str | None]:
560
580
  """
561
581
  Validate the signal name and entry.
582
+
562
583
  Args:
563
584
  x_name(str): Name of the x signal.
564
585
  y_name(str): Name of the y signal.
@@ -567,6 +588,7 @@ class BECWaveform(BECPlotBase):
567
588
  y_entry(str|None): Entry of the y signal.
568
589
  z_entry(str|None): Entry of the z signal.
569
590
  validate_bec(bool, optional): If True, validate the signal with BEC. Defaults to True.
591
+
570
592
  Returns:
571
593
  tuple[str,str,str|None]: Validated x, y, z entries.
572
594
  """
@@ -584,6 +606,7 @@ class BECWaveform(BECPlotBase):
584
606
  def _check_curve_id(self, val: Any, dict_to_check: dict) -> bool:
585
607
  """
586
608
  Check if val is in the values of the dict_to_check or in the values of the nested dictionaries.
609
+
587
610
  Args:
588
611
  val(Any): Value to check.
589
612
  dict_to_check(dict): Dictionary to check.
@@ -602,6 +625,7 @@ class BECWaveform(BECPlotBase):
602
625
  def remove_curve(self, *identifiers):
603
626
  """
604
627
  Remove a curve from the plot widget.
628
+
605
629
  Args:
606
630
  *identifiers: Identifier of the curve to be removed. Can be either an integer (index) or a string (curve_id).
607
631
  """
@@ -618,6 +642,7 @@ class BECWaveform(BECPlotBase):
618
642
  def _remove_curve_by_id(self, curve_id):
619
643
  """
620
644
  Remove a curve by its ID from the plot widget.
645
+
621
646
  Args:
622
647
  curve_id(str): ID of the curve to be removed.
623
648
  """
@@ -634,6 +659,7 @@ class BECWaveform(BECPlotBase):
634
659
  def _remove_curve_by_order(self, N):
635
660
  """
636
661
  Remove a curve by its order from the plot widget.
662
+
637
663
  Args:
638
664
  N(int): Order of the curve to be removed.
639
665
  """
@@ -679,6 +705,7 @@ class BECWaveform(BECPlotBase):
679
705
  def _update_scan_curves(self, data: ScanData):
680
706
  """
681
707
  Update the scan curves with the data from the scan segment.
708
+
682
709
  Args:
683
710
  data(ScanData): Data from the scan segment.
684
711
  """
@@ -713,6 +740,7 @@ class BECWaveform(BECPlotBase):
713
740
  def _make_z_gradient(self, data_z: list | np.ndarray, colormap: str) -> list | None:
714
741
  """
715
742
  Make a gradient color for the z values.
743
+
716
744
  Args:
717
745
  data_z(list|np.ndarray): Z values.
718
746
  colormap(str): Colormap for the gradient color.
@@ -735,6 +763,7 @@ class BECWaveform(BECPlotBase):
735
763
  """
736
764
  Update the scan curves with the data from the scan storage.
737
765
  Provide only one of scan_id or scan_index.
766
+
738
767
  Args:
739
768
  scan_id(str, optional): ScanID of the scan to be updated. Defaults to None.
740
769
  scan_index(int, optional): Index of the scan to be updated. Defaults to None.
@@ -754,8 +783,10 @@ class BECWaveform(BECPlotBase):
754
783
  def get_all_data(self, output: Literal["dict", "pandas"] = "dict") -> dict | pd.DataFrame:
755
784
  """
756
785
  Extract all curve data into a dictionary or a pandas DataFrame.
786
+
757
787
  Args:
758
788
  output (Literal["dict", "pandas"]): Format of the output data.
789
+
759
790
  Returns:
760
791
  dict | pd.DataFrame: Data of all curves in the specified format.
761
792
  """
@@ -109,6 +109,7 @@ class ScanControl(QWidget):
109
109
  def add_horizontal_separator(self, layout) -> None:
110
110
  """
111
111
  Adds a horizontal separator to the given layout
112
+
112
113
  Args:
113
114
  layout: Layout to add the separator to
114
115
  """
@@ -142,6 +143,7 @@ class ScanControl(QWidget):
142
143
  def add_labels_to_layout(self, labels: list, grid_layout: QGridLayout) -> None:
143
144
  """
144
145
  Adds labels to the given grid layout as a separate row.
146
+
145
147
  Args:
146
148
  labels (list): List of label names to add.
147
149
  grid_layout (QGridLayout): The grid layout to which labels will be added.
@@ -157,6 +159,7 @@ class ScanControl(QWidget):
157
159
  ) -> None: # TODO could be moved to BECTable
158
160
  """
159
161
  Adds labels to the given table widget as a header row.
162
+
160
163
  Args:
161
164
  labels(list): List of label names to add.
162
165
  table(QTableWidget): The table widget to which labels will be added.
@@ -166,7 +169,8 @@ class ScanControl(QWidget):
166
169
 
167
170
  def generate_args_input_fields(self, scan_info: dict) -> None:
168
171
  """
169
- Generates input fields for args
172
+ Generates input fields for args.
173
+
170
174
  Args:
171
175
  scan_info(dict): Scan signature dictionary from BEC.
172
176
  """
@@ -188,6 +192,7 @@ class ScanControl(QWidget):
188
192
  def generate_kwargs_input_fields(self, scan_info: dict) -> None:
189
193
  """
190
194
  Generates input fields for kwargs
195
+
191
196
  Args:
192
197
  scan_info(dict): Scan signature dictionary from BEC.
193
198
  """
@@ -213,12 +218,13 @@ class ScanControl(QWidget):
213
218
  def generate_widgets_from_signature(self, items: list, signature: dict = None) -> list:
214
219
  """
215
220
  Generates widgets from the given list of items.
221
+
216
222
  Args:
217
223
  items(list): List of items to create widgets for.
218
224
  signature(dict, optional): Scan signature dictionary from BEC.
219
225
 
220
226
  Returns:
221
-
227
+ list: List of widgets created from the given items.
222
228
  """
223
229
  widgets = [] # Initialize an empty list to hold the widgets
224
230
 
@@ -333,6 +339,7 @@ class ScanControl(QWidget):
333
339
  def clear_and_delete_layout(self, layout: QLayout):
334
340
  """
335
341
  Clears and deletes the given layout and all its child widgets.
342
+
336
343
  Args:
337
344
  layout(QLayout): Layout to clear and delete
338
345
  """
@@ -383,6 +390,7 @@ class ScanControl(QWidget):
383
390
  def extract_args_from_table(self, table: QTableWidget) -> list:
384
391
  """
385
392
  Extracts the arguments from the given table widget.
393
+
386
394
  Args:
387
395
  table(QTableWidget): Table widget from which to extract the arguments
388
396
  """
@@ -430,9 +438,7 @@ if __name__ == "__main__": # pragma: no cover
430
438
  client.start()
431
439
 
432
440
  app = QApplication([])
433
- scan_control = ScanControl(
434
- client=client,
435
- ) # allowed_scans=["line_scan", "grid_scan"])
441
+ scan_control = ScanControl(client=client) # allowed_scans=["line_scan", "grid_scan"])
436
442
 
437
443
  window = scan_control
438
444
  window.show()
@@ -82,6 +82,7 @@ class RunScriptAction:
82
82
 
83
83
  class ModularToolBar(QToolBar):
84
84
  """Modular toolbar with optional automatic initialization.
85
+
85
86
  Args:
86
87
  parent (QWidget, optional): The parent widget of the toolbar. Defaults to None.
87
88
  auto_init (bool, optional): If True, automatically populates the toolbar based on the parent widget.
@@ -0,0 +1,33 @@
1
+ Metadata-Version: 2.3
2
+ Name: bec_widgets
3
+ Version: 0.53.0
4
+ Summary: BEC Widgets
5
+ Project-URL: Bug Tracker, https://gitlab.psi.ch/bec/bec_widgets/issues
6
+ Project-URL: Homepage, https://gitlab.psi.ch/bec/bec_widgets
7
+ License-File: LICENSE
8
+ Classifier: Development Status :: 3 - Alpha
9
+ Classifier: Programming Language :: Python :: 3
10
+ Classifier: Topic :: Scientific/Engineering
11
+ Requires-Python: >=3.10
12
+ Requires-Dist: bec-lib
13
+ Requires-Dist: black
14
+ Requires-Dist: h5py
15
+ Requires-Dist: jedi
16
+ Requires-Dist: pydantic
17
+ Requires-Dist: pyqtdarktheme
18
+ Requires-Dist: pyqtgraph
19
+ Requires-Dist: qtconsole
20
+ Requires-Dist: qtpy
21
+ Requires-Dist: zmq
22
+ Provides-Extra: dev
23
+ Requires-Dist: coverage; extra == 'dev'
24
+ Requires-Dist: fakeredis; extra == 'dev'
25
+ Requires-Dist: isort; extra == 'dev'
26
+ Requires-Dist: pytest; extra == 'dev'
27
+ Requires-Dist: pytest-qt; extra == 'dev'
28
+ Requires-Dist: pytest-random-order; extra == 'dev'
29
+ Requires-Dist: pytest-timeout; extra == 'dev'
30
+ Provides-Extra: pyqt5
31
+ Requires-Dist: pyqt5>=5.9; extra == 'pyqt5'
32
+ Provides-Extra: pyqt6
33
+ Requires-Dist: pyqt6>=6.7; extra == 'pyqt6'