Skip to content

Commit fd5756c

Browse files
committed
Fix: prevent manual cursor movement in SignalBaselineDialog
(cherry picked from commit ccc95a4)
1 parent 552c5b6 commit fd5756c

1 file changed

Lines changed: 6 additions & 0 deletions

File tree

cdl/widgets/signalbaseline.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,12 @@ def __setup_dialog(self) -> None:
5757
plot.SIG_RANGE_CHANGED.connect(self.xrange_changed)
5858
plot.SIG_MARKER_CHANGED.connect(self.cursor_changed)
5959
self.cursor = make.hcursor(0.0, _("Base line") + " = %g")
60+
61+
# The following line is needed to avoid the cursor being movable manually
62+
# by the user, which would not make sense in this dialog.
63+
# TODO: Calling `set_resizable` for this is not intuitive: report upstream?
64+
self.cursor.set_resizable(False)
65+
6066
self.xrange = make.range(obj.x[0], obj.x[int(0.2 * len(obj.x))])
6167
for item in (self.curve, self.cursor, self.xrange):
6268
plot.add_item(item)

0 commit comments

Comments
 (0)