Skip to content
This repository has been archived by the owner on Jul 24, 2021. It is now read-only.

add OpenLayers.LonLat in order to display the courrent position on OSM slippy map #3857

Closed
openstreetmap-trac opened this issue Jul 23, 2021 · 1 comment

Comments

@openstreetmap-trac
Copy link

Reporter: Hendrik75
[Submitted to the original trac issue database at 6.40pm, Wednesday, 22nd June 2011]

Several times I was asked about how to know where the slippy map on www.openstreetmap.org is centered. A map without any indication of where it is located seems not well accepted.

It is actually possible to check the permalink, but it is not user friendly.

I suggest to add something like

map.setCenter(new OpenLayers.LonLat(18500000,-2450000),8);

to the openlayers code in order to display the lat.lon of the mouse cursor.

@openstreetmap-trac
Copy link
Author

Author: TomH
[Added to the original trac issue at 8.18am, Thursday, 23rd June 2011]

I have no idea why you think that line of code would make OL display the position of the mouse cursor. What it would actually do is to centre the map on a fixed location.

Ignoring that, there is a control in OL to display the mouse position, but it's horribly ugly and anyway wanting to know the lat/lon of your mouse seems like it would be very much a minority requirement - for most people that information is close to meaningless.

I see no point is making our user interface uglier and more confusing to benefit the small number of people that might find this useful.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

1 participant