mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
Multiaxis: add support for Qwt multiaxis plot
This commit is contained in:
committed by
Kristian Bendiksen
parent
22d6e3f853
commit
dde0487024
@@ -70,13 +70,11 @@ RiuMohrsCirclePlot::RiuMohrsCirclePlot( QWidget* parent )
|
||||
{
|
||||
RiuQwtPlotTools::setCommonPlotBehaviour( this );
|
||||
|
||||
enableAxis( QwtPlot::xBottom, true );
|
||||
enableAxis( QwtPlot::yLeft, true );
|
||||
enableAxis( QwtPlot::xTop, false );
|
||||
enableAxis( QwtPlot::yRight, false );
|
||||
setAxesCount( QwtAxis::XBottom, 1 );
|
||||
setAxesCount( QwtAxis::YLeft, 1 );
|
||||
|
||||
setAxisTitle( QwtPlot::xBottom, "Effective Normal Stress" );
|
||||
setAxisTitle( QwtPlot::yLeft, "Shear Stress" );
|
||||
setAxisTitle( QwtAxis::XBottom, "Effective Normal Stress" );
|
||||
setAxisTitle( QwtAxis::YLeft, "Shear Stress" );
|
||||
|
||||
applyFontSizes( false );
|
||||
|
||||
@@ -459,7 +457,7 @@ void RiuMohrsCirclePlot::updateTransparentCurvesOnPrincipals()
|
||||
qVectorPoints.push_back( QPointF( mohrCircleInfo.principals[2], 0 ) );
|
||||
|
||||
transparentCurve->setSamples( qVectorPoints );
|
||||
transparentCurve->setYAxis( QwtPlot::yLeft );
|
||||
transparentCurve->setYAxis( QwtAxis::YLeft );
|
||||
transparentCurve->setStyle( QwtPlotCurve::NoCurve );
|
||||
transparentCurve->setLegendAttribute( QwtPlotCurve::LegendNoAttribute );
|
||||
|
||||
@@ -715,8 +713,8 @@ void RiuMohrsCirclePlot::setAxesScaleAndReplot()
|
||||
yMaxDisplayed = heightToKeepAspectRatio;
|
||||
}
|
||||
|
||||
this->setAxisScale( QwtPlot::yLeft, 0, yMaxDisplayed );
|
||||
this->setAxisScale( QwtPlot::xBottom, xMin, xMaxDisplayed );
|
||||
this->setAxisScale( QwtAxis::YLeft, 0, yMaxDisplayed );
|
||||
this->setAxisScale( QwtAxis::XBottom, xMin, xMaxDisplayed );
|
||||
|
||||
this->replot();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user