I am using the GraphicTracker to display icons and labels. Using the IMask interface I can add a text mask background so the text is easier to read. Using the "ESRI.ArcGIS.Display.esriMaskStyle.esriMSHalo" type works great. The halo completely covers the background of the text. When I enable dynamic display (for performance) it causes each character in the text label to be surrounded by its own halo and separated by some small amount of space. This looks terrible and takes up quite a bit more space to display. I have tried many things without success. The attached image shows what the labels look like with dynamic display off and on.
Is there any way to get the display to be the same with Dynamic Display turned on?
Here is the code to create the textsymbol:
Public Function CreateTextMask() As ESRI.ArcGIS.Display.ITextSymbol
Dim SimpleFill As ESRI.ArcGIS.Display.ISimpleFillSymbol = New ESRI.ArcGIS.Display.SimpleFillSymbol
Dim Mask As ESRI.ArcGIS.Display.IMask
Dim Text As ESRI.ArcGIS.Display.ISimpleTextSymbol = New ESRI.ArcGIS.Display.TextSymbol
Dim TextColor As ESRI.ArcGIS.Display.IRgbColor = New ESRI.ArcGIS.Display.RgbColor
Dim MaskColor As ESRI.ArcGIS.Display.IRgbColor = New ESRI.ArcGIS.Display.RgbColor
Dim Font As stdole.IFontDisp
Font = New stdole.StdFont
With Font
Font.Name = "Arial"
Font.Bold = True
Font.Size = 10
End With
With TextColor
.Red = 0
.Green = 0
.Blue = 0
End With
With MaskColor
.Red = 100
.Green = 200
.Blue = 0
End With
Mask = Text
SimpleFill.Color = MaskColor
SimpleFill.Style = ESRI.ArcGIS.Display.esriSimpleFillStyle.esriSFSSolid
SimpleFill.Outline = Nothing
Mask.MaskSymbol = SimpleFill
Mask.MaskSize = 3
Mask.MaskStyle = ESRI.ArcGIS.Display.esriMaskStyle.esriMSHalo
Text.Font = Font
Text.Color = TextColor
Text = Mask
Return Text
End Function