ESRI.ArcGIS.ADF.IMS
TrueTypeMarkerSymbol Class
Members  Example  See Also 
ESRI.ArcGIS.ADF.IMS.Display.Symbol Namespace : TrueTypeMarkerSymbol Class




A MarkerSymbol that uses a TrueType character to display point features.

Object Model


Syntax

Visual Basic (Declaration) 
<SerializableAttribute()>
Public Class TrueTypeMarkerSymbol 
   Inherits MarkerSymbol
Visual Basic (Usage)Copy Code
Dim instance As TrueTypeMarkerSymbol
C# 
[SerializableAttribute()]
public class TrueTypeMarkerSymbol : MarkerSymbol 

Example

The following example renders a cities layer with a TrueType symbol using a TrueTypeMarkerSymbol.
Visual BasicCopy Code
' Create a new TrueTypeMarker symbol and set its properties

Dim trueTypeMarker As New TrueTypeMarkerSymbol()

Dim fontInfo As New FontInfo("ESRI Conservation", 16, Drawing.Color.MidnightBlue, FontStyle.Regular)

trueTypeMarker.Font = fontInfo

trueTypeMarker.Character = "U"c ' in VB, use c to specify Char type

trueTypeMarker.AllowLabelOverlap = True

trueTypeMarker.Angle = 10

trueTypeMarker.Antialiasing = True

trueTypeMarker.GlowColor = Drawing.Color.Ivory

trueTypeMarker.ShadowColor = Drawing.Color.Gray

trueTypeMarker.Transparency = 30



' Retrieve an existing point layer's renderer

Dim layer As FeatureLayer = mapView.Layers.FindByName("Cities")

Dim grpRend As GroupRenderer = layer.Renderer



' Create a new simple renderer to contain the symbol, and replace the existing feature renderer

Dim simpleRend As New SimpleRenderer(trueTypeMarker)

grpRend.Renderers.RemoveAt(0)

grpRend.Renderers.Add(simpleRend)

C#Copy Code
// Create a new TrueTypeMarker symbol and set its properties 

TrueTypeMarkerSymbol trueTypeMarker = new TrueTypeMarkerSymbol(); 

FontInfo fontInfo = new FontInfo("ESRI Conservation", 16, Drawing.Color.MidnightBlue, FontStyle.Regular); 

trueTypeMarker.Font = fontInfo; 

trueTypeMarker.Character = "U"; 

trueTypeMarker.AllowLabelOverlap = true; 

trueTypeMarker.Angle = 10; 

trueTypeMarker.Antialiasing = true; 

trueTypeMarker.GlowColor = Drawing.Color.Ivory; 

trueTypeMarker.ShadowColor = Drawing.Color.Gray; 

trueTypeMarker.Transparency = 30; 

  

// Retrieve an existing point layer's renderer 

FeatureLayer layer = mapView.Layers.FindByName("Cities"); 

GroupRenderer grpRend = layer.Renderer; 

  

// Create a new simple renderer to contain the symbol, and replace the existing feature renderer 

SimpleRenderer simpleRend = new SimpleRenderer(trueTypeMarker); 

grpRend.Renderers.RemoveAt(0); 

grpRend.Renderers.Add(simpleRend); 

    

Remarks

A TrueTypeMarkerSymbol is used to display features with TrueType font characters. Any font installed on the Spatial Server machine may be used for the character. Note that if multiple machines are used as Spatial Servers, all must have the font installed.

To specify the character to use for the symbol, set the Font and the Character properties. The Font property describes which font on the system to use. The Character property specifies which character within the font to use for the symbol.

Tip: Use the Windows Character Map utility to explore and find the appropriate font and character. If the font displays standard Latin-style characters (i.e., a standard A-Z alphabet), you can simply use the character to define the Character value (see the Character property for examples). If the characters are symbols or a non-Latin alphabet, you will need to obtain its numeric value (decimal or hexadecimal), or find the Latin character equivalent. Click on the character you want to use to display the hexadecimal value in the status bar of Character Map. You can either use this value directly, or compare the position with a Latin-type character set to find the equivalent Latin character. See the Character property for example of converting this value to a usable value.

For ArcMap Server image services, valid only for acetate layers. ArcMap Server ignores several of the properties of this class. For details, see the topic for TRUETYPEMARKERSYMBOL in the ArcIMS Help, at ArcXML Guide - Symbol elements - TRUETYPEMARKERSYMBOL. The ArcIMS Help is also available online at ESRI).

Inheritance Hierarchy

System.Object
   ESRI.ArcGIS.ADF.IMS.Display.Symbol.Symbol
      ESRI.ArcGIS.ADF.IMS.Display.Symbol.FeatureSymbol
         ESRI.ArcGIS.ADF.IMS.Display.Symbol.MarkerSymbol
            ESRI.ArcGIS.ADF.IMS.Display.Symbol.TrueTypeMarkerSymbol

See Also

© 2010 All Rights Reserved.