mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
(#438) Added unit to depth axis title. Did some refactoring.
This commit is contained in:
parent
7901c3c4bd
commit
dce0361660
@ -418,3 +418,25 @@ RimWellLogPlot::DepthTypeEnum RimWellLogPlot::depthType() const
|
||||
{
|
||||
return m_depthType.value();
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
QString RimWellLogPlot::depthPlotTitle() const
|
||||
{
|
||||
QString depthTitle = "Depth";
|
||||
|
||||
switch (m_depthType.value())
|
||||
{
|
||||
case MEASURED_DEPTH:
|
||||
depthTitle = "MD";
|
||||
break;
|
||||
|
||||
case TRUE_VERTICAL_DEPTH:
|
||||
depthTitle = "TVD";
|
||||
break;
|
||||
}
|
||||
|
||||
depthTitle += " [m]";
|
||||
return depthTitle;
|
||||
}
|
||||
|
@ -73,6 +73,7 @@ public:
|
||||
void setVisibleDepthRangeFromContents();
|
||||
|
||||
DepthTypeEnum depthType() const;
|
||||
QString depthPlotTitle() const;
|
||||
|
||||
virtual caf::PdmFieldHandle* userDescriptionField() { return &m_userName; }
|
||||
|
||||
|
@ -165,8 +165,7 @@ void RimWellLogPlotTrace::loadDataAndUpdate()
|
||||
firstAnchestorOrThisOfType(wellLogPlot);
|
||||
if (wellLogPlot)
|
||||
{
|
||||
QString depthTitle = wellLogPlot->depthType() == RimWellLogPlot::MEASURED_DEPTH ? "MD" : "TVD";
|
||||
m_viewer->setDepthTitle(depthTitle);
|
||||
m_viewer->setDepthTitle(wellLogPlot->depthPlotTitle());
|
||||
}
|
||||
|
||||
for (size_t cIdx = 0; cIdx < curves.size(); ++cIdx)
|
||||
|
Loading…
Reference in New Issue
Block a user