10

我正在尝试设计一个谷歌地图以匹配我得到的设计,在设计上,所有国家的外围都有一个笔划,以及划分边界的一个笔划。

我要达到的效果如下: 在此处输入图像描述

我的样式代码目前如下:

var styles =   [
        {
          featureType: "water",
          stylers: [
            { visibility: "on" },
            { color: "#ffffff" }
          ]
        },{
          featureType: "landscape",
          stylers: [
            { color: "#f7f7f5" }
          ]
        },{
          featureType: "road",
          stylers: [
            { visibility: "off" }
          ]
        },{
          featureType: "poi",
          stylers: [
            { visibility: "off" }
          ]
        },{
          featureType: "administrative.country",
          stylers: [
            { color: "#d2cdcd" },
            { weight: 1 }
          ]
        },{
          featureType: "administrative.country",
          elementType: "labels",
          stylers: [
            { visibility: "off" }
          ]
        },{
          featureType: "administrative.province",
          elementType: "geometry",
          stylers: [
            { visibility: "off" }
          ]
        },{
          featureType: "administrative.locality",
          elementType: "labels",
          stylers: [
            { visibility: "off" }
          ]
        },{
          featureType: "administrative.province",
          elementType: "labels",
          stylers: [
            { visibility: "off" }
          ]
        },{
          featureType: "water",
          elementType: "geometry.stroke",
          stylers: [
            { color: "#4cfff5" }
          ]
        }
      ];

知道我所追求的是否可能吗?

谢谢!

编辑:上述风格给了我以下

在此处输入图像描述

4

1 回答 1

2

您目前只能定义水的填充,但不能定义轮廓。

于 2014-07-29T16:00:30.243 回答