mirror of
https://github.com/OPM/ResInsight.git
synced 2026-10-26 07:00:17 -05:00
#1136: Apply global curve appearance to summary plots and ensemble curve sets
This commit is contained in:
1 parent
68f41943e6
commit
83b4aa35a2
9 files changed
+283
-131
No files matched your search
@@ -32,6 +32,7 @@
|
||||
|
||||
#include "SummaryPlotCommands/RicSummaryPlotEditorUi.h"
|
||||
|
||||
#include "RimCurveStyleRules.h"
|
||||
#include "RimCustomObjectiveFunction.h"
|
||||
#include "RimCustomObjectiveFunctionCollection.h"
|
||||
#include "RimDeltaSummaryEnsemble.h"
|
||||
@@ -333,6 +334,23 @@ void RimEnsembleCurveSet::setColor( cvf::Color3f color )
|
||||
computeRealizationColor();
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RimEnsembleCurveSet::setColorAndUpdateCurves( cvf::Color3f color )
|
||||
{
|
||||
setColor( color );
|
||||
updateCurveColors();
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
cvf::Color3f RimEnsembleCurveSet::color() const
|
||||
{
|
||||
return m_mainEnsembleColor();
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
@@ -1415,7 +1433,13 @@ void RimEnsembleCurveSet::appendColorGroup( caf::PdmUiOrdering& uiOrdering )
|
||||
|
||||
if ( m_colorMode() == RimEnsembleCurveSetColorManager::ColorMode::SINGLE_COLOR )
|
||||
{
|
||||
auto plot = firstAncestorOrThisOfType<RimSummaryPlot>();
|
||||
const bool isColorGlobal = plot && plot->useGlobalCurveAppearance();
|
||||
m_mainEnsembleColor.uiCapability()->setUiReadOnly( isColorGlobal );
|
||||
colorsGroup->add( &m_mainEnsembleColor );
|
||||
if ( isColorGlobal )
|
||||
RimCurveStyleRules::addGlobalAppearanceLink( *colorsGroup,
|
||||
"The color is controlled by the <a href=\"dummy\">global curve appearance</a>." );
|
||||
}
|
||||
else if ( m_colorMode == ColorMode::BY_ENSEMBLE_PARAM )
|
||||
{
|
||||
|
||||
Reference in new issue
Block a user