<!DOCTYPE html><html><head><title></title><style type="text/css">#fastmail-quoted p.fastmail-quoted-MsoNormal,#fastmail-quoted li.fastmail-quoted-MsoNormal,#fastmail-quoted div.fastmail-quoted-MsoNormal{margin-top:0cm;margin-right:0cm;margin-left:0cm;margin-bottom:0.0001pt;font-size:11pt;font-family:"Calibri", sans-serif;}
#fastmail-quoted a:link,#fastmail-quoted span.fastmail-quoted-MsoHyperlink{color:rgb(5, 99, 193);text-decoration-line:underline;text-decoration-style:solid;text-decoration-color:currentcolor;}
#fastmail-quoted a:visited,#fastmail-quoted span.fastmail-quoted-MsoHyperlinkFollowed{color:rgb(149, 79, 114);text-decoration-line:underline;text-decoration-style:solid;text-decoration-color:currentcolor;}
#fastmail-quoted p.fastmail-quoted-msonormal0,#fastmail-quoted li.fastmail-quoted-msonormal0,#fastmail-quoted div.fastmail-quoted-msonormal0{margin-right:0cm;margin-left:0cm;font-size:11pt;font-family:"Calibri", sans-serif;}
#fastmail-quoted p.fastmail-quoted-msipfooter5f75dde,#fastmail-quoted li.fastmail-quoted-msipfooter5f75dde,#fastmail-quoted div.fastmail-quoted-msipfooter5f75dde{margin-right:0cm;margin-left:0cm;font-size:11pt;font-family:"Calibri", sans-serif;}
#fastmail-quoted span.fastmail-quoted-EmailStyle19{font-family:"Calibri", sans-serif;color:windowtext;}
#fastmail-quoted span.fastmail-quoted-EmailStyle20{font-family:"Calibri", sans-serif;color:windowtext;}
#fastmail-quoted span.fastmail-quoted-EmailStyle21{font-family:"Calibri", sans-serif;color:windowtext;}
#fastmail-quoted .fastmail-quoted-MsoChpDefault{font-size:10pt;}
#fastmail-quoted div.fastmail-quoted-WordSection1{}
p.MsoNormal,p.MsoNoSpacing{margin:0}</style></head><body><div>Hi Julian,<br></div><div><br></div><div>I have seen something similar when writing tests for mappyfil. I've tried to find my test case in <a href="https://github.com/geographika/mappyfile/tree/master/tests">https://github.com/geographika/mappyfile/tree/master/tests</a> but can't seem to locate it at the moment. I'm fairly sure I had some notes somewhere and it related to parsing MapServer expressions. I'll take another look later. <br></div><div>Did you try to dump the Mapfile out using MapScript to see how it is stored internally in MapServer after it has been loaded?<br></div><div><br></div><div>Seth<br></div><div><br></div><div id="sig62266145"><div class="signature">--<br></div><div class="signature">web:http://geographika.co.uk<br></div><div class="signature">twitter: @geographika<br></div></div><div><br></div><div><br></div><div>On Wed, Mar 20, 2019, at 4:49 PM, Julian Hollingbery wrote:<br></div><blockquote type="cite" id="fastmail-quoted"><div class="fastmail-quoted-WordSection1"><p class="fastmail-quoted-MsoNormal"><span lang="EN-US">Hi list,</span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US"> </span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US">I have observed an obscure behavior in MapServer version 7.0.7, which I’d like to run by you before I submit an issue.</span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US"> </span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US">I have an issue where labels on contour line disappear when I write a particular type of comment after the TEXT directive.</span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US"> </span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US">Using this request:</span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US"><a href="http://host/fcgi-bin/mapserv.fcgi?map=ms_issue_report.map&SERVICE=WMS&VERSION=1.3.0&REQUEST=GetMap&BBOX=542400.00,6216800.00,542600.0,6217000.0&CRS=EPSG:25832&WIDTH=400&HEIGHT=400&LAYERS=dhm_kote_0_5_m,dhm_kurve_0_5_m&STYLES=&FORMAT=image/png&TRANSPARENT=FALSE">http://host/fcgi-bin/mapserv.fcgi?map=ms_issue_report.map&SERVICE=WMS&VERSION=1.3.0&REQUEST=GetMap&BBOX=542400.00,6216800.00,542600.0,6217000.0&CRS=EPSG:25832&WIDTH=400&HEIGHT=400&LAYERS=dhm_kote_0_5_m,dhm_kurve_0_5_m&STYLES=&FORMAT=image/png&TRANSPARENT=FALSE</a></span><br></p><p class="fastmail-quoted-MsoNormal">this piece of MAP file<br></p><p class="fastmail-quoted-MsoNormal"> <br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US"> CLASS</span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US"> GROUP "default"</span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US"> NAME "dhm2015 kurver, 0,5 m"</span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US"> </span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US"> TEXT (tostring([hoejde],"%.2f")) #altid to decimal, også .00 (eng. always two decimals, including .00)</span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US"> STYLE</span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US"> OPACITY 80</span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US"> COLOR 100 50 0</span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US"> WIDTH 1</span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US"> END #STYLE</span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US"> LABEL</span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US"> FONT "arial"</span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US"> SIZE 9</span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US"> COLOR 137 90 68</span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US"> OFFSET 0 -6</span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US"> SHADOWSIZE 1 1</span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US"> TYPE TRUETYPE</span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US"> REPEATDISTANCE 300</span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US"> ANGLE auto</span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US"> PARTIALS FALSE</span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US"> END # LABEL</span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US"> END #CLASS</span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US"> </span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US">Gives me <a href="https://pasteboard.co/I6jsBen.png"> https://pasteboard.co/I6jsBen.png</a> (contour lines w/o labels), whereas</span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US"> </span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US"> CLASS</span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US"> GROUP "default"</span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US"> NAME "dhm2015 kurver, 0,5 m"</span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US"> #altid to decimal, også .00 (eng. always two decimals, including .00)</span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US"> TEXT (tostring([hoejde],"%.2f"))</span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US"> STYLE</span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US"> OPACITY 80</span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US"> COLOR 100 50 0</span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US"> WIDTH 1</span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US"> END #STYLE</span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US"> LABEL</span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US"> FONT "arial"</span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US"> SIZE 9</span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US"> COLOR 137 90 68</span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US"> OFFSET 0 -6</span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US"> SHADOWSIZE 1 1</span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US"> TYPE TRUETYPE</span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US"> REPEATDISTANCE 300</span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US"> ANGLE auto</span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US"> PARTIALS FALSE</span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US"> END # LABEL</span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US"> END #CLASS</span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US"> </span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US">Results in https://pasteboard.co/I6js9YK.png (which is the desired result: Contour lines labelled with two decimal points).</span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US">I have narrowed it down a bit, and if I delete the “(eng. ..)”, i.e. just have</span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US"> TEXT (tostring([hoejde],"%.2f")) #altid to decimal, også .00</span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US">It still works nicely.</span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US"> </span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US">So I guess the parentheses are somehow parsed as something meaningful (related to the “tostring”-expression, perhaps?), invalidating the TEXT declaration.</span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US"> </span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US">Has anyone seen something similar?</span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US"> </span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US">Best Regards</span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US">/julian</span><br></p><p class="fastmail-quoted-MsoNormal"><span lang="EN-US"> </span><br></p></div><div>_______________________________________________<br></div><div>mapserver-users mailing list<br></div><div>mapserver-users@lists.osgeo.org<br></div><div>https://lists.osgeo.org/mailman/listinfo/mapserver-users<br></div></blockquote><div><br></div></body></html>