Fix typo in functional
Switch all floats to qreal, remove all conversion warnings