Set size and anchor position for embedded markers

This commit is contained in:
Tom Hughes 2012-11-23 17:57:47 +00:00
parent 3d40181f87
commit dc0ada9515

View file

@ -28,7 +28,10 @@ window.onload = function () {
if (args.marker) {
L.marker(args.marker, {icon: L.icon({
iconUrl: <%= asset_path('images/marker-icon.png').to_json %>,
shadowUrl: <%= asset_path('images/marker-shadow.png').to_json %>
iconSize: new L.Point(25, 41),
iconAnchor: new L.Point(12, 41),
shadowUrl: <%= asset_path('images/marker-shadow.png').to_json %>,
shadowSize: new L.Point(41, 41)
})}).addTo(map);
}