Leaflet.MagnifyingGlass icon indicating copy to clipboard operation
Leaflet.MagnifyingGlass copied to clipboard

Fix to viewport

Open shaunakv1 opened this issue 10 years ago • 1 comments

Hi @bbecquet .. first off Thanks for a Superb plugin!!

I was wondering if there is a way to fix the glass to some pixel coordinates in the viewport and not attach it to map with a lat long.

What I am looking for is a magnifying glass that is attached to same point in the viewport and when main map slides under it, it shows the zoomed in version of the map that is currently under it.

or it can be used to create glass that shows different layer of the map that is under it.

Thanks!

  • Shaunak

shaunakv1 avatar Jun 27 '14 20:06 shaunakv1

Hi! Thanks your question, and sorry for waiting so long to reply. You've probably found a way to do what you want by now… If not, is what you would like to do feasible with that plug-in instead: https://github.com/Norkart/Leaflet-MiniMap ?

The main difference between it and mine is that MiniMap is a Leaflet Control, which is meant to be part of the UI and fixed to the viewport as other controls. On the contrary, MagnifyingGlass inherits Layer, so it's meant to be part of the map itself, placed (and optionnaly moved) on it.

bbecquet avatar Jul 18 '14 09:07 bbecquet