google maps - SVG path ignores anchor point -
the anchor: of icon ignored although think "moves" absolute , not relative. no matter values supply anchor: in code, svg markers unchanged. more specific, pins beingness positioned downward , right of should be. because using bezier curves, or what?
function createmarker(point,text,id,color,label,pinage) { var stroke = "000000" var icon = { path: "m16,3.5c-4.142,0-7.5,3.358-7.5,7.5c0,4.143,7.5,18.121,7.5,18.121s23.5,15.143,23.5,11c23.5,6.858,20.143,3.5,16,3.5z m16,14.584c-1.979,0-3.584-1.604-3.584-3.584s14.021,7.416,16,7.416s19.584,9.021,19.584,11s17.979,14.584,16,14.584z", fillcolor: color, fillopacity: .8, anchor: google.maps.point(0.0, 0.0), strokeweight: 1, scale:1.4 }; var marker = new google.maps.marker({ position: point, map: map , title: text, icon: icon, zindex: id}); }
you've ommitted new-keyword, has be:
google-maps svg
No comments:
Post a Comment