GridPlanWidget¶
Example¶
API¶
Bases: QScrollArea
Widget to edit a grid plan.
The value is a useq.GridRowsColumns, useq.GridWidthHeight,
useq.GridFromEdges or useq.GridFromPolygon, depending on the mode
selected in the widget.
Referenced by:
Returned by:
valueChanged
¶
valueChanged = Signal(object)
Emitted with the new grid plan when the widget changes.
setMode
¶
setMode(mode: Mode | Literal['number', 'area', 'bounds', 'polygon']) -> None
Set the current mode, one of "number", "area", "bounds", or "polygon".
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
mode
|
Mode | Literal['number', 'area', 'bounds', 'polygon']
|
The mode to set. |
required |
value
¶
Return the current value of the widget as a grid plan.
Returns:
| Type | Description |
|---|---|
GridFromEdges | GridRowsColumns | GridWidthHeight
|
The current grid plan value of the widget. |
setValue
¶
Set the current value of the widget from a grid plan.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
value
|
GridFromEdges | GridRowsColumns | GridWidthHeight | GridFromPolygon
|
The grid plan to set. |
required |

