From battisti at actgate.com Thu Oct 3 06:28:54 2013 From: battisti at actgate.com (Andrea Battisti) Date: Thu, 03 Oct 2013 15:28:54 +0200 Subject: [OpenLayers-Dev] OL 2.13.1 + latest Proj4js (?) Message-ID: <524D7116.7090903@actgate.com> Hello, Looks like that the latest version of Proj4js from: https://github.com/proj4js/proj4js has a slightly different API then before, and indeed it does not seem to work with the plain OL 2.13.1. Question: is there a patch available to use OL against the new Proj4js? If not, which is the best way to make it compatible? As far as I see the code to adapt will be the OpenLayers.Projection class in Projection.js; is that enough? are there other changes needed from the OL perspective? Thanks in advance! -- Ing. Andrea Battisti From ahocevar at boundlessgeo.com Thu Oct 3 12:11:18 2013 From: ahocevar at boundlessgeo.com (Andreas Hocevar) Date: Thu, 3 Oct 2013 13:11:18 -0600 Subject: [OpenLayers-Dev] OL 2.13.1 + latest Proj4js (?) In-Reply-To: <524D7116.7090903@actgate.com> References: <524D7116.7090903@actgate.com> Message-ID: Hey, You'll have to add the following wrapper before you load projections from spatialreference.org and before you load OpenLayers.js: This is all. Andreas. On Thu, Oct 3, 2013 at 7:28 AM, Andrea Battisti wrote: > Hello, > > Looks like that the latest version of Proj4js from: > https://github.com/proj4js/**proj4js > > has a slightly different API then before, and indeed it does not seem to > work with the plain OL 2.13.1. > > Question: is there a patch available to use OL against the new Proj4js? > If not, which is the best way to make it compatible? > > As far as I see the code to adapt will be the OpenLayers.Projection class > in Projection.js; is that enough? are there other changes needed from the > OL perspective? > > > Thanks in advance! > -- > Ing. Andrea Battisti > ______________________________**_________________ > Dev mailing list > Dev at lists.osgeo.org > http://lists.osgeo.org/**mailman/listinfo/openlayers-**dev > -------------- next part -------------- An HTML attachment was scrubbed... URL: From battisti at actgate.com Fri Oct 4 06:33:24 2013 From: battisti at actgate.com (Andrea Battisti) Date: Fri, 04 Oct 2013 15:33:24 +0200 Subject: [OpenLayers-Dev] OL 2.13.1 + latest Proj4js (?) In-Reply-To: References: <524D7116.7090903@actgate.com> Message-ID: <524EC3A4.7020401@actgate.com> Il 03/10/13 21.11, Andreas Hocevar ha scritto: > Hey, > > You'll have to add the following wrapper before you load projections > from spatialreference.org and before you > load OpenLayers.js: > > > > This is all. > > Andreas, thanks for the quick reply, the above wrapper helps! Just for the record for who might be interested, I noticed that the internal projection object (as returned by: OpenLayers.Map.getProjectionObject().proj) has changed as well, so any code that was accessing its properties should be adapted. -- Ing. Andrea Battisti