Back to Devexpress

MapCustomElement Class

wpf-devexpress-dot-xpf-dot-map-e43ffe2b.md

latest2.8 KB
Original Source

MapCustomElement Class

The class used to draw any custom element on a map.

Namespace : DevExpress.Xpf.Map

Assembly : DevExpress.Xpf.Map.v25.2.dll

NuGet Package : DevExpress.Wpf.Map

Declaration

csharp
public class MapCustomElement :
    MapItem,
    ISupportCoordLocation,
    IPointCore,
    IClusterable,
    IClusterItemCore,
    IClusterItem,
    IColorizerElement,
    IMapCallout
vb
Public Class MapCustomElement
    Inherits MapItem
    Implements ISupportCoordLocation,
               IPointCore,
               IClusterable,
               IClusterItemCore,
               IClusterItem,
               IColorizerElement,
               IMapCallout

The following members return MapCustomElement objects:

Remarks

The following image shows an example of a map custom element.

Example

View Example

xaml
<dxm:MapCustomElement>
    <dxm:MapCustomElement.ContentTemplate>
        <DataTemplate>
            <Border Name="border" BorderBrush="DarkGray"  
                Background="LightGray" BorderThickness="1"
                Padding="5" Margin="5" CornerRadius="5">
                <StackPanel Orientation="Horizontal">
                    <Image Source="DevExpress.png" Width="40" 
                       Height="40" Margin="5"/>
                    <TextBlock Text="This is a custom element." 
                           TextAlignment="Center" FontSize="18"
                           VerticalAlignment="Center" Margin="5"/>
                </StackPanel>
            </Border>
        </DataTemplate>
    </dxm:MapCustomElement.ContentTemplate>
</dxm:MapCustomElement>

Implements

IColorizerElement

Inheritance

Object DispatcherObject DependencyObject Freezable MapDependencyObject MapItem MapCustomElement

See Also

MapCustomElement Members

DevExpress.Xpf.Map Namespace