Support JOSM style templates. Fixes #1023