Solved! Go to Solution.
Yes you can add halo around the text.
//
//-------------------------------------------------
// --- Create halo symbology mask for text ---
//-------------------------------------------------
//
// --- Set the Halo color - White
//
HaloColor.Red = 255;
HaloColor.Green = 255;
HaloColor.Blue = 255;
//
// --- Create Halo Font Symbol
//
HaloFontSymbol.Font =
ESRI.ArcGIS.ADF.COMSupport.OLE.GetIFontDispFromFont(HaloDrawFont) as stdole.IFontDisp;
//
HaloFontSymbol.Font.Size = 24;
HaloFontSymbol.Font.Bold = true;
HaloFontSymbol.Angle = 0.0;
HaloFontSymbol.Color = HaloColor;
//
// --- Set the Simple Fill color
//
SimpleFill.Color = HaloColor;
SimpleFill.Style =
ESRI.ArcGIS.Display.esriSimpleFillStyle.esriSFSSolid;
SimpleFill.Outline = null;
//
// --- Setup a mask
//
pMask = (IMask)HaloFontSymbol;
pMask.MaskSymbol = SimpleFill;
pMask.MaskSize = 2;
pMask.MaskStyle = esriMaskStyle.esriMSHalo;
//
// --- Create and add halo text to graphic container
//
//
// --- Add text element and set properties
//
HaloTextElement.Text = gPolygonText;
HaloTextElement.Symbol = HaloFontSymbol;
//
// --- Create element, set property & add to graphic container
//
HaloElement = HaloTextElement as IElement;
TextPoint.Y -= .5;
HaloElement.Geometry = TextPoint;
//
// --- Add graphic text element to graphic
container
//
if (cbDrawResults.Checked)
{
SearchGraphicsContainer.AddElement(HaloElement, 0);
}
Yes you can add halo around the text.
//
//-------------------------------------------------
// --- Create halo symbology mask for text ---
//-------------------------------------------------
//
// --- Set the Halo color - White
//
HaloColor.Red = 255;
HaloColor.Green = 255;
HaloColor.Blue = 255;
//
// --- Create Halo Font Symbol
//
HaloFontSymbol.Font =
ESRI.ArcGIS.ADF.COMSupport.OLE.GetIFontDispFromFont(HaloDrawFont) as stdole.IFontDisp;
//
HaloFontSymbol.Font.Size = 24;
HaloFontSymbol.Font.Bold = true;
HaloFontSymbol.Angle = 0.0;
HaloFontSymbol.Color = HaloColor;
//
// --- Set the Simple Fill color
//
SimpleFill.Color = HaloColor;
SimpleFill.Style =
ESRI.ArcGIS.Display.esriSimpleFillStyle.esriSFSSolid;
SimpleFill.Outline = null;
//
// --- Setup a mask
//
pMask = (IMask)HaloFontSymbol;
pMask.MaskSymbol = SimpleFill;
pMask.MaskSize = 2;
pMask.MaskStyle = esriMaskStyle.esriMSHalo;
//
// --- Create and add halo text to graphic container
//
//
// --- Add text element and set properties
//
HaloTextElement.Text = gPolygonText;
HaloTextElement.Symbol = HaloFontSymbol;
//
// --- Create element, set property & add to graphic container
//
HaloElement = HaloTextElement as IElement;
TextPoint.Y -= .5;
HaloElement.Geometry = TextPoint;
//
// --- Add graphic text element to graphic
container
//
if (cbDrawResults.Checked)
{
SearchGraphicsContainer.AddElement(HaloElement, 0);
}