geosdi / GWT-OpenLayers

GWT Wrapper for OpenLayers
47 stars 20 forks source link

Display none to Line Feature, become black stroke line #47

Open malvinpatrick opened 3 years ago

malvinpatrick commented 3 years ago

Hello, I was trying hide my line on openlayer VectorFeature vector = routeLayer.getFeatureById(vDay.getId().toString()); vector.setStyle(new Style("{display: none}"));

But why I got this "black" line ?? I have to refresh the layer. image

TDesjardins commented 3 years ago

@malvinpatrick What do you want to achieve? Actually the Style class hasn't such constructor and the style hasn't such properties (see http://dev.openlayers.org/releases/OpenLayers-2.13.1/doc/apidocs/files/OpenLayers/Style-js.html).