mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
Merge pull request #8387 from OPM/qtcharts-summary-plots
Closes #8228 Major refactoring of summary plotting. Now possible to create plots both with Qwt and QtChart as plotting tool.
This commit is contained in:
committed by
GitHub
parent
d9bb82de91
commit
258fbddc10
@@ -42,6 +42,8 @@
|
||||
#include "cafPdmUiPushButtonEditor.h"
|
||||
#include "cafPdmUiToolButtonEditor.h"
|
||||
|
||||
#include "qwt_plot.h"
|
||||
|
||||
CAF_PDM_ABSTRACT_SOURCE_INIT( RimAbstractCorrelationPlot, "AbstractCorrelationPlot" );
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
@@ -557,7 +559,7 @@ QString RimAbstractCorrelationPlot::description() const
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
RiuQwtPlotWidget* RimAbstractCorrelationPlot::doCreatePlotViewWidget( QWidget* mainWindowParent /*= nullptr */ )
|
||||
RiuPlotWidget* RimAbstractCorrelationPlot::doCreatePlotViewWidget( QWidget* mainWindowParent /*= nullptr */ )
|
||||
{
|
||||
if ( !m_plotWidget )
|
||||
{
|
||||
@@ -576,12 +578,20 @@ RiuQwtPlotWidget* RimAbstractCorrelationPlot::viewer()
|
||||
return m_plotWidget;
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
RiuPlotWidget* RimAbstractCorrelationPlot::plotWidget()
|
||||
{
|
||||
return m_plotWidget;
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RimAbstractCorrelationPlot::detachAllCurves()
|
||||
{
|
||||
if ( m_plotWidget ) m_plotWidget->detachItems();
|
||||
if ( m_plotWidget ) m_plotWidget->qwtPlot()->detachItems();
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
@@ -661,7 +671,7 @@ void RimAbstractCorrelationPlot::updateLegend()
|
||||
{
|
||||
if ( m_plotWidget )
|
||||
{
|
||||
m_plotWidget->insertLegend( nullptr );
|
||||
m_plotWidget->qwtPlot()->insertLegend( nullptr );
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user