Fix calculation of graduated symbology breaks

Fixes #7256