summaryrefslogtreecommitdiff
path: root/gr-qtgui/lib/TimeDomainDisplayPlot.cc
diff options
context:
space:
mode:
Diffstat (limited to 'gr-qtgui/lib/TimeDomainDisplayPlot.cc')
-rw-r--r--gr-qtgui/lib/TimeDomainDisplayPlot.cc9
1 files changed, 8 insertions, 1 deletions
diff --git a/gr-qtgui/lib/TimeDomainDisplayPlot.cc b/gr-qtgui/lib/TimeDomainDisplayPlot.cc
index ee13a7dce..f635a2b0c 100644
--- a/gr-qtgui/lib/TimeDomainDisplayPlot.cc
+++ b/gr-qtgui/lib/TimeDomainDisplayPlot.cc
@@ -213,6 +213,12 @@ TimeDomainDisplayPlot::setTitle(int which, QString title)
_plot_curve[which]->setTitle(title);
}
+void
+TimeDomainDisplayPlot::setColor(int which, QString color)
+{
+ _plot_curve[which]->setPen(QPen(color));
+}
+
void TimeDomainDisplayPlot::replot()
{
QwtPlot::replot();
@@ -221,7 +227,8 @@ void TimeDomainDisplayPlot::replot()
void
TimeDomainDisplayPlot::resizeSlot( QSize *s )
{
- resize(s->width(), s->height());
+ // -10 is to spare some room for the legend and x-axis label
+ resize(s->width()-10, s->height()-10);
}
void TimeDomainDisplayPlot::PlotNewData(const std::vector<double*> dataPoints,