logo separator

[mkgmap-dev] Preprocessor for style files

From toc-rox easyclasspage at googlemail.com on Wed Jan 4 14:53:24 GMT 2012

My style file are becoming more and more complex.
IMHO a (simple) preprocessor would be very helpful.

Important features (analogue C preprocessor):
- ##include (includes a text file)
- ##define (defines a preprocessor var; also as command line option)
- ##ifdef (checks if a preprocessor var is defined)
-   ##else (else for ##ifdef)
- ##endif (end of ##ifdef)

A simple example (for polygons):

##define BASECAMP
...
##include "indexrules.txt"
...
##ifdef BASECAMP
  # draw buildings
  building = * [0x13 resolution 20]
##endif
...

Questions:
- What do think of this proposal ? 
- Does anyone already uses an external preprocessor for the style files ?

Regards Klaus


--
View this message in context: http://gis.638310.n2.nabble.com/Preprocessor-for-style-files-tp7150709p7150709.html
Sent from the Mkgmap Development mailing list archive at Nabble.com.



More information about the mkgmap-dev mailing list