new LabelPlaces(options)
Parameters:
Name | Type | Description |
---|---|---|
options |
lucid.maps.places.LabelPlacesOptions | Configuration for the labelling of places. |
- Source:
- maps/places/LabelPlaces.js, line 13
Methods
-
addPlaces()
-
Add places to the map.The Google PlacesService will be called to find the places to show. The locationsreturned are then marked on the map with a Marker and a LIMB.You can remove the labels with a call to 'removePlaces'.
- Source:
- maps/places/LabelPlaces.js, line 67
-
getNumberOfPlaces() → {number}
-
- Source:
- maps/places/LabelPlaces.js, line 212
Returns:
The total number of places being labelled (includes any labels currently being hidden).- Type
- number
-
hide()
-
Temporarily hide all places.This does not remove the LIMBs and markers, it just takes them off display.Call this if you hide the map element.
- Source:
- maps/places/LabelPlaces.js, line 196
-
removePlaces()
-
Remove places from the map.
- Source:
- maps/places/LabelPlaces.js, line 176
-
setPlaceTypes(types)
-
Set the type(s) of place this instance searches for.
Parameters:
Name Type Description types
string[] A list of Google places types. - Source:
- maps/places/LabelPlaces.js, line 40
-
show()
-
Re-display the places after being hidden with a call to 'hide'.
- Source:
- maps/places/LabelPlaces.js, line 204
Events
-
post_add_labels
-
Raised after labels have been added to the map.
Type:
- object
- Source:
- maps/places/LabelPlaces.js, line 223
-
post_remove_labels
-
Raised after labels have been removed from the map.
Type:
- object
- Source:
- maps/places/LabelPlaces.js, line 227
-
pre_add_labels
-
Raised before new places are labelled on the map.
Type:
- object
- Source:
- maps/places/LabelPlaces.js, line 221
-
pre_remove_labels
-
Raised before removing place labels from the map.
Type:
- object
- Source:
- maps/places/LabelPlaces.js, line 225