daplis_rtp.gui.pixel_mask_window module
The per-pixel mask, in a window of its own.
The mask is 256 check boxes per board. Kept inside the tab they need a scroll area about 250 px tall, which is both too small to work in - a few rows of pixels visible at a time, out of 64 - and large enough to set the minimum height of the whole application, since the control column’s minimum is the sum of everything stacked in it.
So they live here instead. The tab keeps a button and a count, and the boxes open in a window that can be dragged next to the plot and left there: it is not modal, so the stream keeps running and the plot keeps refreshing while pixels are ticked off, which is the way masking is actually done - look at the peak, mask it, watch what is left.
The check boxes are created here but belong to the host tab, which reads them through ‘boxes’ and ‘grids’ exactly as it did when they sat in the scroll area; ‘grids[b].itemAt(i).widget()’ is still the box for pixel i, so the preset-mask and reset paths are unchanged.
- class daplis_rtp.gui.pixel_mask_window.PixelMaskWindow(parent=None, boards=(('', 4, 64),), font=None, title='Pixel mask', n_pixels=256)[source]
Bases:
QDialogNon-modal window holding one grid of check boxes per board.
- Parameters:
parent (QWidget) – The host tab. The window is a top-level one all the same, so it can be moved away from the application and left beside it.
boards (sequence) – One ‘(label, columns, rows)’ per board; ‘columns * rows’ must come to ‘n_pixels’. The boxes are created column by column, the order the tabs have always used.
font (QFont, optional) – Applied to every child, to match the tab it was opened from.
title (str, optional) – Window title.
n_pixels (int, optional) – Pixels per board, by default 256.
- changed
str = …, revision: 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
- clear_requested
str = …, revision: 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