LTM Plot honour plot background color

.. more of the same as recently updated similarly for
   CP, PfPv, Histogram, AllPlot etc
This commit is contained in:
Mark Liversedge
2013-12-15 23:28:18 +00:00
parent a436f41b9f
commit 80cb8f464d

View File

@@ -49,6 +49,7 @@ LTMPlot::LTMPlot(LTMWindow *parent, Context *context) :
{
// don't do this ..
setAutoReplot(false);
setAutoFillBackground(true);
// setup my axes
// for now we limit to 4 on left and 4 on right
@@ -119,6 +120,19 @@ LTMPlot::configUpdate()
QPen gridPen(GColor(CPLOTGRID));
//gridPen.setStyle(Qt::DotLine);
grid->setPen(gridPen);
QPalette palette;
palette.setBrush(QPalette::Window, QBrush(GColor(CPLOTBACKGROUND)));
palette.setColor(QPalette::WindowText, GColor(CPLOTMARKER));
palette.setColor(QPalette::Text, GColor(CPLOTMARKER));
setPalette(palette);
foreach (QwtAxisId x, supportedAxes) {
axisWidget(x)->setPalette(palette);
axisWidget(x)->setPalette(palette);
}
axisWidget(QwtPlot::xBottom)->setPalette(palette);
this->legend()->setPalette(palette);
}
void