-
Notifications
You must be signed in to change notification settings - Fork 827
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Label of float8 data shows to many digits #430
Comments
[springmeyer] hardcoded right here: http://trac.mapnik.org/browser/trunk/include/mapnik/value.hpp#L553 |
[springmeyer] this (http://173.255.217.246:8000/mapnik_trac/attachment/ticket/430/control_precision.patch) patch implements flexibility needed to control the precision when converting doubles to unicode text. If this is a decent approach we could then expose as a text_symbolizer param: (should also likely consider exposing fixed vs scientific formatting, and apply same fix to to_string())
|
Fixes precision digits, closing mapnik#430 Also avoids forcing a trailing '.0', closing mapnik#1627
Fixes precision digits, closing mapnik#430 Also avoids forcing a trailing '.0', closing mapnik#1627
The pull requests #1631 (for 2.1 branch) and #1632 (for master) fix the precision used by to_string(), effectively fixing the issue reported in the title of this ticket. Maybe there should be another ticket for "Controlling floating point formatting in label symbolizers" and this one should be closed as fixed ? |
@strk - thanks, will check it out asap! |
The testcase is ready to host more conversion tests but is currently really only targetting the double-to-string. refs mapnik#430, mapnik#1632
Fixes precision digits, closing mapnik#430 Also avoids forcing a trailing '.0', closing mapnik#1627
The testcase is ready to host more conversion tests but is currently really only targetting the double-to-string. refs mapnik#430, mapnik#1632
In quantumnik, I use a postgis layer and set its label to a float8 attribute. QGIS shows one of the labels as "24.6", but when quantumnik is turned on this label displays "24.60000000000001".
The text was updated successfully, but these errors were encountered: