(#396) Added grid to well log trace plot. Using light gray solid lines.

This commit is contained in:
Pål Hagen 2015-08-31 11:39:59 +02:00
parent 2bac87972f
commit 513e9d9075
2 changed files with 16 additions and 0 deletions

View File

@ -19,12 +19,17 @@
#include "RiuWellLogTracePlot.h"
#include "qwt_plot_grid.h"
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
RiuWellLogTracePlot::RiuWellLogTracePlot(QWidget* parent)
: QwtPlot(parent)
{
m_grid = new QwtPlotGrid();
m_grid->attach(this);
setDefaults();
}
@ -33,6 +38,8 @@ RiuWellLogTracePlot::RiuWellLogTracePlot(QWidget* parent)
//--------------------------------------------------------------------------------------------------
RiuWellLogTracePlot::~RiuWellLogTracePlot()
{
m_grid->detach();
delete m_grid;
}
@ -53,4 +60,8 @@ void RiuWellLogTracePlot::setDefaults()
{
canvasFrame->setFrameShape(QFrame::NoFrame);
}
QPen gridPen(Qt::SolidLine);
gridPen.setColor(Qt::lightGray);
m_grid->setPen(gridPen);
}

View File

@ -21,6 +21,8 @@
#include "qwt_plot.h"
class QwtPlotGrid;
//==================================================================================================
//
// RiuWellLogTracePlot
@ -36,5 +38,8 @@ public:
private:
void setDefaults();
private:
QwtPlotGrid* m_grid;
};