Add wideband spectrum fill option

This commit is contained in:
2026-05-26 17:52:02 +03:00
parent f61290ad3d
commit ae1a7d9a6d
4 changed files with 90 additions and 11 deletions
+22 -8
View File
@@ -49,7 +49,8 @@ type
TOnAudioDevChange = procedure(DevIndex: Integer; const DevName: string) of object;
TOnAudioInDevChange = procedure(DevIndex: Integer; const DevName: string) of object;
TOnAudioBufferChange = procedure(BufferSize: Integer) of object;
TOnVisibilityChange = procedure(ShowSpectrum, ShowWaterfall, ShowWideband: Boolean) of object;
TOnVisibilityChange = procedure(ShowSpectrum, ShowWaterfall, ShowWideband,
WidebandFill: Boolean) of object;
TOnFPSChange = procedure(FPS: Integer) of object;
TOnThemeChange = procedure(LightTheme: Boolean) of object;
TOnWfAGCNFChange = procedure(WfAGC, WfNF: Boolean) of object;
@@ -121,6 +122,7 @@ type
FChkShowSpectrum: TFlatCheckBox;
FChkShowWaterfall: TFlatCheckBox;
FChkShowWideband: TFlatCheckBox;
FChkWidebandFill: TFlatCheckBox;
FCmbFPS: TFlatComboBox;
FChkLightTheme: TFlatCheckBox;
FCmbFreqMhzDigits: TFlatComboBox;
@@ -372,7 +374,8 @@ type
procedure RefreshAudioDevices(AudioOut: TAudioOutput; AudioIn: TAudioInput);
procedure LoadAudioBufferSize(BufferSize: Integer);
procedure LoadVisibility(ShowSpectrum, ShowWaterfall, ShowWideband: Boolean);
procedure LoadVisibility(ShowSpectrum, ShowWaterfall, ShowWideband,
WidebandFill: Boolean);
procedure LoadFPS(FPS: Integer);
procedure LoadLightTheme(ALight: Boolean);
procedure LoadFreqMhzDigits(Digits: Integer);
@@ -801,7 +804,7 @@ begin
Font.Color := CLR_TEXTDIM;
end;
Grp := MakeGroupPanel(FPageDisplay, 'Visible Panes', MARGIN, 86, 650, 86);
Grp := MakeGroupPanel(FPageDisplay, 'Visible Panes', MARGIN, 86, 650, 112);
FChkShowSpectrum := TFlatCheckBox.Create(Self);
FChkShowSpectrum.Parent := Grp;
@@ -833,7 +836,17 @@ begin
FChkShowWideband.Font.Size := 9;
FChkShowWideband.OnChange := OnVisibilityChkChange;
Grp := MakeGroupPanel(FPageDisplay, 'Performance', MARGIN, 186, 650, 92);
FChkWidebandFill := TFlatCheckBox.Create(Self);
FChkWidebandFill.Parent := Grp;
FChkWidebandFill.Caption := 'Wideband gradient fill';
FChkWidebandFill.SetBounds(PAD + (CHKW + 20) * 2, R1 + 28, CHKW, 22);
FChkWidebandFill.Checked := False;
FChkWidebandFill.Font.Color := CLR_TEXT;
FChkWidebandFill.Font.Name := UI_FONT;
FChkWidebandFill.Font.Size := 9;
FChkWidebandFill.OnChange := OnVisibilityChkChange;
Grp := MakeGroupPanel(FPageDisplay, 'Performance', MARGIN, 212, 650, 92);
MakeLbl(Grp, 'Refresh rate', PAD, R1 + 5, LW);
FCmbFPS := MakeCombo(Grp, CX, R1, 140, OnFPSCmbChange);
@@ -841,7 +854,7 @@ begin
FCmbFPS.Items.Add(FPS_NAMES[i]);
FCmbFPS.ItemIndex := 8;
Grp := MakeGroupPanel(FPageDisplay, 'Appearance', MARGIN, 292, 650, 68);
Grp := MakeGroupPanel(FPageDisplay, 'Appearance', MARGIN, 318, 650, 68);
FChkLightTheme := TFlatCheckBox.Create(Self);
FChkLightTheme.Parent := Grp;
@@ -853,7 +866,7 @@ begin
FChkLightTheme.Font.Size := 9;
FChkLightTheme.OnChange := OnLightThemeChkChange;
Grp := MakeGroupPanel(FPageDisplay, 'VFO Display', MARGIN, 378, 650, 92);
Grp := MakeGroupPanel(FPageDisplay, 'VFO Display', MARGIN, 404, 650, 92);
MakeLbl(Grp, 'Frequency range', PAD, R1 + 5, LW);
FCmbFreqMhzDigits := MakeCombo(Grp, CX, R1, 240, OnFreqMhzDigitsCmbChange);
@@ -2313,13 +2326,14 @@ begin
end;
procedure TSettingsForm.LoadVisibility(ShowSpectrum, ShowWaterfall,
ShowWideband: Boolean);
ShowWideband, WidebandFill: Boolean);
begin
FLoading := True;
try
FChkShowSpectrum.Checked := ShowSpectrum;
FChkShowWaterfall.Checked := ShowWaterfall;
FChkShowWideband.Checked := ShowWideband;
FChkWidebandFill.Checked := WidebandFill;
finally
FLoading := False;
end;
@@ -2341,7 +2355,7 @@ begin
if FLoading then Exit;
if not Assigned(FOnVisibilityChange) then Exit;
FOnVisibilityChange(FChkShowSpectrum.Checked, FChkShowWaterfall.Checked,
FChkShowWideband.Checked);
FChkShowWideband.Checked, FChkWidebandFill.Checked);
end;
procedure TSettingsForm.OnLightThemeChkChange(Sender: TObject);