KeyColorColorizer.ItemKeyProvider Property

Gets or sets the items' key provider.

Namespace: DevExpress.XtraMap

Assembly: DevExpress.XtraMap.v20.1.dll

Declaration

[DefaultValue(null)]
public IColorizerItemKeyProvider ItemKeyProvider { get; set; }
<DefaultValue(Nothing)>
Public Property ItemKeyProvider As IColorizerItemKeyProvider

Property Value

Type Default Description
DevExpress.XtraMap.IColorizerItemKeyProvider

null

An object implementing the DevExpress.XtraMap.IColorizerItemKeyProvider interface.

Examples

MapColorizer CreateColorizer() {
    KeyColorColorizer colorizer = new KeyColorColorizer() {
        ItemKeyProvider = new ArgumentItemKeyProvider()
    };

    colorizer.Colors.Add(Color.FromArgb(255, 207, 98));
    colorizer.Colors.Add(Color.FromArgb(169, 181, 188));
    colorizer.Colors.Add(Color.FromArgb(233, 152, 118));

    colorizer.Keys.Add(new ColorizerKeyItem() { Key = 1, Name = "Gold" });
    colorizer.Keys.Add(new ColorizerKeyItem() { Key = 2, Name = "Silver" });
    colorizer.Keys.Add(new ColorizerKeyItem() { Key = 3, Name = "Bronze" });

    return colorizer;
}
See Also