Closed kaneplusplus closed 8 years ago
Wheel zoom was working for me (OSX/Safari). Box zoom is difficult with Google Maps because the GMaps API insists on preserving aspect ratio. We will have to find a way to improve this in BokehJS at some point soon.
OK, thanks for the information. Do you want me to close this issue or should it be kept around as a "todo".
@kaneplusplus , if you just do gmap()
, is there still a zoom problem? That will just give you a blank map. I may have chosen an example with too much data.
@hafen Yes, the problem is still there. Wheel zoom works on Chrome not Firefox. Box zoom works on neither.
> sessionInfo()
R version 3.1.2 (2014-10-31)
Platform: x86_64-apple-darwin14.0.0 (64-bit)
locale:
[1] en_US.UTF-8/en_US.UTF-8/en_US.UTF-8/C/en_US.UTF-8/en_US.UTF-8
attached base packages:
[1] stats graphics grDevices utils datasets methods base
other attached packages:
[1] rbokeh_0.2
loaded via a namespace (and not attached):
[1] digest_0.6.8 evaluate_0.5.5 formatR_1.0 grid_3.1.2
[5] hexbin_1.27.0 htmltools_0.2.6 htmlwidgets_0.3.2 knitr_1.9
[9] lattice_0.20-29 magrittr_1.5 maps_2.3-9 RJSONIO_1.3-0
[13] stringr_0.6.2 tools_3.1.2 yaml_2.1.13
Interesting. You can leave this open because I need make it so box zoom cannot be a possible tool to use with gmap. I'm not sure about the wheel zoom.
There are a few potential avenues for a box zoom with gmap plots, they have just not been implemented. The first and simplest thing is to add an aspect-preserving mode to the box tool and require it for gmap plots. Next is to use the other gmap API function to reposition the map according to the box center (instead of the current center of the plot, like wheel zoom does). I had some issues getting this to work, but I am sure it was just a case of operator error.
I've restricted gmap plot to only allow tools with which it plays nicely, so I will mark this as closed.
The map at http://hafen.github.io/taxi/gmap.html doesn't allow me to box zoom or wheel zoom. Is this by design?