#5374 Snapshot : Snapshot to clipboard does not work for some plots

This commit is contained in:
Magne Sjaastad 2020-01-24 07:30:30 +01:00
parent 8bbfe9e7af
commit e8d832343e
2 changed files with 13 additions and 2 deletions

View File

@ -740,6 +740,14 @@ int RiuQwtPlotWidget::overlayMargins() const
return m_overlayMargins; return m_overlayMargins;
} }
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
RimViewWindow* RiuQwtPlotWidget::ownerViewWindow() const
{
return m_plotDefinition;
}
//-------------------------------------------------------------------------------------------------- //--------------------------------------------------------------------------------------------------
/// ///
//-------------------------------------------------------------------------------------------------- //--------------------------------------------------------------------------------------------------

View File

@ -19,10 +19,11 @@
#pragma once #pragma once
#include "cafUiStyleSheet.h" #include "RiuInterfaceToViewWindow.h"
#include "cafPdmObject.h" #include "cafPdmObject.h"
#include "cafPdmPointer.h" #include "cafPdmPointer.h"
#include "cafUiStyleSheet.h"
#include "qwt_plot.h" #include "qwt_plot.h"
@ -52,7 +53,7 @@ class QWheelEvent;
// //
// //
//================================================================================================== //==================================================================================================
class RiuQwtPlotWidget : public QwtPlot class RiuQwtPlotWidget : public QwtPlot, public RiuInterfaceToViewWindow
{ {
Q_OBJECT Q_OBJECT
@ -118,6 +119,8 @@ public:
void renderTo( QPaintDevice* painter, const QRect& targetRect ); void renderTo( QPaintDevice* painter, const QRect& targetRect );
int overlayMargins() const; int overlayMargins() const;
RimViewWindow* ownerViewWindow() const override;
signals: signals:
void plotSelected( bool toggleSelection ); void plotSelected( bool toggleSelection );
void axisSelected( int axisId, bool toggleSelection ); void axisSelected( int axisId, bool toggleSelection );