Definition of a CompositeSymbol in xaml

07-11-2017 06:48 AM
Occasional Contributor

I tried to define a CompositeSymbol as a resource in .xaml, like:

<esri:CompositeSymbol x:Key="CompositeSymbol">
        <esri:SimpleMarkerSymbol Size="6" Color="Black"/>
        <esri:SimpleMarkerSymbol Size="6" Color="Red"/>

This does not compile.

I think, this is because Symbols returns the generic IList<T> interface only. I think, I read somewhere that XAML can handle collections only, if they implement the non-generic version as well.

Actually, I tested it with an own dummy CompositeSymbol class. If I define Symbols as IList or List<T>, I can define it in xaml. If I define it as IList<T>, it does not work.

Maybe, the CompositeSymbol can be enhanced to support IList as well.

0 Kudos
0 Replies