mirror of
https://git.vladimir.cc/vladimir/ewsdr.git
synced 2026-08-26 21:57:32 +00:00
Align spectrum grid and ruler to FM tuning step
When FM mode is active, vertical grid lines and frequency labels snap to FM channel boundaries (FM_STEP_HZ) instead of the fixed 8-division layout. Grid and label density auto-adapt: lines thinner than 4px are thinned, labels are spaced so they never overlap (short tick shown between labeled lines). Grid cache invalidates on center-freq, step, or span changes. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -2797,6 +2797,10 @@ begin
|
||||
FSpecView.SpanHz := FSpanHz;
|
||||
FSpecView.Mode := FMode;
|
||||
FSpecView.FilterBW := FFilterBW;
|
||||
if FMode = MODE_FM then
|
||||
FSpecView.FMGridStepHz := FM_STEP_HZ[FFMStepIdx]
|
||||
else
|
||||
FSpecView.FMGridStepHz := 0;
|
||||
// TX overlay следует за активной TX-частотой (учитывает split). При CTUN
|
||||
// спектр TX будет отрисован на VFO, а не в центре дисплея.
|
||||
FSpecView.TXFreq := ActiveTXFreqHz;
|
||||
@@ -4805,6 +4809,8 @@ begin
|
||||
if FBtnFMSteps[Idx] <> nil then
|
||||
FBtnFMSteps[Idx].Active := True;
|
||||
if FWebServer <> nil then FWebServer.FMStepIdx := Idx;
|
||||
if (FMode = MODE_FM) and (FSpecView <> nil) then
|
||||
FSpecView.FMGridStepHz := FM_STEP_HZ[Idx];
|
||||
end;
|
||||
|
||||
procedure TMainForm.BtnFMStepClick(Sender: TObject);
|
||||
|
||||
Reference in New Issue
Block a user