Google Static Maps Demo Available

Mark Wieder ahsoftware at sonic.net
Fri Jul 7 16:36:11 CEST 2017


On 07/06/2017 10:33 PM, William Prothero via use-livecode wrote:
> Mark:
> Yes, you’ve done it all.

Cool. It's working as expected then.

  It was intended just to demo the display of a Google Static Map and 
show how to get the corners of the image so the lat/lon of the mouse 
position could be calculated. To do that, I had to rely oh Hermann’s 
expertise with Javascript to convert a posted solution to LCS. I spent 
time carefully checking that the corners calculation agreed with the box 
plotted by the maps api. The map image is also slightly stretched 
horizontally (to fit my own project map size) and I had to do some 
tweaking to the corners code to make that work.
> 
> The links to the Google API get the programmer to the web site that tells how to display streets, display a map of a particular city or other feature, add symbols, etc. For those who need to do that, this should help. It’s pretty trivial to change the URL params, so I felt I could leave that to the user. Actually, the entire thing is pretty trivial, but it did take me quite a bit of time, thrashing through the details because I’d never worked with the Google maps api, so perhaps others might find it useful.
> 
> My project will continue and plot data on a captured image, scroll the map, etc. I hadn’t planned on including that part in the demo, but could, if requested.

The demo doesn't seem to be trivial at all, especially looking at the 
libraries involved - you've put a lot of work into that.

-- 
  Mark Wieder
  ahsoftware at gmail.com



More information about the use-livecode mailing list