7.5.3.3. pymodaq_gui.managers.roi_manager module
- class pymodaq_gui.managers.roi_manager.CircularROI(index=0, pos=[0, 0], size=[10, 10], **kwargs)[source]
Bases:
EllipseROI
- class pymodaq_gui.managers.roi_manager.EllipseROI(index=0, pos=[0, 0], size=[10, 10], **kwargs)[source]
Bases:
ROIElliptical ROI subclass with one scale handle and one rotation handle.
Arguments
pos
(length-2 sequence) The position of the ROI’s origin.
size
(length-2 sequence) The size of the ROI’s bounding rectangle.
**args
All extra keyword arguments are passed to ROI()
Methods
getArrayRegion(arr[, img, axes])Return the result of ROI.getArrayRegion() masked by the elliptical shape of the ROI.
paint(self, painter, option[, widget])shape(self)- getArrayRegion(arr, img=None, axes=(0, 1), **kwds)[source]
Return the result of ROI.getArrayRegion() masked by the elliptical shape of the ROI. Regions outside the ellipse are set to 0.
- class pymodaq_gui.managers.roi_manager.LinearROI(index=0, pos=[0, 10], name='roi', **kwargs)[source]
Bases:
LinearRegionItem- Attributes:
- color
Methods
contextMenuEvent(self, event)pos(self)setPos(setPos)center
copy_clipboard
emit_index_signal
index_signal
setPen
- setPos(self, pos: Union[QPointF, QPoint]) setPos(self, ax: float, ay: float)[source]
- setPos(self, ax: float, ay: float) None
- property color
- index_signal
int = …, arguments: Sequence = …) -> PYQT_SIGNAL
types is normally a sequence of individual types. Each type is either a type object or a string that is the name of a C++ type. Alternatively each type could itself be a sequence of types each describing a different overloaded signal. name is the optional C++ name of the signal. If it is not specified then the name of the class attribute that is bound to the signal is used. revision is the optional revision of the signal that is exported to QML. If it is not specified then 0 is used. arguments is the optional sequence of the names of the signal’s arguments.
- Type:
pyqtSignal(*types, name
- Type:
str = …, revision
- class pymodaq_gui.managers.roi_manager.ROI(*args, index=0, name='roi', **kwargs)[source]
Bases:
ROI- Attributes:
- color
Methods
center()Get the center position of the ROI
contextMenuEvent(self, event)copy_clipboard
emit_index_signal
height
index_signal
set_center
set_positions
width
- property color
- index_signal
int = …, arguments: Sequence = …) -> PYQT_SIGNAL
types is normally a sequence of individual types. Each type is either a type object or a string that is the name of a C++ type. Alternatively each type could itself be a sequence of types each describing a different overloaded signal. name is the optional C++ name of the signal. If it is not specified then the name of the class attribute that is bound to the signal is used. revision is the optional revision of the signal that is exported to QML. If it is not specified then 0 is used. arguments is the optional sequence of the names of the signal’s arguments.
- Type:
pyqtSignal(*types, name
- Type:
str = …, revision
- class pymodaq_gui.managers.roi_manager.ROIBrushable(brush=None, *args, **kwargs)[source]
Bases:
ROIMethods
paint(self, painter, option[, widget])setBrush(*br, **kargs)Set the brush that fills the region.
- class pymodaq_gui.managers.roi_manager.ROIManager(viewer_widget=None, ROI_type='1D')[source]
Bases:
QObject- Attributes:
- ROIs
Methods
add_roi_programmatically
clear_ROI
color_signal
emit_colors
get_roi
get_roi_from_index
load_ROI
new_ROI_signal
remove_ROI_signal
remove_roi_programmatically
roi_changed
roi_format
roi_tree_changed
roi_update_children
roi_value_changed
save_ROI
set_roi
setupUI
update_roi
update_roi_tree
update_use_channel
- property ROIs
- color_list = array([[255, 255, 255], [255, 0, 0], [ 0, 255, 0], [ 0, 0, 255], [ 14, 207, 189], [207, 14, 166], [207, 204, 14]])
- color_signal
int = …, arguments: Sequence = …) -> PYQT_SIGNAL
types is normally a sequence of individual types. Each type is either a type object or a string that is the name of a C++ type. Alternatively each type could itself be a sequence of types each describing a different overloaded signal. name is the optional C++ name of the signal. If it is not specified then the name of the class attribute that is bound to the signal is used. revision is the optional revision of the signal that is exported to QML. If it is not specified then 0 is used. arguments is the optional sequence of the names of the signal’s arguments.
- Type:
pyqtSignal(*types, name
- Type:
str = …, revision
- new_ROI_signal
int = …, arguments: Sequence = …) -> PYQT_SIGNAL
types is normally a sequence of individual types. Each type is either a type object or a string that is the name of a C++ type. Alternatively each type could itself be a sequence of types each describing a different overloaded signal. name is the optional C++ name of the signal. If it is not specified then the name of the class attribute that is bound to the signal is used. revision is the optional revision of the signal that is exported to QML. If it is not specified then 0 is used. arguments is the optional sequence of the names of the signal’s arguments.
- Type:
pyqtSignal(*types, name
- Type:
str = …, revision
- remove_ROI_signal
int = …, arguments: Sequence = …) -> PYQT_SIGNAL
types is normally a sequence of individual types. Each type is either a type object or a string that is the name of a C++ type. Alternatively each type could itself be a sequence of types each describing a different overloaded signal. name is the optional C++ name of the signal. If it is not specified then the name of the class attribute that is bound to the signal is used. revision is the optional revision of the signal that is exported to QML. If it is not specified then 0 is used. arguments is the optional sequence of the names of the signal’s arguments.
- Type:
pyqtSignal(*types, name
- Type:
str = …, revision
- roi_changed
int = …, arguments: Sequence = …) -> PYQT_SIGNAL
types is normally a sequence of individual types. Each type is either a type object or a string that is the name of a C++ type. Alternatively each type could itself be a sequence of types each describing a different overloaded signal. name is the optional C++ name of the signal. If it is not specified then the name of the class attribute that is bound to the signal is used. revision is the optional revision of the signal that is exported to QML. If it is not specified then 0 is used. arguments is the optional sequence of the names of the signal’s arguments.
- Type:
pyqtSignal(*types, name
- Type:
str = …, revision
- roi_update_children
int = …, arguments: Sequence = …) -> PYQT_SIGNAL
types is normally a sequence of individual types. Each type is either a type object or a string that is the name of a C++ type. Alternatively each type could itself be a sequence of types each describing a different overloaded signal. name is the optional C++ name of the signal. If it is not specified then the name of the class attribute that is bound to the signal is used. revision is the optional revision of the signal that is exported to QML. If it is not specified then 0 is used. arguments is the optional sequence of the names of the signal’s arguments.
- Type:
pyqtSignal(*types, name
- Type:
str = …, revision
- roi_value_changed
int = …, arguments: Sequence = …) -> PYQT_SIGNAL
types is normally a sequence of individual types. Each type is either a type object or a string that is the name of a C++ type. Alternatively each type could itself be a sequence of types each describing a different overloaded signal. name is the optional C++ name of the signal. If it is not specified then the name of the class attribute that is bound to the signal is used. revision is the optional revision of the signal that is exported to QML. If it is not specified then 0 is used. arguments is the optional sequence of the names of the signal’s arguments.
- Type:
pyqtSignal(*types, name
- Type:
str = …, revision
- class pymodaq_gui.managers.roi_manager.ROIPositionMapper(roi_pos, roi_size)[source]
Bases:
QWidgetWidget presenting a Tree structure representing a ROI positions.
Methods
show_dialog
- class pymodaq_gui.managers.roi_manager.ROISaver(msgbox=False, det_modules=[])[source]
Bases:
objectMethods
set_file_roi
set_new_roi
show_rois
- class pymodaq_gui.managers.roi_manager.ROIScalableGroup(roi_type='1D', **opts)[source]
Bases:
GroupParameterMethods
addNew([typ])This method is called when the user has requested to add a new item to the group.