-
Notifications
You must be signed in to change notification settings - Fork 97
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Added OverviewMap plugin #117
base: master
Are you sure you want to change the base?
Conversation
Sorry, I forgot to add OverviewMap.js to the loader.js |
Hello Thanks AC |
I think you can add it to the controls section of the map config of a Viewer, but you'll need to repeat the controls that are added by default and you need to make sure MousePosition is in your build (use a @requires): https://github.com/boundlessgeo/gxp/blob/master/src/script/widgets/Viewer.js#L507:L515 |
Thanks a lot De: Bart van den Eijnden [email protected] I think you can add it to the controls section of the map config of a Viewer, but you'll need to repeat the controls that are added by default and you need to make sure MousePosition is in your build (use a @requireshttps://github.com/requires): https://github.com/boundlessgeo/gxp/blob/master/src/script/widgets/Viewer.js#L507:L515 You are receiving this because you commented. |
Thanks It works perfect perfectly. Now, it shows EPSG: 4265 and 3857 only. How can I change the showed CRS to EPSG:32619? Thanks in advance AC De: Bart van den Eijnden [email protected] I think you can add it to the controls section of the map config of a Viewer, but you'll need to repeat the controls that are added by default and you need to make sure MousePosition is in your build (use a @requireshttps://github.com/requires): https://github.com/boundlessgeo/gxp/blob/master/src/script/widgets/Viewer.js#L507:L515 You are receiving this because you commented. |
Check |
Hello... Unfortunately ol.control.MousePosition doesn't work as expected . I added proj4js dependency in app.js and in the HTML header. Also, I add my EPSG definition in proj4/lib/def I added some lines in app.js as stated at (http://dev.openlayers.org/releases/OpenLayers-2.13.1/doc/apidocs/files/OpenLayers/Control/MousePosition-js.html) controls: [ However, it still shows EPSG:32619 coordinates. I would be very grateful if you could help me solve this issue. AC De: Bart van den Eijnden [email protected] Check displayProjection for ol.control.MousePosition (http://dev.openlayers.org/releases/OpenLayers-2.13.1/doc/apidocs/files/OpenLayers/Control/MousePosition-js.html) you might need to add that projection using proj4js if you have not already done that. OpenLayers.Control.MousePosition - OpenLayers 2http://dev.openlayers.org/releases/OpenLayers-2.13.1/doc/apidocs/files/OpenLayers/Control/MousePosition-js.html You are receiving this because you commented. |
Sorry I,ve made a mistake it still shows EPSG:900913 coordinates, not EPSG:32619 AC De: Abraham Coiman [email protected] Hello... Unfortunately ol.control.MousePosition doesn't work as expected . I added proj4js dependency in app.js and in the HTML header. Also, I add my EPSG definition in proj4/lib/def I added some lines in app.js as stated at (http://dev.openlayers.org/releases/OpenLayers-2.13.1/doc/apidocs/files/OpenLayers/Control/MousePosition-js.html) controls: [ However, it still shows EPSG:32619 coordinates. I would be very grateful if you could help me solve this issue. AC De: Bart van den Eijnden [email protected] Check displayProjection for ol.control.MousePosition (http://dev.openlayers.org/releases/OpenLayers-2.13.1/doc/apidocs/files/OpenLayers/Control/MousePosition-js.html) you might need to add that projection using proj4js if you have not already done that. OpenLayers.Control.MousePosition - OpenLayers 2http://dev.openlayers.org/releases/OpenLayers-2.13.1/doc/apidocs/files/OpenLayers/Control/MousePosition-js.html You are receiving this because you commented. |
Sorry I,ve made a mistake it still shows EPSG:900913 coordinates, not EPSG:32619 AC De: Bart van den Eijnden [email protected] Check displayProjection for ol.control.MousePosition (http://dev.openlayers.org/releases/OpenLayers-2.13.1/doc/apidocs/files/OpenLayers/Control/MousePosition-js.html) you might need to add that projection using proj4js if you have not already done that. OpenLayers.Control.MousePosition - OpenLayers 2http://dev.openlayers.org/releases/OpenLayers-2.13.1/doc/apidocs/files/OpenLayers/Control/MousePosition-js.html You are receiving this because you commented. |
It works perfectly. I had to put the projs4 library in src/gxp/script/ folder. |
I've added a plugin to add the OpenLayers OverviewMap Control to the Viewer. It can be configured to load an already loaded layer to the map or a layer from a LayerSource.
I've added two examples, one adding an OSM OverviewMap and another adding a WMS layer.