fixed platform specific problems with qreal