logo separator

[mkgmap-dev] Rounding off population

From Gerd Petermann gpetermann_muenchen at hotmail.com on Sun Jul 30 13:09:35 BST 2023

Hi Nick,

sorry for the late response.
I think this problem can and should be solved in the style. If you want to tolerate wrong values like this you can use a rule like
population=* {set population='${population|subst:,=>}'}
to remove the comma before before evaluating it further in other rules.

ciao,
Gerd

________________________________________
Von: mkgmap-dev <mkgmap-dev-bounces at lists.mkgmap.org.uk> im Auftrag von osm <osm at pinns.co.uk>
Gesendet: Donnerstag, 15. Juni 2023 08:13
An: mkgmap-dev at lists.mkgmap.org.uk
Betreff: [mkgmap-dev] Rounding off population

Hi

I  have a feeling mkgmap rounds off population when a comma has been
inserted thinking it is a 'continental decimal comma'

In my style I have

place=village & population < 30 {set place=hamlet;echotags "village to
hamlet"}

The following place node gets flagged up as it has been given a
population of 1

https://www.openstreetmap.org/node/271408#map=18/50.82664/-1.70104

When I look at the osm tags it contains:

population:1,350

Perhaps we should not round off population data?

Just a thought.

Nick

_______________________________________________
mkgmap-dev mailing list
mkgmap-dev at lists.mkgmap.org.uk
https://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev


More information about the mkgmap-dev mailing list