谷歌地图v3:Z-Index问题与多个KML图层 [英] Google Maps v3: Z-Index issue with Multiple KML Layers

查看:176
本文介绍了谷歌地图v3:Z-Index问题与多个KML图层的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一张Google地图(v3)地图,包含4个独立的叠加层,由4个独立的KML文件填充。其中三个KML文件只显示地图上的点,我以不同的颜色(例如红色,蓝色,黄色)制作Google。第三个覆盖图包含多个多边形坐标(即构建轮廓)。

问题是多边形(建筑物轮廓)位于其他3个覆盖物的标记之上。我希望其他三个叠加层(标记)位于多边形之上。感谢!

解决方案

首先将多边形的KmlLayer添加到地图中(您可能需要等待它渲染以确保它在底部)。有几个功能请求允许指定图层的相对Z-索引,但它尚未实施。

I've got a Google Maps (v3) map with 4 separate overlays, which are populated from 4 separate KML files. Three of the KML files only indicate points on the map which I render as different-colored (e.g. red, blue, yellow) Google makers. The third overlay contains multiple coordinates for polygons (i.e. building outlines).

The problem is that the polygons (building outlines) are on top of the markers in the other 3 overlays. I would like for the other three overlays (the markers) to be on top of the polygons. Thanks!

解决方案

Add the KmlLayer for the polygons to the map first (you may need to wait for it to be rendered to ensure it is on the bottom). There are several feature requests to allow specifying the relative z-index of layers, but it hasn't been implemented.

这篇关于谷歌地图v3:Z-Index问题与多个KML图层的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆