
Originally Posted by
ars
I have to override QwtLinearScaleEngine::autoScale() method.
Yes, nothing wrong about it.
Uwe
{
...
virtual void autoScale( int maxNumSteps,
double &x1, double &x2, double &stepSize ) const
{
if ( x1 == x2 )
{
x1 = ...;
x2 = ...;
stepSize = ...;
return;
}
}
};
class YourScaleEngine: public QwtLinearScaleEngine
{
...
virtual void autoScale( int maxNumSteps,
double &x1, double &x2, double &stepSize ) const
{
if ( x1 == x2 )
{
x1 = ...;
x2 = ...;
stepSize = ...;
return;
}
QwtLinearScaleEngine::autoScale( maxNumSteps, x1, x2, stepSize );
}
};
To copy to clipboard, switch view to plain text mode
Bookmarks