ArcObjects Library Reference (Carto)  

ISymbolSubstitution Interface

Provides access to members that control dynamic symbol substitution for display.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Members

Description
Read/write property InlineColor The color used for substituting symbols that do not reference the symbol collection.
Read/write property MassColor The color used for substituting only the color.
Read/write property SubstituteSymbolCollection The substitute symbol collection when substituting the entire collection.
Read/write property SubstituteType The type of symbol substitution.

CoClasses that implement ISymbolSubstitution

CoClasses and Classes Description
FDOGraphicsLayer A collection of properties for an annotation layer (feature data object graphics layer).

Remarks

ISymbolSubstitution provides access to the properties which control the display of annotation using Symbol Substitution.  Unlike FeatureLayers, Annotation Layers (FDOGraphicsLayers) use symbology stored in the geodatabase for drawing.  Typically, the data needs to be edited in order to change the appearance of an annotation. To help with this issue, Symbol Substitution allows for the alteration of text symbology used when displaying annotation layers (FDOGraphicsLayers ).  Symbol Substitution properties are layer based and persisted with the layer, therefore no editing of the data is needed. 

There are four types of Symbol Substitution:
esriSymbolSubstituteNone - Do not substitute symbols (the default).
esriSymbolSubstituteColor - Substitute only the color.
esriSymbolSubstituteIndividualSubordinate - Substitute individual symbols in the collection with overrides taking precedence to symbols.
esriSymbolSubstituteIndividualDominant - Substitute individual symbols in the collection with the symbol taking precedence to overrides.
 
The type of Symbol Substitution used can be set using ISymbolSubstitution::SubstituteType.  Substitution type esriSymbolSubstituteColor uses the color set as the MassColor property to draw all text in the layer with that color.  Substitution types esriSymbolSubstituteIndividualSubordinate and esriSymbolSubstituteIndividualDominant use a SymbolCollection set in the SubstituteSymbolCollection property to draw annotation features that references a symbol in the symbol collection with a different base symbol.  Text that does not reference a symbol in the symbol collection can optionally be drawn with a color when an color is set using the InlineColor property.
 
The difference between Symbol Substitution types esriSymbolSubstituteIndividualSubordinate and esriSymbolSubstituteIndividualDominant is in how the substitution is performed when the annotation feature contains TextSymbol overrides.  When substitution type esriSymbolSubstituteIndividualSubordinate is chosen, the text is drawn with the symbol from the substitute symbol collection and the overrides are applied to this symbol.  When substitution type esriSymbolSubstituteIndividualDominant is chosen, the text is drawn just with the symbol from the substitute SymbolCollection and the overrides are ignored.
 
To properly create a substitute SymbolCollection, the collection must contain symbols at the same index as the symbol that you wish to substitute.  For instance, if an annotation feature class has a SymbolCollection with 3 symbols indexed from 1 to 3.  To substitute only symbol number 2, a new SymbolCollection should be cocreated, the substitute TextSymbol should be stored at position 2 in the SymbolCollection, and the collection should be set as the SubstituteSymbolCollection for the annotation layer.
 
For more on the concept of text symbol overrides, consult the documentation for Interface ISymbolCollectionElement which contains a more thorough explanation of the concept.