<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 Greg, <br>
</p>
<p><br>
</p>
<p>"why is "Beck Road" being set for variable $[destination] ??"<br>
</p>
<p>I've answered this question multiple times now, seems my english is too bad, so</p>
<p>I try again.</p>
<p><br>
</p>
<p>The option --process-destination in mkgmap triggers a function that</p>
<p>is execute when the OSM data is read and before your style rules are executed.</p>
<p>This function checks a list of tags ike destination, destination:forward, destination:lanes</p>
<p>and destination:street . When any of those is found mkgmap adds the tag mkgmap:dest_hint=true</p>
<p>and if the tag destination is not already set it is set with the value that was found in the
<br>
</p>
<p>alternatives. <br>
</p>
<p>I guess this happens because nobody tried to create detailed hints like you do.</p>
<p>If I'd start to code this now I would simplify the code so that it</p>
<p>sets mkgmap:dest_hint to the value that was found. So, instead of checking</p>
<p>mkgmap:dest_hint=true one would use mkgmap:dest_hint=*</p>
<p><br>
</p>
<p>If I change that now all style authors have to change the corresponding rules,</p>
<p>so I'd like to get positive feedback for this idea before I change the code.<br>
</p>
<p><br>
</p>
<p>Gerd<br>
</p>
<p><br>
</p>
<p><br>
</p>
<p><br>
</p>
<p><br>
</p>
<p><br>
</p>
<p><br>
</p>
<br>
<br>
<div style="color: rgb(0, 0, 0);">
<hr tabindex="-1" style="display:inline-block; width:98%">
<div id="divRplyFwdMsg" dir="ltr"><font style="font-size:11pt" face="Calibri, sans-serif" color="#000000"><b>Von:</b> mkgmap-dev <mkgmap-dev-bounces@lists.mkgmap.org.uk> im Auftrag von greg crago <gregcrago@gmail.com><br>
<b>Gesendet:</b> Montag, 21. März 2016 00:12<br>
<b>An:</b> Development list for mkgmap<br>
<b>Betreff:</b> Re: [mkgmap-dev] Exit_hint and Dest_hint result is not what I was expecting</font>
<div> </div>
</div>
<div>
<div dir="ltr">Now we are getting somewhere:
<div><br>
</div>
<div>I ran this code:</div>
<div><br>
</div>
<div>
<div># build destination hint </div>
<div>dest_hint=* { delete dest_hint }</div>
<div>highway=* & mkgmap:dest_hint=true { echo 'BEFORE destination=${destination}';</div>
<div><span class="" style="white-space:pre"></span>set destination:ref = '${destination:ref|subst:South=> S|subst:North=> N|subst:East=> E|subst:West=> W|subst:I =>I-|subst:M =>M-|subst:US =>US-}'; </div>
<div><span class="" style="white-space:pre"></span>set destination = '${destination|subst:/=>,}';</div>
<div><span class="" style="white-space:pre"></span>set destination:street = '${destination:street|subst:;=>,|subst: Road=> Rd|subst: Street=> St|subst: Avenue=> Ave|subst: Mile=> Mi|subst: Boulevard=> Blvd|subst: Parkway=> Pkwy|subst: Highway=> Hwy|subst: Southwest=>
SW|subst: Northwest=> NW|subst: Southeast=> SE|subst: Northeast=> NE}';</div>
<div><span class="" style="white-space:pre"></span>echo 'AFTER destination=${destination}';</div>
<div><span class="" style="white-space:pre"></span>}</div>
</div>
<div><br>
</div>
<div>And got this response from mkgmap:</div>
<div><br>
</div>
<div>
<div>Time started: Sun Mar 20 19:09:49 EDT 2016</div>
<div>Found one style in \MKGMAP\openmapchest-style\openmapchest</div>
<div>finished check-styles</div>
<div>4611686018427387907 (8729200): BEFORE destination=Beck Road</div>
<div>4611686018427387907 (8729200): AFTER destination=Beck Road</div>
<div>4611686018427387909 (8729934): BEFORE destination=Beck Road</div>
<div>4611686018427387909 (8729934): AFTER destination=Beck Road</div>
<div>Number of MapFailedExceptions: 0</div>
<div>Number of ExitExceptions: 0</div>
<div>Time finished: Sun Mar 20 19:09:51 EDT 2016</div>
<div>Total time taken: 1497ms</div>
</div>
<div><br>
</div>
<div>If you look at the OSM data, there IS NO DESTINATION tag, so why is "Beck Road" being set for variable $[destination] ??</div>
<div><br>
</div>
<div>Greg</div>
</div>
<div class="gmail_extra"><br>
<div class="gmail_quote">On Sat, Mar 19, 2016 at 5:42 PM, Andrzej Popowski <span dir="ltr">
<<a title="Ctrl+Klicken oder tippen Sie, um dem Link zu folgen." href="mailto:popej@poczta.onet.pl" target="_blank">popej@poczta.onet.pl</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex; border-left:1px #ccc solid; padding-left:1ex">
Hi,<span class=""><br>
<br>
> No, echotags expects a string constant as parm, and it prints all<br>
> tags of an object<br>
<br>
</span>It is not that bad, I think it works like string in "set" command. This should work:<br>
... {echotags 'testing destination=${destination}'}<br>
<br>
but it is kind of redundant, maybe better looking would be:<br>
<br>
... {echo 'testing destination=${destination}'}<span class="HOEnZb"><font color="#888888"><br>
<br>
-- <br>
Best regards,<br>
Andrzej</font></span>
<div class="HOEnZb">
<div class="h5"><br>
<br>
_______________________________________________<br>
mkgmap-dev mailing list<br>
<a href="mailto:mkgmap-dev@lists.mkgmap.org.uk" target="_blank">mkgmap-dev@lists.mkgmap.org.uk</a><br>
<a href="http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev" rel="noreferrer" target="_blank">http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev</a><br>
</div>
</div>
</blockquote>
</div>
<br>
</div>
</div>
</div>
</div>
</body>
</html>