mirror of
https://github.com/OPM/ResInsight.git
synced 2026-10-14 09:22:13 -05:00
Add support for summary cross plot curves in summary plots
This commit is contained in:
1 parent
b87fa0bc74
commit
146412c600
44 files changed
+970
-440
No files matched your search
@@ -65,6 +65,39 @@ RimSummaryCurveAutoName::RimSummaryCurveAutoName()
|
||||
}
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
QString RimSummaryCurveAutoName::curveName( const RiaSummaryCurveAddress& summaryCurveAddress,
|
||||
const RimSummaryNameHelper* currentNameHelper,
|
||||
const RimSummaryNameHelper* plotNameHelper ) const
|
||||
{
|
||||
QString name;
|
||||
|
||||
{
|
||||
auto nameForY = curveNameY( summaryCurveAddress.summaryAddressY(), currentNameHelper, plotNameHelper );
|
||||
if ( nameForY.isEmpty() )
|
||||
{
|
||||
nameForY = curveNameY( summaryCurveAddress.summaryAddressY(), nullptr, nullptr );
|
||||
}
|
||||
|
||||
name += nameForY;
|
||||
}
|
||||
|
||||
if ( summaryCurveAddress.summaryAddressX().category() != SummaryCategory::SUMMARY_TIME )
|
||||
{
|
||||
auto nameForX = curveNameX( summaryCurveAddress.summaryAddressX(), currentNameHelper, plotNameHelper );
|
||||
if ( nameForX.isEmpty() )
|
||||
{
|
||||
nameForX = curveNameX( summaryCurveAddress.summaryAddressX(), nullptr, nullptr );
|
||||
}
|
||||
|
||||
if ( nameForX != name ) name += " | " + nameForX;
|
||||
}
|
||||
|
||||
return name;
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
@@ -193,7 +226,7 @@ QString RimSummaryCurveAutoName::buildCurveName( const RifEclipseSummaryAddress&
|
||||
|
||||
if ( m_vectorName || m_longVectorName )
|
||||
{
|
||||
bool skipSubString = currentNameHelper && currentNameHelper->vectorNames().size() == 1;
|
||||
bool skipSubString = currentNameHelper && currentNameHelper->isPlotDisplayingSingleCurve();
|
||||
if ( !skipSubString )
|
||||
{
|
||||
if ( m_longVectorName() )
|
||||
|
||||
Reference in new issue
Block a user