diff --git a/src/plot.cpp b/src/plot.cpp --- a/src/plot.cpp +++ b/src/plot.cpp @@ -73,6 +73,16 @@ Plot::Plot(QWidget* parent) : demoIndicator.setText(demoText); demoIndicator.hide(); demoIndicator.attach(this); + + // init no channels are visible indicator + QwtText noChannelText(" No Visible Channels "); + noChannelText.setColor(QColor("white")); + noChannelText.setBackgroundBrush(Qt::darkBlue); + noChannelText.setBorderRadius(4); + noChannelText.setRenderFlags(Qt::AlignHCenter | Qt::AlignVCenter); + noChannelIndicator.setText(noChannelText); + noChannelIndicator.hide(); + noChannelIndicator.attach(this); } Plot::~Plot() @@ -163,6 +173,12 @@ void Plot::showDemoIndicator(bool show) replot(); } +void Plot::showNoChannel(bool show) +{ + noChannelIndicator.setVisible(show); + replot(); +} + void Plot::unzoom() { zoomer.zoom(0);