mirror of
https://github.com/miek/inspectrum.git
synced 2026-03-04 15:34:21 +01:00
Adding checkbox to show / hide SigMF annotations
Signed-off-by: Jacob Gilbert <jacob.gilbert@protonmail.com>
This commit is contained in:
@@ -49,6 +49,8 @@ PlotView::PlotView(InputSource *input) : cursors(this), viewRange({0, 0})
|
||||
|
||||
enableScales(true);
|
||||
|
||||
enableAnnotations(true);
|
||||
|
||||
addPlot(spectrogramPlot);
|
||||
|
||||
mainSampleSource->subscribe(this);
|
||||
@@ -602,6 +604,14 @@ void PlotView::enableScales(bool enabled)
|
||||
viewport()->update();
|
||||
}
|
||||
|
||||
void PlotView::enableAnnotations(bool enabled)
|
||||
{
|
||||
if (spectrogramPlot != nullptr)
|
||||
spectrogramPlot->enableAnnotations(enabled);
|
||||
|
||||
viewport()->update();
|
||||
}
|
||||
|
||||
int PlotView::sampleToColumn(size_t sample)
|
||||
{
|
||||
return sample / samplesPerColumn();
|
||||
|
||||
Reference in New Issue
Block a user