Tuesday, 4 December 2018

javascript - get and change style property openlayers


i need to change the property of some style after its created, and i need to change it with knowing only the string of the property name. i am getting string like "fillColor" and value like "blue", and i need to change the style object. how can i do it? i didnt find anything in the api. the style code:


            var selectStyle = new OpenLayers.Style({
externalGraphic: 'styles/tree_selected.png',
graphicWidth: 16, graphicHeight: 26, graphicYOffset: -24,
title: 'tree'
});


No comments:

Post a Comment

arcpy - Changing output name when exporting data driven pages to JPG?

Is there a way to save the output JPG, changing the output file name to the page name, instead of page number? I mean changing the script fo...