diff --git a/src/pymmcore_widgets/_mda/_channel_table_widget.py b/src/pymmcore_widgets/_mda/_channel_table_widget.py index bcd6298a7..e495dc9fe 100644 --- a/src/pymmcore_widgets/_mda/_channel_table_widget.py +++ b/src/pymmcore_widgets/_mda/_channel_table_widget.py @@ -209,7 +209,7 @@ def _pick_first_unused_channel(self, channel_group: str) -> str: return available[0] def _create_spinbox( - self, range: tuple[int, int], double: bool = False + self, range: tuple[int | float, int | float], double: bool = False ) -> QDoubleSpinBox: dspinbox = QDoubleSpinBox() if double else QSpinBox() dspinbox.setButtonSymbols(QAbstractSpinBox.ButtonSymbols.NoButtons) @@ -249,8 +249,7 @@ def _create_new_row(self, channel: useq.Channel | None = None) -> None: channel_combo.setCurrentText(channel.config) # exposure spinbox - channel_exp_spinbox = self._create_spinbox((0, 10000), True) - channel_exp_spinbox.setMinimum(1) + channel_exp_spinbox = self._create_spinbox((0.01, 999999), True) channel_exp_spinbox.setValue(channel.exposure or self._mmc.getExposure() or 100) # z offset spinbox diff --git a/src/pymmcore_widgets/useq_widgets/_channels.py b/src/pymmcore_widgets/useq_widgets/_channels.py index 13741b4f7..a9de33eaa 100644 --- a/src/pymmcore_widgets/useq_widgets/_channels.py +++ b/src/pymmcore_widgets/useq_widgets/_channels.py @@ -30,7 +30,7 @@ class ChannelTable(DataTableWidget): # fmt: off GROUP = TextColumn(key="group", default=DEFAULT_GROUP, hidden=True) CONFIG = TextColumn(key="config", default=None, is_row_selector=True) - EXPOSURE = FloatColumn(key="exposure", header="Exposure [ms]", default=100.0, minimum=1) # noqa + EXPOSURE = FloatColumn(key="exposure", header="Exposure [ms]", default=100.0, minimum=0.01) # noqa ACQUIRE_EVERY = IntColumn(key="acquire_every", default=1, minimum=1) DO_STACK = BoolColumn(key="do_stack", default=True) Z_OFFSET = FloatColumn(key="z_offset", default=0.0, minimum=-10000, maximum=10000) diff --git a/src/pymmcore_widgets/useq_widgets/_column_info.py b/src/pymmcore_widgets/useq_widgets/_column_info.py index a64f0d080..2435ca6bc 100644 --- a/src/pymmcore_widgets/useq_widgets/_column_info.py +++ b/src/pymmcore_widgets/useq_widgets/_column_info.py @@ -263,7 +263,7 @@ class TableDoubleSpinBox(_TableSpinboxMixin, QDoubleSpinBox): class _RangeColumn(WidgetColumn, Generic[W, T]): data_type: WdgGetSet[W, float] minimum: float = 0 - maximum: float = 10_000 + maximum: float = 999_999 def _init_widget(self) -> W: wdg = self.data_type.widget()