handlersOptions {leaflet.extras} | R Documentation |
Options for editing handlers
Description
Customize tooltips for addDrawToolbar
Usage
handlersOptions(
polyline = list(error = "<strong>Error:</strong> shape edges cannot cross!",
tooltipStart = "Click to start drawing line.", tooltipCont =
"Click to start drawing line.", tooltipEnd = "Click to start drawing line."),
polygon = list(tooltipStart = "Click to start drawing shape.", tooltipCont =
"Click to start drawing shape.", tooltipEnd = "Click to start drawing shape."),
rectangle = list(tooltipStart = "Click and drag to draw rectangle."),
circle = list(tooltipStart = "Click map to place circle marker.", radius = "Radius"),
marker = list(tooltipStart = "Click map to place marker."),
circlemarker = list(tooltipStart = "Click and drag to draw circle.")
)
Arguments
polyline |
List of options for polyline tooltips. |
polygon |
List of options for polygon tooltips. |
rectangle |
List of options for rectangle tooltips. |
circle |
List of options for circle tooltips. |
marker |
List of options for marker tooltips. |
circlemarker |
List of options for circlemarker tooltips. |
Examples
## Not run:
library(leaflet)
library(leaflet.extras)
leaflet() %>%
addTiles() %>%
addDrawToolbar(
handlers = handlersOptions(
polyline = list(
tooltipStart = "Click It",
tooltipCont = "Keep going",
tooltipEnd = "Make it stop"
),
),
polylineOptions = T, rectangleOptions = F, circleOptions = F,
polygonOptions = F, markerOptions = F, circleMarkerOptions = F
)
## End(Not run)
[Package leaflet.extras version 2.0.0 Index]