Re: correct steps to display x axis labels on specific x axis points
Brought to you by:
rathmann
From: Uwe R. <Uwe...@ti...> - 2011-06-28 16:47:16
|
> You can find a commented example that shows the wrong behaviour I ran > into... thanks You are returning an invalid QwtScaleDiv object - what is the consequence of a lousy QwtScaleDiv interface. Your code needs to look like this: QwtScaleDiv ScaleEngine::divideScale (...) const { QwtValueList ticks[QwtScaleDiv::NTickTypes]; ticks[QwtScaleDiv::MajorTick] << 10 << 25 << 35 << 54 << 63 << 100; QwtScaleDiv scDiv( ticks[QwtScaleDiv::MajorTick].first(), ticks[QwtScaleDiv::MajorTick].last(), ticks ); return scDiv; } The important thing is not to use the default constructor for your QwtScaleDiv object. Uwe PS: I read the mailing list - no need to send a copy to me. |