6.3.5. Plotting utility classes¶
Summary of the classes
|
Allows selection of a given 2D viewer to get scan info |
- class pymodaq.utils.plotting.scan_selector.ScanSelector(viewer_items: Optional[List[SelectorItem]] = None, positions: Optional[List] = None)[source]¶
Allows selection of a given 2D viewer to get scan info
respectively scan2D or scan Tabular from respectively a rectangular ROI or a polyline
- Parameters
viewer_items (dict) – where the keys are the titles of the sources while the values are dict with keys * viewers: list of plotitems * names: list of viewer titles
selector_type (str) – either ‘PolyLines’ corresponding to a polyline ROI or ‘Rectangle’ for a rect Roi
positions (list) – a sequence of 2 floats sequence [(x1,y1),(x2,y2),(x3,y3),…]
- Attributes
- selector_type
- source_name
- viewers_items
Methods
value_changed
(param)Non-mandatory method to be subclassed for actions to perform (methods to call) when one of the param's value in self._settings is changed
hide
remove_selector
scan_select_signal
show
show_selector
update_model
update_model_data
update_scan
update_selector_type
update_table_view
- value_changed(param)[source]¶
Non-mandatory method to be subclassed for actions to perform (methods to call) when one of the param’s value in self._settings is changed
- Parameters
param (Parameter) – the parameter whose value just changed
Examples
>>> if param.name() == 'do_something': >>> if param.value(): >>> print('Do something') >>> self.settings.child('main_settings', 'something_done').setValue(False)