Create Grid plot collection and allow creation of new combination plots

This commit is contained in:
Gaute Lindkvist
2019-10-31 13:48:40 +01:00
parent e042b2d17b
commit 30db19a1d0
55 changed files with 1208 additions and 597 deletions

View File

@@ -24,6 +24,10 @@
#include "RiuQwtPlotWidget.h"
#include "RiuWellLogPlot.h"
#include "RimGridCrossPlot.h"
#include "RimGridCrossPlotCollection.h"
#include "RimSummaryPlot.h"
#include "RimSummaryPlotCollection.h"
#include "RimWellLogCurve.h"
#include "RimWellLogPlot.h"
#include "RimWellLogTrack.h"
@@ -83,33 +87,3 @@ void RicWellLogPlotTrackFeatureImpl::moveCurvesToWellLogPlotTrack( RimWellLogTra
destTrack->updateParentPlotZoom();
destTrack->updateConnectedEditors();
}
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
void RicWellLogPlotTrackFeatureImpl::movePlotsToGridPlotWindow( RimGridPlotWindow* gridPlotWindow,
const std::vector<RimPlotInterface*>& plotsToMove,
RimPlotInterface* plotToInsertAfter )
{
CVF_ASSERT( gridPlotWindow );
for ( size_t tIdx = 0; tIdx < plotsToMove.size(); tIdx++ )
{
RimPlotInterface* plot = plotsToMove[tIdx];
caf::PdmObject* pdmObject = dynamic_cast<caf::PdmObject*>( plot );
RimGridPlotWindow* srcPlot;
pdmObject->firstAncestorOrThisOfType( srcPlot );
if ( srcPlot )
{
srcPlot->removePlot( plot );
}
}
size_t insertionStartIndex = 0;
if ( plotToInsertAfter ) insertionStartIndex = gridPlotWindow->plotIndex( plotToInsertAfter ) + 1;
for ( size_t tIdx = 0; tIdx < plotsToMove.size(); tIdx++ )
{
gridPlotWindow->insertPlot( plotsToMove[tIdx], insertionStartIndex + tIdx );
}
}