mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
Improve ensemble curve colors
* Use unique_ptr * Improve default assignment of curve appearance * Improve display of color tags in tree view items * Select curve or ensemble instead of plot * Only change curves connected to a Rim-object * Improve color management for ensemble curves Use a base color for statistics curves and set realization curves transparent Make sure new curves are assigned a unique color Harmonize how dropped addresses are handled * Update all tags always The update of tags for a subset of tree nodes is currently broken. Always update all tags. * Add const
This commit is contained in:
@@ -59,6 +59,8 @@ RimEnsembleStatistics::RimEnsembleStatistics( RimEnsembleCurveSetInterface* pare
|
||||
// Set to always show curves before the version this feature was introduced in
|
||||
m_showStatisticsCurveLegends = true;
|
||||
}
|
||||
|
||||
m_showColorField = true;
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
@@ -109,6 +111,14 @@ void RimEnsembleStatistics::disableMeanCurve( bool disable )
|
||||
m_showMeanCurve.uiCapability()->setUiReadOnly( disable );
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RimEnsembleStatistics::showColorField( bool show )
|
||||
{
|
||||
m_showColorField = show;
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
@@ -124,7 +134,8 @@ void RimEnsembleStatistics::fieldChangedByUi( const caf::PdmFieldHandle* changed
|
||||
|
||||
curveSet->updateStatisticsCurves();
|
||||
|
||||
if ( changedField == &m_active || changedField == &m_basedOnFilteredCases ) curveSet->updateEditors();
|
||||
// Trigger update of tree view editor for ensemble curve set as they depend on these fields
|
||||
if ( changedField == &m_active || changedField == &m_basedOnFilteredCases || changedField == &m_color ) curveSet->updateEditors();
|
||||
}
|
||||
|
||||
if ( changedField == &m_hideEnsembleCurves )
|
||||
@@ -150,7 +161,8 @@ void RimEnsembleStatistics::defineUiOrdering( QString uiConfigName, caf::PdmUiOr
|
||||
uiOrdering.add( &m_basedOnFilteredCases );
|
||||
uiOrdering.add( &m_includeIncompleteCurves );
|
||||
uiOrdering.add( &m_showCurveLabels );
|
||||
uiOrdering.add( &m_color );
|
||||
|
||||
if ( m_showColorField ) uiOrdering.add( &m_color );
|
||||
|
||||
auto group = uiOrdering.addNewGroup( "Curves" );
|
||||
if ( !curveSet->hasMeanData() ) group->add( &m_warningLabel );
|
||||
|
||||
Reference in New Issue
Block a user