-
Notifications
You must be signed in to change notification settings - Fork 918
TileOverlay
###Add a TileOverlay A Tile Overlay is a set of images which are displayed on top of the base map tiles. These tiles are displayed like the base map tiles, but you can set the opacity of the tiles.
To add a tileOverlay, call addTileOverlay()
method.
The map.addTileOverlay() method takes a single overlay options object literal, specifying the initial properties of the tile overlay.
The following properties are available when constructing a TileOverlay:
Field Name | Type | Description |
---|---|---|
tileUrlFormat | String | The url of the tile images. You must include <x> ,<y> and <zoom> strings into the URL format. |
visible | Boolean | false if you want to hide the ground overlay. |
zIndex | Number | Specify the zIndex. (Default: 0) |
tileSize | Number | Specify the tile image size. (Default: 256) |
map.addTileOverlay({
// <x>,<y> and <zoom> are replaced with values
tileUrlFormat: "http://tile.stamen.com/watercolor/<zoom>/<x>/<y>.jpg"
}, function(tileOverlay) {
mTileOverlay = tileOverlay;
map.showDialog();
});
Method | Return value | Description |
---|---|---|
getVisible() | Boolean | Return true if the tile overlay is visible. |
setVisible(Boolean) | void | Set false if you want to hide. |
getFadeIn() | Boolean | Get whether the tiles should fade in. |
setFadeIn(Boolean) | void | Set whether the tiles should fade in. |
getZIndex() | Number | Return the zIndex of the tile overlay. |
setZIndex(Number) | void | Set the zIndex of the tile overlay. |
clearTileCache() | void | Remove the tile cache. |
remove() | void | Remove the tile overlay. |
If you get an error, feel free to ask me on the official community or the issue list.
New version 2.0-beta2 is available.
The cordova-googlemaps-plugin v2.0 has more faster, more features.
https://github.com/mapsplugin/cordova-plugin-googlemaps-doc/tree/master/v2.0.0/README.md
New versions will be announced through the official community. Stay tune!
Feel free to ask me on the issues tracker.
Or on the official community is also welcome!
New version 2.0-beta2 is available.
The cordova-googlemaps-plugin v2.0 has more faster, more features.
https://github.com/mapsplugin/cordova-plugin-googlemaps-doc/tree/master/v2.0.0/README.md