maps

Popup on hovering over cluster group

浪尽此生 提交于 2019-12-13 00:55:18
问题 I want to add popup on cluster group made using Leaflet.markercluster just like the popups that come on hovering over the leaflet markers. 回答1: I was able to find the answer with the help of issues present in the github page of leaflet.markercluster cluster.on('clustermouseover', function(c) { var popup = L.popup() .setLatLng(c.layer.getLatLng()) .setContent(c.layer._childCount +' Locations(click to Zoom)') .openOn(map); }).on('clustermouseout',function(c){ map.closePopup(); }).on(

Google Maps Bounds inaccurate

て烟熏妆下的殇ゞ 提交于 2019-12-13 00:25:27
问题 my problem is related to the way how LatLngBounds.extend() method works. I am not sure if this is a bug or not but it does not work as intended. I expect bounds to contain all points included in it. Unfortunately it works really strangely in my case. Please check this fiddle: http://jsfiddle.net/Sy5dC/4/. var locationBBOX = [ '(42.00, -142.00) (70.00, -50.00)', //CANADA '(47.274719, 5.864166000000068) (55.053055, 15.038886999999932)',//GERMANY //'(40.00, 27.00) (70.00, 179.00)'//RUSSIA ]; In

How to display and connect multiple locations with a route with annotations in an MKMapView inside an iPhone App?

一世执手 提交于 2019-12-12 20:58:42
问题 I need to display a MKMapView with more than 4 locations with different Annotations and a route connecting the locations. I have tried to display the multiple locations inside a MKMapView but i still not able to find out on how to connect the locations with a route. I am also trying to get this checked if i have implemented it in a right way. I have created a "CLLocationCoordinate2D" and then added a lat and long similarly for 4 points. I have created a custom object which implements

Open Layers 3 center the map based on extent on vector layer?

China☆狼群 提交于 2019-12-12 19:17:05
问题 I want to position the center and zoom level of my map depending on the vector layer features (points). I have a geojson file which is populating my map: var vectorSource = new ol.source.Vector({ url: 'assets/js/data.geojson', format: new ol.format.GeoJSON(), projection: 'ESPG:3857' }); I now try to get the extent of the vector layer: vectorSource.once('change', function (e) { if (vectorSource.getState() === 'ready') { if (vectorLayer.getSource().getFeatures().length > 0) { map.getView().fit

Google Maps API color stylers not working

旧城冷巷雨未停 提交于 2019-12-12 18:06:36
问题 I'm trying to learn how to use the API, and I'm following the code that's on their site completely but for some reason it just doesn't want to change colour. The code I'm posting is just copy and pasted from their website but I cannot get it to work, can any one please tell me what I'm doing wrong? <!doctype html> <html lang="en"> <head> <meta charset="UTF-8"> <title>maps</title> <style> html, body { height: 100%; margin: 0; width: 100%; } #map{ height: 100%; margin: 0; width: 100%;

Different results when setting/getting System properties with GStrings in Groovy

自闭症网瘾萝莉.ら 提交于 2019-12-12 17:45:25
问题 I'm perplexed by Groovy's behavior here. I've run through the debugger some to try to determine where in the dynamic mixins these code paths may be getting crossed but wondered if anyone could set me straight here. Basically, in setting a system property with a GString for a value, depending on how I set the property, the property is not always readable back via certain methods. I have seen Why Map does not work for GString in Groovy? and Why groovy does not see some values in dictionary? but

Is it possible to cache iOS maps for use when the phone is offline?

拟墨画扇 提交于 2019-12-12 17:37:37
问题 Is it possible to request that an iOS app stores map images of a location so that they are available when the user is not connected to the internet? i.e. if a user is in London, is it possible to force the app to source map images for Barcelona and keep them cached, so that once the user arrives in the location (without internet connectivity) the maps are already cached? Thanks 回答1: Unfortunately apple doesn't allow anybody to do that.The MapKit.framework is strictly for displaying them.

Using an array of Strings to create a 2D (map) array in Java

。_饼干妹妹 提交于 2019-12-12 15:24:14
问题 How would it be possible to create a 2D array of characters in Java? I've researching this as applicable to my goal of a map you can move a character around on, though have not found anything helpful. I have done this (with a little help) in C++ before, though don't know how to in Java. For the C++ version, I started with a 1D array of strings: "#######.#.~~~####.##.......~~~..##.~~....H....######..#######", "#####..T.#~~~..##.H......~~~...#..T.~~.........######.###....", "######..~~~~#######

How do I add a simple image overlay in Mapbox Javascript?

可紊 提交于 2019-12-12 13:18:19
问题 The following link in the Mapbox Javascript API describes how to add an image overlay on a map, and it is very simple : https://www.mapbox.com/mapbox-gl-js/example/image-on-a-map/ This works! However, I am trying to add an image overlay on a custom map. I am wanting to do this without creating tiles or anything of the like. I can't find a way to overlay an image on a satellite map (that's my goal, just a weather radar GIF on a satellite map), but I can't seem to get this to work on any other

How would I plot borehole traces in 3d?

旧城冷巷雨未停 提交于 2019-12-12 13:10:18
问题 Borehole data contains the "collar" information: that's X,Y, and Z (Z is ground elevation, and Z=0 is some datum like mean sea level), and also borehole length in Z direction. How can I create a 3D plot of the borehole traces (curves)? I'm looking for solutions in R but also interested in python (though haven't tagged it as such in case it just confuses). The result might be similar to this image from ArcScene: . Here, the borehole traces are coloured by another parameter from one or more