Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我想在搜索根时更改谷歌地图上线条的颜色。我想让它像图片中的那样。我想将它从这个默认图片默认线路路由更改为红色线路,就像在这条线路的图片颜色中一样。我使用谷歌地图 JavaScript API V3。那可能吗??
查看答案如何在谷歌地图 v3 中更改路线的颜色
创建 directionDisplay 对象时
var directionsDisplay = new google.maps.DirectionsRenderer({ polylineOptions: { strokeColor: "red" } });