(#491) Updating X-range fields according to changes in plots

This commit is contained in:
Pål Hagen
2015-09-18 10:50:01 +02:00
parent 1df537627d
commit 2653bcf1a9
7 changed files with 91 additions and 5 deletions

View File

@@ -18,7 +18,9 @@
/////////////////////////////////////////////////////////////////////////////////
#include "RimWellLogPlotCurve.h"
#include "RimWellLogPlot.h"
#include "RiuWellLogTracePlot.h"
#include "RiuWellLogPlotCurve.h"
@@ -157,6 +159,26 @@ bool RimWellLogPlotCurve::depthRange(double* minimumDepth, double* maximumDepth)
return true;
}
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
bool RimWellLogPlotCurve::valueRange(double* minimumValue, double* maximumValue) const
{
CVF_ASSERT(minimumValue && maximumValue);
CVF_ASSERT(m_plotCurve);
if (m_plotCurve->data()->size() < 1)
{
return false;
}
*minimumValue = m_plotCurve->minXValue();
*maximumValue = m_plotCurve->maxXValue();
return true;
}
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
@@ -180,4 +202,3 @@ QwtPlotCurve* RimWellLogPlotCurve::plotCurve() const
{
return m_plotCurve;
}