[OpenLayers-Trac] [OpenLayers] #2852: Bug in OpenLayers.Util.getFormattedLonLat

OpenLayers trac-20090302 at openlayers.org
Mon Sep 27 12:19:30 EDT 2010


#2852: Bug in OpenLayers.Util.getFormattedLonLat
----------------------+-----------------------------------------------------
 Reporter:  mattnott  |       Owner:              
     Type:  bug       |      Status:  new         
 Priority:  major     |   Milestone:  2.11 Release
Component:  general   |     Version:  2.10        
 Keywords:            |       State:              
----------------------+-----------------------------------------------------
 The problem I have come across is when I use a graticule with labelformat
 set to 'dms'. The issue is that very often I get labels such as '2 3 60E'
 - i.e. 60 seconds! Which looks pretty poor. The problem is that the code
 in getFormattedLonLat does a 'round' on seconds which means that it can
 actually come out at 60. You then need some code to check that if it is 60
 then set it to zero and increment the number of minutes by one (and then
 obviously check that minutes is now not greater than 59 (etc))

-- 
Ticket URL: <http://trac.openlayers.org/ticket/2852>
OpenLayers <http://openlayers.org/>
A free AJAX map viewer


More information about the Trac mailing list