ESRI.ArcGIS.Client.Toolkit.DataSources.Kml.PolygonSymbolDescriptor.CreateSymbol C# (CSharp) Method

CreateSymbol() public method

Method to create proper symbology for each feature type.
public CreateSymbol ( ) : Symbol
return Symbol
        public override Symbol CreateSymbol()
        {
            Symbol sym = new SimpleFillSymbol();
            if (style != null)
            {
                if (style.PolyFill)
                {
                    // Create brush using color information, this can only be done on the UI thread
                    sym.SetValue(SimpleFillSymbol.FillProperty, new System.Windows.Media.SolidColorBrush(style.PolyFillColor));
                }
                if (style.PolyOutline)
                {
                    if (style.LineColor != null)
                    {
                        // Create brush using color information, this can only be done on the UI thread
                        sym.SetValue(SimpleFillSymbol.BorderBrushProperty, new System.Windows.Media.SolidColorBrush(style.LineColor));
                    }
                    if (style.LineWidth != 0.0)
                    {
                        sym.SetValue(SimpleFillSymbol.BorderThicknessProperty, style.LineWidth);
                    }
                }
            }

            return sym;
        }
PolygonSymbolDescriptor