зеркало из https://github.com/telerik/xaml-sdk.git
35 строки
1.8 KiB
XML
35 строки
1.8 KiB
XML
<Window x:Class="InformationLayerMapPolygon.MainWindow"
|
|
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
|
xmlns:telerik="http://schemas.telerik.com/2008/xaml/presentation"
|
|
Title="MainWindow" Height="800" Width="1200">
|
|
<Grid>
|
|
<telerik:RadMap x:Name="radMap"
|
|
Width="600"
|
|
Height="480"
|
|
ZoomLevel="4"
|
|
Center="52, -100">
|
|
<telerik:RadMap.Provider>
|
|
<!-- Please specify different user agent string in your application -->
|
|
<telerik:OpenStreetMapProvider StandardModeUserAgent="Telerik UI for WPF SDK Samples"/>
|
|
</telerik:RadMap.Provider>
|
|
<telerik:InformationLayer>
|
|
<telerik:MapPolygon Points="56,-100 56,-108 48,-108 48,-100" Fill="Green" Stroke="Red"
|
|
StrokeThickness="4" CaptionLocation="52,-104">
|
|
<telerik:MapPolygon.CaptionTemplate>
|
|
<DataTemplate>
|
|
<Grid Background="Yellow">
|
|
<telerik:MapLayer.HotSpot>
|
|
<telerik:HotSpot X="0.5" Y="0.5" />
|
|
</telerik:MapLayer.HotSpot>
|
|
<TextBlock Text="My Custom Text" />
|
|
</Grid>
|
|
</DataTemplate>
|
|
</telerik:MapPolygon.CaptionTemplate>
|
|
</telerik:MapPolygon>
|
|
</telerik:InformationLayer>
|
|
</telerik:RadMap>
|
|
<telerik:MapMouseLocationIndicator MapControl="{Binding ElementName=radMap}" VerticalAlignment="Bottom" />
|
|
</Grid>
|
|
</Window>
|