• Product Bundles

    DevCraft

    All Telerik .NET tools and Kendo UI JavaScript components in one package. Now enhanced with:

    • NEW: Design Kits for Figma
    • Online Training
    • Document Processing Library
    • Embedded Reporting for web and desktop
    Web
    Kendo UI UI for jQuery UI for Angular UI for React UI for Vue UI for ASP.NET AJAX UI for ASP.NET MVC UI for ASP.NET Core UI for Blazor UI for Silverlight UI for PHP UI for JSP
    Mobile
    UI for .NET MAUI UI for Xamarin
    Document Management
    Telerik Document Processing
    Desktop
    UI for .NET MAUI UI for WinUI UI for WinForms UI for WPF UI for UWP
    Reporting & Mocking
    Telerik Reporting Telerik Report Server Telerik JustMock
    Automated Testing
    Test Studio Test Studio Dev Edition
    CMS
    Sitefinity
    UI/UX Design
    Unite UX
    Debugging
    Fiddler Fiddler Everywhere Fiddler Classic Fiddler Jam FiddlerCap FiddlerCore
    Extended Reality
    UI for Unity XR
    Free Tools
    JustAssembly JustDecompile VB.NET to C# Converter Testing Framework
    View all products
  • Overview
  • Demos
    • What's New
    • Roadmap
    • Release History
  • Docs & Support
  • Pricing
  • Search
  • Shopping cart
    • Account Overview
    • Your Licenses
    • Support Center
    • Forum Profile
    • Payment Methods
    • Edit Profile
    • Log out
  • Login
  • Contact Us
  • Try now

Class RadMap

Represents the RadMap class.

Inheritance
System.Object
RadMap
MiniMap
Namespace: Telerik.Windows.Controls
Assembly: Telerik.Windows.Controls.DataVisualization.dll

Syntax

[TelerikToolboxCategory("Data Visualization")]
public class RadMap : ItemsControl

Constructors

RadMap()

Initializes a new instance of the RadMap class.

Declaration
public RadMap()

Fields

CenterProperty

Identifies the Center Center dependency property.

Declaration
public static readonly DependencyProperty CenterProperty
Field Value
System.Windows.DependencyProperty

CommandBarVisibilityProperty

Identifies the CommandBarVisibility dependency property.

Declaration
public static readonly DependencyProperty CommandBarVisibilityProperty
Field Value
System.Windows.DependencyProperty

DistanceUnitProperty

Identifies the DistanceUnit DistanceUnit dependency property.

Declaration
public static readonly DependencyProperty DistanceUnitProperty
Field Value
System.Windows.DependencyProperty

GeoBoundsNWProperty

Identifies the GeoBoundsNW GeoBoundsNW dependency property.

Declaration
public static readonly DependencyProperty GeoBoundsNWProperty
Field Value
System.Windows.DependencyProperty

GeoBoundsProperty

Identifies the GeoBounds GeoBounds dependency property.

Declaration
public static readonly DependencyProperty GeoBoundsProperty
Field Value
System.Windows.DependencyProperty

GeoBoundsSEProperty

Identifies the GeoBoundsSE GeoBoundsSE dependency property.

Declaration
public static readonly DependencyProperty GeoBoundsSEProperty
Field Value
System.Windows.DependencyProperty

IsKeyboardNavigationEnabledProperty

Identifies the IsKeyboardNavigationEnabled dependency property.

Declaration
public static readonly DependencyProperty IsKeyboardNavigationEnabledProperty
Field Value
System.Windows.DependencyProperty

IsMiniMapExpandedProperty

Identifies the IsMiniMapExpanded dependency property.

Declaration
public static readonly DependencyProperty IsMiniMapExpandedProperty
Field Value
System.Windows.DependencyProperty

MapMouseClickEvent

Identifies the MapMouseClick routed event.

Declaration
public static readonly RoutedEvent MapMouseClickEvent
Field Value
System.Windows.RoutedEvent

MapMouseDoubleClickEvent

Identifies the MapMouseDoubleClick routed event.

Declaration
public static readonly RoutedEvent MapMouseDoubleClickEvent
Field Value
System.Windows.RoutedEvent

MaxZoomLevelProperty

Identifies the MaxZoomLevel dependency property.

Declaration
public static readonly DependencyProperty MaxZoomLevelProperty
Field Value
System.Windows.DependencyProperty

MiniMapExpanderVisibilityProperty

Identifies the MiniMapExpanderVisibility dependency property.

Declaration
public static readonly DependencyProperty MiniMapExpanderVisibilityProperty
Field Value
System.Windows.DependencyProperty

MiniMapHeightProperty

Identifies the MiniMapHeight dependency property.

Declaration
public static readonly DependencyProperty MiniMapHeightProperty
Field Value
System.Windows.DependencyProperty

MiniMapWidthProperty

Identifies the MiniMapWidth dependency property.

Declaration
public static readonly DependencyProperty MiniMapWidthProperty
Field Value
System.Windows.DependencyProperty

MinZoomLevelProperty

Identifies the MinZoomLevel dependency property.

Declaration
public static readonly DependencyProperty MinZoomLevelProperty
Field Value
System.Windows.DependencyProperty

MouseClickModeProperty

Identifies the MouseClickMode dependency property.

Declaration
public static readonly DependencyProperty MouseClickModeProperty
Field Value
System.Windows.DependencyProperty

MouseDoubleClickModeProperty

Identifies the MouseDoubleClickMode dependency property.

Declaration
public static readonly DependencyProperty MouseDoubleClickModeProperty
Field Value
System.Windows.DependencyProperty

MouseDragModeProperty

Identifies the MouseDragMode dependency property.

Declaration
public static readonly DependencyProperty MouseDragModeProperty
Field Value
System.Windows.DependencyProperty

MouseLocationIndicatorVisibilityProperty

Identifies the MouseLocationIndicatorVisibility dependency property.

Declaration
public static readonly DependencyProperty MouseLocationIndicatorVisibilityProperty
Field Value
System.Windows.DependencyProperty

MouseSelectionModeProperty

Identifies the MouseSelectionMode dependency property.

Declaration
public static readonly DependencyProperty MouseSelectionModeProperty
Field Value
System.Windows.DependencyProperty

MouseShiftDragModeProperty

Identifies the MouseShiftDragMode dependency property.

Declaration
public static readonly DependencyProperty MouseShiftDragModeProperty
Field Value
System.Windows.DependencyProperty

MouseWheelModeProperty

Identifies the MouseWheelMode dependency property.

Declaration
public static readonly DependencyProperty MouseWheelModeProperty
Field Value
System.Windows.DependencyProperty

MouseWheelSensitivityProperty

Identifies the MouseWheelSensitivity dependency property.

Declaration
public static readonly DependencyProperty MouseWheelSensitivityProperty
Field Value
System.Windows.DependencyProperty

NavigationVisibilityProperty

Identifies the NavigationVisibility dependency property.

Declaration
public static readonly DependencyProperty NavigationVisibilityProperty
Field Value
System.Windows.DependencyProperty

PanningFinishedEvent

Identifies the PanningFinished routed event.

Declaration
public static readonly RoutedEvent PanningFinishedEvent
Field Value
System.Windows.RoutedEvent

ProviderProperty

Identifies the Provider Provider dependency property.

Declaration
public static readonly DependencyProperty ProviderProperty
Field Value
System.Windows.DependencyProperty

ProvidersProperty

Identifies the Providers dependency property.

Declaration
public static readonly DependencyProperty ProvidersProperty
Field Value
System.Windows.DependencyProperty

ScaleVisibilityProperty

Identifies the ScaleVisibility dependency property.

Declaration
public static readonly DependencyProperty ScaleVisibilityProperty
Field Value
System.Windows.DependencyProperty

SpringAnimationsModeProperty

Identifies the SpringAnimationsMode dependency property.

Declaration
public static readonly DependencyProperty SpringAnimationsModeProperty
Field Value
System.Windows.DependencyProperty

UseDefaultLayoutProperty

Identifies the UseDefaultLayout dependency property.

Declaration
public static readonly DependencyProperty UseDefaultLayoutProperty
Field Value
System.Windows.DependencyProperty

UseSpringAnimationsProperty

Identifies the UseSpringAnimations dependency property.

Declaration
public static readonly DependencyProperty UseSpringAnimationsProperty
Field Value
System.Windows.DependencyProperty

WrapAroundProperty

Identifies the WrapAround dependency property.

Declaration
public static readonly DependencyProperty WrapAroundProperty
Field Value
System.Windows.DependencyProperty

ZoomBarDropDownHeightProperty

Identifies the ZoomBarDropDownHeight dependency property.

Declaration
public static readonly DependencyProperty ZoomBarDropDownHeightProperty
Field Value
System.Windows.DependencyProperty

ZoomBarPresetsVisibilityProperty

Identifies the ZoomBarPresetsVisibility dependency property.

Declaration
public static readonly DependencyProperty ZoomBarPresetsVisibilityProperty
Field Value
System.Windows.DependencyProperty

ZoomBarVisibilityProperty

Identifies the ZoomBarVisibility dependency property.

Declaration
public static readonly DependencyProperty ZoomBarVisibilityProperty
Field Value
System.Windows.DependencyProperty

ZoomingFinishedEvent

Identifies the ZoomingFinished routed event.

Declaration
public static readonly RoutedEvent ZoomingFinishedEvent
Field Value
System.Windows.RoutedEvent

ZoomLevelProperty

Identifies the ZoomLevel ZoomLevel dependency property.

Declaration
public static readonly DependencyProperty ZoomLevelProperty
Field Value
System.Windows.DependencyProperty

ZoomProperty

Identifies the Zoom dependency property.

Declaration
public static readonly DependencyProperty ZoomProperty
Field Value
System.Windows.DependencyProperty

ZoomStepProperty

Identifies the ZoomStep dependency property.

Declaration
public static readonly DependencyProperty ZoomStepProperty
Field Value
System.Windows.DependencyProperty

Properties

Center

Gets or sets center of the map. In WrapAround mode Center's Longitude exceeds boundaries (-180; 180). To coerce it you can use the method GetCoercedLocation(Location).

Declaration
public Location Center { get; set; }
Property Value
Location

CommandBarVisibility

Gets or sets visibility of the embedded MapCommandBar UI control.

Declaration
public Visibility CommandBarVisibility { get; set; }
Property Value
System.Windows.Visibility

DistanceUnit

Gets or sets distance unit.

Declaration
public DistanceUnit DistanceUnit { get; set; }
Property Value
DistanceUnit

GeoBounds

Gets or sets map geographical bounds.

Declaration
public LocationRect GeoBounds { get; set; }
Property Value
LocationRect

Remarks

You can't use this property to set bounds at the same time with GeoBoundsNW and GeoBoundsSE properties.

GeoBoundsNW

Gets or sets north-west corner of the map geographical bounds.

Declaration
public Location GeoBoundsNW { get; set; }
Property Value
Location

Remarks

You can't use this property to set bounds at the same time with GeoBounds property.

GeoBoundsSE

Gets or sets south-east corner of the map geographical bounds.

Declaration
public Location GeoBoundsSE { get; set; }
Property Value
Location

Remarks

You can't use this property to set bounds at the same time with GeoBounds property.

GeographicalBounds

Gets bounds of the geographical region covered by map control.

Declaration
public Rect GeographicalBounds { get; }
Property Value
System.Windows.Rect

IsInitialized

Gets value which indicates whether map control have been initialized.

Declaration
public bool IsInitialized { get; }
Property Value
System.Boolean

IsKeyboardNavigationEnabled

Gets or sets value which indicates whether keyboard can be used to navigate over the map.

Declaration
public bool IsKeyboardNavigationEnabled { get; set; }
Property Value
System.Boolean

IsMiniMapExpanded

Gets or sets value which indicates whether the embedded MiniMap UI control is expanded.

Declaration
public bool IsMiniMapExpanded { get; set; }
Property Value
System.Boolean

LocationRect

Gets LocationRect of the geographical region covered by map control.

Declaration
public LocationRect LocationRect { get; }
Property Value
LocationRect

MapZoomBar

Gets the default zoom control.

Declaration
public MapZoomBar MapZoomBar { get; }
Property Value
MapZoomBar

The map zoom panel.

MaxZoomLevel

Gets or sets maximum ZoomLevel.

Declaration
public int MaxZoomLevel { get; set; }
Property Value
System.Int32

MiniMapExpanderVisibility

Gets or sets visibility of the embedded MiniMapExpander UI control.

Declaration
public Visibility MiniMapExpanderVisibility { get; set; }
Property Value
System.Windows.Visibility

MiniMapHeight

Gets or sets height of the embedded MiniMap UI control.

Declaration
public double MiniMapHeight { get; set; }
Property Value
System.Double

MiniMapWidth

Gets or sets width of the embedded MiniMap UI control.

Declaration
public double MiniMapWidth { get; set; }
Property Value
System.Double

MinZoomLevel

Gets or sets minimum ZoomLevel.

Declaration
public int MinZoomLevel { get; set; }
Property Value
System.Int32

MouseClickMode

Gets or sets Mouse Click Mode property.

Declaration
public MouseBehavior MouseClickMode { get; set; }
Property Value
MouseBehavior

MouseDoubleClickMode

Gets or sets Mouse Double Click Mode property.

Declaration
public MouseBehavior MouseDoubleClickMode { get; set; }
Property Value
MouseBehavior

MouseDragMode

Gets or sets Mouse Drag Mode property.

Declaration
public MouseDragBehavior MouseDragMode { get; set; }
Property Value
MouseDragBehavior

MouseLocationIndicatorVisibility

Gets or sets visibility of the embedded MouseLocationIndicator UI control.

Declaration
public Visibility MouseLocationIndicatorVisibility { get; set; }
Property Value
System.Windows.Visibility

MouseSelectionMode

Gets or sets Mouse Selection Mode property.

Declaration
public MouseSelectionMode MouseSelectionMode { get; set; }
Property Value
MouseSelectionMode

MouseShiftDragMode

Gets or sets value which specify mouse dragging behaviour when SHIFT key is pressed.

Declaration
public MouseDragBehavior MouseShiftDragMode { get; set; }
Property Value
MouseDragBehavior

MouseWheelMode

Gets or sets the mode of mouse wheel.

Declaration
public MouseWheelBehavior MouseWheelMode { get; set; }
Property Value
MouseWheelBehavior

MouseWheelSensitivity

Gets or sets the sensitivity of mouse wheel.

Declaration
public double MouseWheelSensitivity { get; set; }
Property Value
System.Double

NavigationVisibility

Gets or sets visibility of the embedded MapNavigation UI control (the arrows navigation).

Declaration
public Visibility NavigationVisibility { get; set; }
Property Value
System.Windows.Visibility

PinchManipulationSensitivity

Gets or sets sensitivity of the pinch manipulation on the touch screens.

Declaration
public double PinchManipulationSensitivity { get; set; }
Property Value
System.Double

Remarks

The value must be in the [0..1] range.

Provider

Get or sets map provider.

Declaration
public MapProviderBase Provider { get; set; }
Property Value
MapProviderBase

Providers

Gets collection of the map image providers.

Declaration
public MapProviderCollection Providers { get; }
Property Value
MapProviderCollection

ScaleVisibility

Gets or sets visibility of the embedded MapScale UI control.

Declaration
public Visibility ScaleVisibility { get; set; }
Property Value
System.Windows.Visibility

SpatialReference

Gets or sets current Spatial Reference of the Map control.

Declaration
public ISpatialReference SpatialReference { get; set; }
Property Value
ISpatialReference

SpringAnimationsMode

Gets or sets mode of map animation.

Declaration
public SpringAnimationsMode SpringAnimationsMode { get; set; }
Property Value
SpringAnimationsMode

UseDefaultLayout

Gets or sets value which indicates whether map control should use default layout for navigation and map mode controls.

Declaration
public bool UseDefaultLayout { get; set; }
Property Value
System.Boolean

UseSpringAnimations

Gets or sets value which indicates whether spring animations are enabled.

Declaration
public bool UseSpringAnimations { get; set; }
Property Value
System.Boolean

WrapAround

Gets or sets a value indicating whether Map Wraparound Mode is Enabled. When in WrapAround mode - the map always covers the viewport horizontally, panning can be considered unlimited.

Declaration
public bool WrapAround { get; set; }
Property Value
System.Boolean

Zoom

Gets or sets the current zoom. Should be value between 1.0 and 20.0. It automatically sets the ZoomLevel to the biggest integer which is below the current double value.

Declaration
public double Zoom { get; set; }
Property Value
System.Double

ZoomBarDropDownHeight

Gets or sets height of the embedded MapZoomBar drop down.

Declaration
public double ZoomBarDropDownHeight { get; set; }
Property Value
System.Double

ZoomBarPresetsVisibility

Gets or sets the visibility of the MapZoomBar preset buttons that zoom to predefined levels on the map (World, State, Region, City, Hood).

Declaration
public Visibility ZoomBarPresetsVisibility { get; set; }
Property Value
System.Windows.Visibility

ZoomBarVisibility

Gets or sets visibility of the embedded MapZoomBar UI control.

Declaration
public Visibility ZoomBarVisibility { get; set; }
Property Value
System.Windows.Visibility

ZoomLevel

Gets or sets zoom level.

Declaration
public int ZoomLevel { get; set; }
Property Value
System.Int32

ZoomStep

Gets or sets a value indicating the zoom step when zooming with mouse or map zoom bar control.

Declaration
public double ZoomStep { get; set; }
Property Value
System.Double

Methods

ArrangeOverride(Size)

Called to arrange and size the content.

Declaration
protected override Size ArrangeOverride(Size finalSize)
Parameters
System.Windows.Size finalSize

The computed size that is used to arrange the content.

Returns
System.Windows.Size

The calculated size.

ClearContainerForItemOverride(DependencyObject, Object)

Undoes the effects of the PrepareContainerForItemOverride method.

Declaration
protected override void ClearContainerForItemOverride(DependencyObject element, object item)
Parameters
System.Windows.DependencyObject element

The container element.

System.Object item

The item.

Dispose()

Dispose all resources are used by RadMap control.

Declaration
public void Dispose()

ExportToImage(Stream, Boolean, BitmapEncoder)

Exports the current viewport of the map into a steam.

Declaration
public void ExportToImage(Stream stream, bool includeMapObjects = false, BitmapEncoder encoder = null)
Parameters
System.IO.Stream stream

The stream to which the map should be exported.

System.Boolean includeMapObjects

Indicates whether to include or not the objects from the information / visualization layers.

System.Windows.Media.Imaging.BitmapEncoder encoder

The encoder used for the export.

ExportToImage(String, Boolean, BitmapEncoder)

Exports the current viewport of the map into a file with the given fileName parameter.

Declaration
public void ExportToImage(string fileName, bool includeMapObjects = false, BitmapEncoder encoder = null)
Parameters
System.String fileName

The name of the file to which the map should be exported.

System.Boolean includeMapObjects

Indicates whether to include or not the objects from the information / visualization layers.

System.Windows.Media.Imaging.BitmapEncoder encoder

The encoder used for the export.

GetCoercedLocation(Location)

Gets a Location in longitude range(-180;180) by shifting the given location's longitude.

Declaration
public Location GetCoercedLocation(Location location)
Parameters
Location location

Returns
Location

GetCoercedLocationRect(LocationRect)

Gets a LocationRect whose West is in longitude range(-180;180) by shifting the given LocationRect West longitude.

Declaration
public LocationRect GetCoercedLocationRect(LocationRect baseRect)
Parameters
LocationRect baseRect

Returns
LocationRect

GetGeoSize(Location, Size)

Calculates degree size according to base point and zoom.

Declaration
public Size GetGeoSize(Location basePoint, Size pixelSize)
Parameters
Location basePoint

Base point.

System.Windows.Size pixelSize

The size in pixels.

Returns
System.Windows.Size

Size in degree.

Examples

This example demonstrates how GetGeoSize method can be used to calculate one location from another using pixel distance between 2 points.

Location firstLocation = new Location(40, -100);
double distanceX = 10; // 10 pixels
double distanceY = 20; // 20 pixels
Size pixelSize = new Size(Math.Abs(distanceX), Math.Abs(distanceY));
Size geoSize = this.radMap.GetGeoSize(firstLocation, pixelSize);
Location secondLocation = new Location(
    firstLocation.Latitude - Math.Sign(distanceY) * geoSize.Height,
    firstLocation.Longitude + Math.Sign(distanceX) * geoSize.Width);
Dim firstLocation As New Location(40, -100)
Dim distanceX As Double = 10 ' 10 pixels
Dim distanceY As Double = 20 ' 20 pixels
Dim pixelSize As New Size(Math.Abs(distanceX), Math.Abs(distanceY))
Dim geoSize As Size = Me.radMap.GetGeoSize(firstLocation, pixelSize)
Dim secondLocation As New Location( _
    firstLocation.Latitude - Math.Sign(distanceY) * geoSize.Height, _
    firstLocation.Longitude + Math.Sign(distanceX) * geoSize.Width)

GetLatitudeLongitudeSize(Location, Double, Double)

Calculates degree size according to base point and zoom.

Declaration
public Size GetLatitudeLongitudeSize(Location basePoint, double width, double height)
Parameters
Location basePoint

Base point.

System.Double width

The width in units according to DistanceUnit property.

System.Double height

The height in units according to DistanceUnit property.

Returns
System.Windows.Size

Size in degree.

GetPixelsDistance(Double)

Calculates horizontal pixel distance according to latitude and zoom.

Declaration
public double GetPixelsDistance(double distance)
Parameters
System.Double distance

The distance in units according to DistanceUnit property.

Returns
System.Double

Horizontal distance in pixels.

GetPixelSize(Location, Double, Double)

Calculates pixel size according to base point and zoom.

Declaration
public Size GetPixelSize(Location basePoint, double width, double height)
Parameters
Location basePoint

Base point.

System.Double width

The width in units according to DistanceUnit property.

System.Double height

The height in units according to DistanceUnit property.

Returns
System.Windows.Size

Size in pixels.

GetPixelSizeAtZoomLevel(LocationRect, Int32)

Gets pixel size of the specified geographic region for the given zoom level.

Declaration
public Size GetPixelSizeAtZoomLevel(LocationRect geoRegion, int zoomLevel)
Parameters
LocationRect geoRegion

Geographical region to get pixel size for.

System.Int32 zoomLevel

Zoom level.

Returns
System.Windows.Size

Pixel size of the region.

GetShiftedLocation(Location, Nullable<Location>)

Gets a Location shifted with offset equal to the offset by which the current center is shifted outside longitude range (-180;180).

Declaration
public Location GetShiftedLocation(Location baseLocation, Location? center = default(Location? ))
Parameters
Location baseLocation

System.Nullable<Location> center

Returns
Location

IsVisible(Location)

Detect whether given location is visible in the map control.

Declaration
public bool IsVisible(Location location)
Parameters
Location location

Returns
System.Boolean

OnApplyTemplate()

When overridden in a derived class, is invoked whenever application code or internal processes (such as a rebuilding layout pass) call ApplyTemplate.

Declaration
public override void OnApplyTemplate()

OnCreateAutomationPeer()

Returns class-specific System.Windows.Automation.Peers.AutomationPeer implementations for the Windows Presentation Foundation (WPF) infrastructure.

Declaration
protected override AutomationPeer OnCreateAutomationPeer()
Returns
System.Windows.Automation.Peers.AutomationPeer

The type-specific System.Windows.Automation.Peers.AutomationPeer implementation.

OnInitialized(EventArgs)

Raises the System.Windows.FrameworkElement.Initialized event. This method is invoked whenever System.Windows.FrameworkElement.IsInitialized is set to true internally.

Declaration
protected override void OnInitialized(EventArgs e)
Parameters
System.EventArgs e

The System.Windows.RoutedEventArgs that contains the event data.

OnMouseDoubleClick(MouseButtonEventArgs)

Handles the System.Windows.Controls.Control.MouseDoubleClick routed event.

Declaration
protected override void OnMouseDoubleClick(MouseButtonEventArgs e)
Parameters
System.Windows.Input.MouseButtonEventArgs e

The event data.

OnMouseWheel(MouseWheelEventArgs)

The MouseWheel event handler.

Declaration
protected override void OnMouseWheel(MouseWheelEventArgs e)
Parameters
System.Windows.Input.MouseWheelEventArgs e

Event arguments.

PrepareContainerForItemOverride(DependencyObject, Object)

Prepares the specified element to display the specified item.

Declaration
protected override void PrepareContainerForItemOverride(DependencyObject element, object item)
Parameters
System.Windows.DependencyObject element

Element used to display the specified item.

System.Object item

Specified item.

RefreshCommandBar()

Refresh default command bar regardless whether map provider has been changed or not.

Declaration
public void RefreshCommandBar()

SetView(LocationRect, Boolean)

Sets ZoomLevel and Center so the given LocationRect object is completely visible.

Declaration
public void SetView(LocationRect view, bool useFractionZoom = false)
Parameters
LocationRect view

The location rect that should be centered in the map viewport.

System.Boolean useFractionZoom

Sets a value indicating whether the zooming of the view should use the fractional part of calculated zoom level.

SetView(LocationRect, Double)

Sets ZoomLevel and Center so the given LocationRect object, including minimum padding around it is completely visible in viewport. After this operation, zoom property is expected to have non-integer value with fractional digits.

Declaration
public void SetView(LocationRect view, double minimumPadding)
Parameters
LocationRect view

The location rect that should be centered in the map viewport.

System.Double minimumPadding

Sets a value indicating the the minimum padding around the visible view, in pixels.

Events

CenterChanged

Event occurs when the Center property of the map control is changed.

Declaration
public event EventHandler CenterChanged
Event Type
System.EventHandler

CenterChanging

Event occurs when the Center property of the map control starts to change.

Declaration
public event EventHandler<PropertyChangingEventArgs> CenterChanging
Event Type
System.EventHandler<PropertyChangingEventArgs>

InitializeCompleted

Event occurs when initialization of the map control is completed.

Declaration
public event EventHandler InitializeCompleted
Event Type
System.EventHandler

MapMouseClick

Occurs when the user clicks on the map.

Declaration
public event MouseRoutedEventHandler MapMouseClick
Event Type
MouseRoutedEventHandler

MapMouseDoubleClick

Occurs when the user does double click on the map.

Declaration
public event MouseRoutedEventHandler MapMouseDoubleClick
Event Type
MouseRoutedEventHandler

PanningFinished

Event occurs when panning of the map finished (spring animation which started when map center has been changed is finished).

Declaration
public event RoutedEventHandler PanningFinished
Event Type
System.Windows.RoutedEventHandler

SelectionRectangleChanged

Event occurs when new geographical region is selected by mouse (the MouseDragBehavior is "Select" and MouseSelectionMode is "RaiseEvent").

Declaration
public event EventHandler<SelectionRectangleChangedEventArgs> SelectionRectangleChanged
Event Type
System.EventHandler<SelectionRectangleChangedEventArgs>

ZoomChanged

Event occurs when the Zoom property of the map control is changed.

Declaration
public event EventHandler ZoomChanged
Event Type
System.EventHandler

ZoomChanging

Event occurs when the ZoomLevel property of the map control starts to change.

Declaration
public event EventHandler<PropertyChangingEventArgs> ZoomChanging
Event Type
System.EventHandler<PropertyChangingEventArgs>

ZoomingFinished

Event occurs when zooming of the map finished (spring animation which started when map zoom level has been changed is finished).

Declaration
public event RoutedEventHandler ZoomingFinished
Event Type
System.Windows.RoutedEventHandler

Extension Methods

CollectionExtensions.ToEnumerable<T>(T)
EnumerableExtensions.ToEnumerable<T>(T)

Was this article helpful?

Tell us how we can improve this article

Skip
Getting Started
  • Install Now
  • Demos
  • SDK Samples Browser
  • Sample Applications
Support Resources
  • Code Library
  • Knowledge Base
  • MVVM Support
  • Videos
  • GitHub SDK Repository
Community
  • Forums
  • Blogs
  • XAML Feedback Portal
  • Document Processing Feedback Portal

Copyright © 2018 Progress Software Corporation and/or its subsidiaries or affiliates.
All Rights Reserved.

Progress, Telerik, and certain product names used herein are trademarks or registered trademarks of Progress Software Corporation and/or one of its subsidiaries or affiliates in the U.S. and/or other countries. See Trademarks for appropriate markings.