[mapserver-commits] r10837 - trunk/mapserver

svn at osgeo.org svn at osgeo.org
Thu Jan 6 10:28:40 EST 2011


Author: aboudreault
Date: 2011-01-06 07:28:40 -0800 (Thu, 06 Jan 2011)
New Revision: 10837

Modified:
   trunk/mapserver/HISTORY.TXT
   trunk/mapserver/mapprimitive.c
Log:
Fixed Auto Angle - incorrectly placed Labels (#3648)

Modified: trunk/mapserver/HISTORY.TXT
===================================================================
--- trunk/mapserver/HISTORY.TXT	2011-01-04 17:37:45 UTC (rev 10836)
+++ trunk/mapserver/HISTORY.TXT	2011-01-06 15:28:40 UTC (rev 10837)
@@ -14,6 +14,8 @@
 Current Version (SVN trunk):
 ----------------------------
 
+- Fixed Auto Angle - incorrectly placed Labels (#3648)
+
 - Fixed Improper validation of symbol index values (#3641)
 
 - Removed BACKGROUNDCOLOR, BACKGROUNDSHADOWCOLOR and BACKGROUNDSHADOWOFFSET label parameters (#3609)

Modified: trunk/mapserver/mapprimitive.c
===================================================================
--- trunk/mapserver/mapprimitive.c	2011-01-04 17:37:45 UTC (rev 10836)
+++ trunk/mapserver/mapprimitive.c	2011-01-06 15:28:40 UTC (rev 10837)
@@ -1686,7 +1686,8 @@
         *(*lengths)[index] = total_length;
 
       /* if there is only 1 label to place... put it in the middle of the current segment (as old behavior) */
-      if (anglemode != MS_NONE && (point_repeat == 1))
+      if ( ((anglemode == MS_AUTO) || (anglemode == MS_AUTO2)) &&  
+           (point_repeat == 1) ) 
       {
         j = segment_index;
         (*labelpoints)[index]->x = (p->line[i].point[j].x + p->line[i].point[j-1].x)/2.0;



More information about the mapserver-commits mailing list