fix: a fit undoes an x zoom instead of redefining the time window
The previous commit took "fit x sets the window properly" to mean a fit should frame the data and propagate that as the new time scale. It should not: a fit is a plot interaction, and the window is also the trigger's event span and how the samples are stored, so a fit that framed the data could re-plan the rings and drop the history on a menu click. What a fit means here is the undo of a zoom -- a 2 s window zoomed into reads 2 s again. `fit_x()` therefore reads `window_s_` and never writes it. Live it takes the window-control path with the window already set, which re-arms the follow and parks the newest span at the live edge. Pinned -- a held event, a filling capture or a paused view -- it restores the pin's full range, which is the snapshot's own span and may be narrower than the requested window, and it writes the per-row member axes as well as the link group: `hold_pinned_window()` prefers a member that differs from `pinned_stated_`, so writing the group alone is reverted to the zoomed range one frame later. `apply_window_scale()` is folded back into `apply_time_window()`, which the window control is again the only caller of. The probe now zooms in before fitting, since otherwise there is nothing to undo, and reports `pinned=`. `window` and `event_span` must be unchanged on every line. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
1 parent
9888fd9977
commit
3d7e214295
7 files changed
+193
-150
No files matched your search
@@ -19,6 +19,9 @@ unit, width-locked so a change of window cannot widen the header bar.
|
||||
value. Stamping at the end of a group would shift every trace half a stored sample late.
|
||||
• Moving the window across a decimation boundary rebuilds the buffer and drops the history.
|
||||
Walking it inside one decade is free.
|
||||
• <b>This control is the only thing that changes the window.</b> A zoom, a pan or a fit moves the
|
||||
view <i>inside</i> it and leaves it alone — which is the point of the previous bullet: a wheel
|
||||
notch that redefined the window could re-plan the buffer and throw your samples away.
|
||||
• The trigger sees the <i>stored</i> (filtered) signal, not the wire signal, because an edge
|
||||
found on a sample that is not in the buffer could not be cut out of it.
|
||||
|
||||
|
||||
@@ -19,10 +19,11 @@ The full table is in the shortcut overview (<tt>Ctrl+/</tt>).
|
||||
• A <i>pinned</i> view is navigable within its own data but cannot leave it. While an event is
|
||||
held, a capture is filling, or the view is paused, a zoom <i>in</i> works normally — "not
|
||||
outside the event" is not "not readable" — but a pan or a zoom out is clamped to the data.
|
||||
• A gesture never changes the <i>time window</i>, only the view inside it. The window is what the
|
||||
header control states, and it also sets the trigger's event span and how the buffer is stored —
|
||||
so a wheel that redefined it would re-plan the buffer and drop your history. The two fits
|
||||
<i>do</i> set it, deliberately, and the control then reads the fitted value back.
|
||||
• Nothing you do on the plot changes the <i>time window</i> — only the header control does. A
|
||||
zoom or a pan moves the view inside the window; <b>f</b> (and Fit X axis) is the <i>undo</i> of a
|
||||
zoom, so a 2 s window zoomed into reads 2 s again. The window is more than the axis: it is also
|
||||
the trigger's event span and how the samples are stored, so a wheel notch that redefined it
|
||||
would re-plan the buffer and drop your history.
|
||||
• A live view is clamped to the window you asked for, not to what the ring happens to hold.
|
||||
That is why a buffer that has only just started filling leaves its left-hand side empty
|
||||
instead of squeezing the window down to the first few samples.
|
||||
|
||||
Reference in new issue
Block a user