[Gambas-user] Question

Tobias Boege taboege at ...626...
Wed Sep 30 13:06:19 CEST 2015


On Wed, 30 Sep 2015, adamnt42 at ...626... wrote:
> On Tue, 29 Sep 2015 21:18:40 +0200 Tobias Boege <taboege at ...626...> wrote:
> > On Tue, 29 Sep 2015, Jussi Lahtinen wrote:
> > > How does the mapviewer work..? I get only empty view, and quickly I don't
> > > see way to define the map.
> > > 
> > 
> > I believe we have a gb.map example using MapView here[0], German though.
> > Scroll all the way down the page to find the download section.
> > 
> > Regards,
> > Tobi
> > 
> > [0] http://www.gambas-buch.de/dw/doku.php?id=k24:k24.8:k24.8.1:start
> > 
> 
> Tobi, 
> That was great, I have been struggling with the MapView for 3 days.  A couple of questions though.
> 1) Is there an example using the GoogleMaps provider?

Thanks, this is Hans' work (IIRC with Fabien's help), I haven't used gb.map
yet. However, grepping through the gb.map sources, there is a file
Tests/FMain.class which seems to use French GoogleMaps.

> 2) If the provided lat/long numbers are invalid, a "Mathematical Error" occurs, but I cant seem to trap this in the client program. Both Try and Catch methods don't work.  I get a stack backtrace of:
> Geo.MapPointToTile.19
> _MapTile.Load.166
> Map.tmrLoad_Timer.172
> in the IDE which then stops.

This seems to be a bug in gb.map. The Geo class is certainly in gb.map and
does some math (involving a logarithm) in line 19.

> 3) Have you considered an interface to the Nokia "Here" map provider? It seems faster than the GoogleMaps web and has a couple of nice features.  e.g. https://www.here.com/?map=52.79089,11.7536,15,satellite
> 

I think as long as the URL format is known, this can be done in an instant,
but I can't get it to work here... Also I need to head to lunch :-)

Regards,
Tobi

-- 
"There's an old saying: Don't change anything... ever!" -- Mr. Monk




More information about the User mailing list