When we apply smart mapping style - Counts and Amounts (By Size) to a point layer (without any classes defined), we are not able to interrogate the size of the graphic symbol. We were expecting the layer's renderer info to have this information. However, the closest thing we could find are only the parameters used by the style i.e., minDatavalue, maxDatavalue, minSize and maxSize in renderer -> visualVariables. The actual size that is used to display the graphic is not listed in the rendererInfo anywhere.
We need to identify the size of a graphic symbol in order to show a cyan colored square selection symbol that is slightly larger than the graphic's symbol, the way it is displayed in ArcGIS Map Viewer.
The cyan colored square selection graphic is added to separate graphic layer on top of the feature layer.
- We cannot use the popup to do this as we need to display the popup contents in a custom way in a side panel.
- We also cannot directly get the graphic's size from the graphic available in feature layer (using getnode) because the graphic is not guaranteed to be always present in featurelayer as its loaded in On-Demand mode.
Is there another way to find out the feature's graphic symbol size? or maybe calculate the size based on parameters defined in rendererInfo?
Here is a sample webmap that uses this style.