return;
if (prs->isSecondY()) {
- myPlot->enableAxis(QwtPlot::yRight, true);
- mySecondY = true;
+ setEnableAxis( QwtPlot::yRight, true );
+ //myPlot->enableAxis(QwtPlot::yRight, true);
+ //mySecondY = true;
}
else {
- myPlot->enableAxis(QwtPlot::yRight, false);
- mySecondY = false;
+ setEnableAxis( QwtPlot::yRight, false );
+ //myPlot->enableAxis(QwtPlot::yRight, false);
+ //mySecondY = false;
}
// display all curves from presentation
return allPositive;
}
+/**
+ *
+ */
+void Plot2d_ViewFrame::setEnableAxis( const QwtPlot::Axis& theAxis, const bool& isEnable )
+{
+ if ( myPlot->axisEnabled( theAxis ) == isEnable )
+ return;
+ myPlot->enableAxis( theAxis, isEnable );
+ if ( theAxis == QwtPlot::yRight )
+ mySecondY = isEnable;
+}
+
class Plot2d_QwtPlotZoomer : public QwtPlotZoomer
{
public:
// non-positive X/Y coordinate
bool isXLogEnabled() const;
bool isYLogEnabled() const;
+ void setEnableAxis( const QwtPlot::Axis&, const bool& );
virtual bool print( const QString& file, const QString& format ) const;
void printPlot( QPainter* p, const QRect& rect,