[OSM-talk] Legend add-in for osmarender

Steve Chilton S.L.Chilton at mdx.ac.uk
Sat Oct 21 19:57:11 BST 2006


I have been doodling with adding a legend to osmarendered maps and have produced a pretty messy add-in that seems to work for me. If anyone would like to try it, it is detailed at: http://wiki.openstreetmap.org/index.php/User:Steve8#Map_Legend
Created a data file with examples of main tags that I use (it is admittedly a pretty small subset), rendered it to svg, saved to png and then included in the border stuff in osmarender.
The messiest bit is the keydata file, which includes all the nudging of nodes I had to do to align things reasonably well (I needed the snap to grid feature that I am familiar with in graphics programmes). If anyone can see a way of reducing that file to its basics I would be grateful. Also any suggestions for moving to a dynamic legend tool rather than a pre-rendered static one would be useful. At moment the legend (which has on/off mode like all other peripheral elements) is valid until you change some details of your rendering scheme by editing the xml file. 
This is my first attempt to code anything - so "constructive" comments/criticisms are welcomed!
 
Cheers
STEVE




More information about the talk mailing list