setPaintProperty method
- String layerId,
- String name,
- dynamic value, [
- StyleSetterOptions? options,
Sets the value of a paint property in the specified style layer.
@param {string} layerId The ID of the layer to set the paint property in.
@param {string} name The name of the paint property to set.
@param {*} value The value of the paint property to set.
Must be of a type appropriate for the property, as defined in the Mapbox Style Specification.
@param {Object} options
@param {boolean} options.validate=true
Whether to check if value
conforms to the Mapbox GL Style Specification. Disabling validation is a performance optimization that should only be used if you have previously validated the values you will be passing to this function.
@returns {MapboxMap} this
@example
map.setPaintProperty('my-layer', 'fill-color', '#faafee');
@see Change a layer's color with buttons
@see Adjust a layer's opacity
@see Create a draggable point
Implementation
setPaintProperty(String layerId, String name, dynamic value,
[StyleSetterOptions? options]) =>
jsObject.setPaintProperty(layerId, name, jsify(value));