Standard Esri Map Control

Set Marker Colors using ColorBrewer

Technologies / User Interface Add-Ins / Geographic Information System (GIS) Views / Map with Thematic Markers

In this example we use ColorBrewer to generate marker colors.

To use ColorBrewer, include it in the view:

<js file="colorbrewer.js"/>

Call colorbrewer2rgb() to set the marker symbol colors passing the name of the desired color brewer scale with the number of colors needed:

markerProperty.symbolColors = this.mapControl.colorbrewer2rgb(colorbrewer.Paired2[12]);

The Colorbrewer scales are pictured here:

colorbrewer.png

A link to this chart with scale names: http://bl.ocks.org/mbostock/5577023

See: ColorBrewer : Color Advice for Maps

Sample view: http://localhost:8080/archibus/schema/ab-products/solutions/arcgis/standard/markers/ab-arcgis-map-thematic-unique-value-renderer.axvw