Hi, I want the width of the Graticule control to be same as that of the 
baselayer. But it is extending beyond baselayer boundaries on both the sides, 
right and left. (Screenshot attached) 'targetSize' is not working. 
Is Graticule's width always the same as the map container division's width? But 
reducing the map container division's width clipped the Graticule, it didn't 
reduce the size. Please help, Thanks in advance
Ameet

Here is my code:

var map = new OpenLayers.Map('map',     {
        maxExtent: [-180, -90, 180, 90],
        resolutions: [0.3515625, 0.17578125, 0.087890625, 
0.0439453125,0.02197265625, 
                      0.010986328125],
        controls: [
            new OpenLayers.Control.Navigation(),
            new OpenLayers.Control.PanZoomBar(),
            new OpenLayers.Control.Graticule({
                numPoints: 1, 
                //targetSize: 550,
                labelled: true
            })
        ]
});
        
var baseLayer = new OpenLayers.Layer.WMS(
        "Global Imagery",
        geoserverUrl + "wms",
        {layers: "world_land"},
        {
            maxExtent: [-180, -90, 180, 90]
        }
);

map.addLayer(baseLayer);
map.zoomToMaxExtent();

HTML code:

    
                        
_______________________________________________
Users mailing list
[email protected]
http://lists.osgeo.org/mailman/listinfo/openlayers-users

Reply via email to