<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<style type="text/css" style="display:none;"><!-- P {margin-top:0;margin-bottom:0;} --></style>
</head>
<body dir="ltr">
<div id="divtagdefaultwrapper" style="font-size:12pt;color:#000000;background-color:#FFFFFF;font-family:Calibri,Arial,Helvetica,sans-serif;">
<p>Hi all,</p>
<p><br>
</p>
<p>please read carefully:</p>
<p><br>
</p>
<p>Up to now the process_destination option is a bit problematic because <br>
</p>
<p>it may add the tag destination=* to an existing OSM element, and I think this</p>
<p>is not good, all tags added by mkgmap should have the mkgmap: prefix.<br>
</p>
<p><br>
</p>
<p>As Greg pointed out this causes problems for style authors who want to</p>
<p>create special hints depending on tags like destination:street .<br>
</p>
<p><br>
</p>
<p>The attached patch changes the method like this:</p>
<p>1) the tag destination is not changed by mkgmap</p>
<p>2) Instead the special tag mkgmap:dest_hint is now set to the <br>
</p>
<p>destination string that was found in one of the tags listed in this code snippet:<br>
</p>
<p>        tags.add("destination");<br>
        tags.add("destination:lanes");<br>
        tags.add("destination:lanes:forward");<br>
        tags.add("destination:lanes:backward");<br>
        tags.add("destination:forward");<br>
        tags.add("destination:backward");<br>
        tags.add("destination:street"); <br>
</p>
<p><br>
</p>
<p>(BTW: This is also the order of evaluation in mkgmap searches since r3673, of cause
<br>
</p>
<p>forward/backward are checked depending on the direction of the way)<br>
</p>
<p><br>
</p>
<p>For style authors this means that they have to <br>
</p>
<p>1) change all rules with mkgmap:dest_hint=true to mkgmap:dest_hint=*</p>
<p>2) change the rule that produces the hint to something like this:<br>
mkgmap:dest_hint=*<br>
  { set dest_hint = '${destination:ref|subst: =>} ${mkgmap:dest_hint|subst:;=> |subst:/=> }' |<br>
         '${ref|subst: =>} ${mkgmap:dest_hint|subst:;=> |subst:/=> }' | <br>
         '${mkgmap:dest_hint|subst:;=> |subst:/=> }';<br>
       } <br>
</p>
<p>Basically all places where "destination" was used were changed to mkgmap:dest_hint.</p>
<p><br>
</p>
<p>I am aware that this could cause trouble, so I've added a check that complains when</p>
<p>the style contains an expression mkgmap:dest_hint=true . <br>
</p>
<p><br>
</p>
<p>A binary can be found here:</p>
<p><a id="LPlnk775238" href="http://files.mkgmap.org.uk/download/295/mkgmap.jar">http://files.mkgmap.org.uk/download/295/mkgmap.jar</a></p>
<p><br>
</p>
<p>With the default style this produces the same img file as r3673. <br>
</p>
<p>Please let me know if you see problems with your style.<br>
</p>
<p><br>
</p>
<p>Gerd<br>
</p>
</div>
</body>
</html>