Add style for Geomettry Collection

This commit is contained in:
Antoine Abt
2014-02-04 11:34:47 +01:00
parent 1c4926b591
commit ad1cec84a1

View File

@@ -171,10 +171,24 @@ var overlayStyle = (function() {
fill: new ol.style.Fill({ fill: new ol.style.Fill({
color: [255, 255, 255, 0.5] color: [255, 255, 255, 0.5]
}) })
}),
new ol.style.Style({
stroke: new ol.style.Stroke({
color: [255, 255, 255, 1],
width: 5
})
}),
new ol.style.Style({
stroke: new ol.style.Stroke({
color: [0, 153, 255, 1],
width: 3
})
}) })
]; ];
styles[ol.geom.GeometryType.MULTI_POLYGON] = styles[ol.geom.GeometryType.MULTI_POLYGON] =
styles[ol.geom.GeometryType.POLYGON]; styles[ol.geom.GeometryType.POLYGON];
styles[ol.geom.GeometryType.GEOMETRY_COLLECTION] =
styles[ol.geom.GeometryType.POLYGON];
styles[ol.geom.GeometryType.LINE_STRING] = [ styles[ol.geom.GeometryType.LINE_STRING] = [
new ol.style.Style({ new ol.style.Style({