Back to Devexpress

MapLineStartCapTemplateMapping Class

windowsforms-devexpress-dot-xtramap-0a9be23a.md

latest3.7 KB
Original Source

MapLineStartCapTemplateMapping Class

Defines the Template property for the start cap when map line settings are loaded from a data source.

Namespace : DevExpress.XtraMap

Assembly : DevExpress.XtraMap.v25.2.dll

NuGet Package : DevExpress.Win.Map

Declaration

csharp
public class MapLineStartCapTemplateMapping :
    MapShapePropertyMappingBase
vb
Public Class MapLineStartCapTemplateMapping
    Inherits MapShapePropertyMappingBase

Remarks

The following example defines a custom arrow template:

csharp
listSourceDataAdapter1.PropertyMappings.Add(new MapLineStartCapVisibleMapping() { DefaultValue = true });
listSourceDataAdapter1.PropertyMappings.Add(new MapLineStartCapLengthMapping() { DefaultValue = 12 });
listSourceDataAdapter1.PropertyMappings.Add(new MapLineStartCapWidthMapping() { DefaultValue = 15 });
MapLineStartCapTemplateMapping templateMapping = new MapLineStartCapTemplateMapping();
templateMapping.DefaultValue = new MapUnit[] {
                new MapUnit(-0.2, 0),
                new MapUnit(-0.5, -0.5),
                new MapUnit(0.25, 0),
                new MapUnit(-0.5, 0.5),
                new MapUnit(-0.2, 0),
};
listSourceDataAdapter1.PropertyMappings.Add(templateMapping);
vb
listSourceDataAdapter1.PropertyMappings.Add(New MapLineStartCapVisibleMapping() With {
        .DefaultValue = True
    })
listSourceDataAdapter1.PropertyMappings.Add(New MapLineStartCapLengthMapping() With {
        .DefaultValue = 12
    })
listSourceDataAdapter1.PropertyMappings.Add(New MapLineStartCapWidthMapping() With {
        .DefaultValue = 15
    })
Dim templateMapping As MapLineStartCapTemplateMapping = New MapLineStartCapTemplateMapping()
templateMapping.DefaultValue = New MapUnit() {New MapUnit(-0.2, 0), 
                                              New MapUnit(-0.5, -0.5), 
                                              New MapUnit(0.25, 0), 
                                              New MapUnit(-0.5, 0.5), 
                                              New MapUnit(-0.2, 0)}
listSourceDataAdapter1.PropertyMappings.Add(templateMapping)

For more examples on MapLine property mappings, see the demo:

Run Demo: Map Arrows

Inheritance

Object DevExpress.XtraMap.Native.MapItemMappingBase MapItemPropertyMappingBase DevExpress.XtraMap.MapItemPropertyMappingBase<MapShape> MapShapePropertyMappingBase MapLineStartCapTemplateMapping

See Also

MapLineStartCapTemplateMapping Members

MapLineStartCapIsFilledMapping

MapLineStartCapLengthMapping

MapLineStartCapVisibleMapping

MapLineStartCapWidthMapping

DevExpress.XtraMap Namespace