I would like to create Mapnik style using Python API and export it to XML-file. Creating style part is clear enough API has sufficient documentation. But I wasn't able to find function that does the import of created style to XML. Does it exist?
1 Answer
You can use mapnik.save_map()
import mapnik
m = mapnik.Map(1440,800)
# ... add styling and layers ...
mapnik.save_map(m, "output.xml")