Right now, the code for my symbol in the Map.xml config file looks like this:
<esri:GraphicsLayer.Renderer>
<esri:UniqueValueRenderer Field="SUBTYPECD" Attribute="SUBTYPECD" DefaultLabel="Default Symbol">
<esri:UniqueValueRenderer.DefaultSymbol>
<esriFSSymbols:PictureMarkerSymbol>
<esriMapping:SymbolExtensions.Json>{"type":"esriPMS","color":null,"width":21,"height":21,"angle":0,"xoffset":0,"yoffset":0}</esriMapping:SymbolExtensions.Json>
</esriFSSymbols:PictureMarkerSymbol>
</esri:UniqueValueRenderer.DefaultSymbol>
<esri:UniqueValueRenderer.Infos>
<esriMapping:UniqueValueInfoObj FieldType="Integer" Label="Overhead Fuse" SerializedValue="1">
<esri:UniqueValueInfo.Symbol>
<esriMapping:ImageFillSymbol Size="44" OriginX="0.5" OriginY="0.5" Source="/Images/MarkerSymbols/Electric/OverheadFuse.png"/>
</esri:UniqueValueInfo.Symbol>
</esriMapping:UniqueValueInfoObj>
</esri:UniqueValueRenderer.Infos>
</esri:UniqueValueRenderer>
</esri:GraphicsLayer.Renderer>
With this code, there is no symbol rotation (based on the value in the field SYMBOLROTATION) but I can manipulate the symbol size in the application builder, and the symbol image shows up in the legend.
I can get the symbol to rotate if I use this code:
<esri:UniqueValueRenderer.Infos>
<esriMapping:UniqueValueInfoObj FieldType="Integer" Label="Overhead Fuse" SerializedValue="1">
<esri:UniqueValueInfo.Symbol>
<esriMapping:ImageFillSymbol Size="44" OriginX="0.5" OriginY="0.5" Source="/Images/MarkerSymbols/Electric/OverheadFuse.png">
<esriMapping:ImageFillSymbol.ControlTemplate>
<ControlTemplate>
<Image RenderTransformOrigin="0.5,0.5">
<Image.RenderTransform>
<RotateTransform Angle="{Binding Path=Attributes.[SYMBOLROTATION]}"/>
</Image.RenderTransform>
</Image>
</ControlTemplate>
</esriMapping:ImageFillSymbol.ControlTemplate>
</esriMapping:ImageFillSymbol>
</esri:UniqueValueInfo.Symbol>
</esriMapping:UniqueValueInfoObj>
</esri:UniqueValueRenderer.Infos>
This rotates the symbol correctly, but I lose any control of the symbol in the application builder. I don't mind too much having to change the symbol size using the xaml, but the symbol no longer shows up in the legend. I understand why, but is there any way to tweak this so I get the best of both worlds?
Thanks!