mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
Turn off statistics curve legends by default and add option to turn them on,
This commit is contained in:
parent
4389b15e37
commit
3772fbac79
@ -1804,6 +1804,8 @@ void RimEnsembleCurveSet::updateStatisticsCurves( const std::vector<RimSummaryCa
|
||||
curve->setSummaryAddressYAndApplyInterpolation( address );
|
||||
curve->setLeftOrRightAxisY( axisY() );
|
||||
|
||||
curve->setShowInLegend( m_statistics->showStatisticsCurveLegends() );
|
||||
|
||||
curve->updateCurveVisibility();
|
||||
curve->loadDataAndUpdate( false );
|
||||
curve->updatePlotAxis();
|
||||
|
@ -35,6 +35,7 @@ RimEnsembleStatistics::RimEnsembleStatistics( RimEnsembleCurveSetInterface* pare
|
||||
m_parentCurveSet = parentCurveSet;
|
||||
|
||||
CAF_PDM_InitField( &m_active, "Active", true, "Show Statistics Curves" );
|
||||
CAF_PDM_InitField( &m_showStatisticsCurveLegends, "ShowStatisticsCurveLegends", false, "Show Statistics Curve Legends" );
|
||||
CAF_PDM_InitField( &m_hideEnsembleCurves, "HideEnsembleCurves", false, "Hide Ensemble Curves" );
|
||||
CAF_PDM_InitField( &m_basedOnFilteredCases, "BasedOnFilteredCases", false, "Based on Filtered Cases" );
|
||||
CAF_PDM_InitField( &m_showP10Curve, "ShowP10Curve", true, "P10" );
|
||||
@ -108,7 +109,8 @@ void RimEnsembleStatistics::fieldChangedByUi( const caf::PdmFieldHandle* changed
|
||||
{
|
||||
if ( changedField == &m_active || changedField == &m_basedOnFilteredCases || changedField == &m_showP10Curve ||
|
||||
changedField == &m_showP50Curve || changedField == &m_showP90Curve || changedField == &m_showMeanCurve ||
|
||||
changedField == &m_showCurveLabels || changedField == &m_color || changedField == &m_includeIncompleteCurves )
|
||||
changedField == &m_showCurveLabels || changedField == &m_color || changedField == &m_includeIncompleteCurves ||
|
||||
changedField == &m_showStatisticsCurveLegends )
|
||||
{
|
||||
auto curveSet = m_parentCurveSet;
|
||||
if ( !curveSet ) return;
|
||||
@ -135,6 +137,7 @@ void RimEnsembleStatistics::defineUiOrdering( QString uiConfigName, caf::PdmUiOr
|
||||
auto curveSet = m_parentCurveSet;
|
||||
|
||||
uiOrdering.add( &m_active );
|
||||
if ( isActive() ) uiOrdering.add( &m_showStatisticsCurveLegends );
|
||||
uiOrdering.add( &m_hideEnsembleCurves );
|
||||
uiOrdering.add( &m_basedOnFilteredCases );
|
||||
uiOrdering.add( &m_includeIncompleteCurves );
|
||||
|
@ -36,6 +36,7 @@ public:
|
||||
|
||||
bool isActive() const;
|
||||
void setShowStatisticsCurves( bool show );
|
||||
bool showStatisticsCurveLegends() const { return m_showStatisticsCurveLegends; }
|
||||
bool hideEnsembleCurves() const { return m_hideEnsembleCurves; }
|
||||
bool basedOnFilteredCases() const { return m_basedOnFilteredCases; }
|
||||
bool showP10Curve() const { return m_showP10Curve; }
|
||||
@ -59,6 +60,7 @@ private:
|
||||
RimEnsembleCurveSetInterface* m_parentCurveSet;
|
||||
|
||||
caf::PdmField<bool> m_active;
|
||||
caf::PdmField<bool> m_showStatisticsCurveLegends;
|
||||
caf::PdmField<bool> m_hideEnsembleCurves;
|
||||
caf::PdmField<bool> m_basedOnFilteredCases;
|
||||
caf::PdmField<bool> m_showP10Curve;
|
||||
|
@ -945,6 +945,7 @@ void RimEnsembleWellLogCurveSet::updateStatisticsCurves( const std::vector<RimWe
|
||||
curve->setSymbolLabel( caf::AppEnum<RimEnsembleWellLogStatistics::StatisticsType>::uiText( statisticsType ) );
|
||||
}
|
||||
curve->setLineStyle( RiuQwtPlotCurveDefines::LineStyleEnum::STYLE_SOLID );
|
||||
curve->setShowInLegend( m_statistics->showStatisticsCurveLegends() );
|
||||
|
||||
plotTrack->addCurve( curve );
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user