Show / Hide Table of Contents

Class MapView

The MapView is a container that holds a Map. It is the mapping component of the ArcGIS Runtime .NET SDK. It can contain mapping layers and responds to user interaction (touch, mouse, keyboard) and provides behavior for map navigation. It has multiple properties such as its extent, scale, zoom factor, rotation, etc.

Inheritance
Object
GeoView
MapView
Implements
Control
System.ComponentModel.INotifyPropertyChanged
GeoView.OnLostFocus(RoutedEventArgs)
GeoView.DrawStatusChanged
GeoView.LayerViewStateChanged
GeoView.SpatialReferenceChanged
GeoView.ViewpointChanged
GeoView.ShowCalloutForGeoElement(GeoElement, Windows.Foundation.Point, CalloutDefinition)
GeoView.ShowCalloutAt(MapPoint, CalloutDefinition)
GeoView.ShowCalloutAt(MapPoint, UIElement, Windows.Foundation.Point)
GeoView.DismissCallout()
GeoView.IsCalloutVisible
GeoView.ExportImageAsync()
GeoView.GraphicsOverlays
GeoView.GraphicsOverlaysProperty
GeoView.GetCurrentViewpoint(ViewpointType)
GeoView.SetViewpoint(Viewpoint)
GeoView.SetViewpointAsync(Viewpoint)
GeoView.SetViewpointAsync(Viewpoint, TimeSpan)
GeoView.SetBookmarkAsync(Bookmark)
GeoView.GetLayerViewState(Layer)
GeoView.IdentifyGraphicsOverlayAsync(GraphicsOverlay, Point, Double, Boolean)
GeoView.IdentifyGraphicsOverlayAsync(GraphicsOverlay, Point, Double, Boolean, Int64)
GeoView.IdentifyGraphicsOverlaysAsync(Point, Double, Boolean)
GeoView.IdentifyGraphicsOverlaysAsync(Point, Double, Boolean, Int64)
GeoView.IdentifyLayerAsync(Layer, Point, Double, Boolean)
GeoView.IdentifyLayerAsync(Layer, Point, Double, Boolean, CancellationToken)
GeoView.IdentifyLayerAsync(Layer, Point, Double, Boolean, Int64)
GeoView.IdentifyLayerAsync(Layer, Point, Double, Boolean, Int64, CancellationToken)
GeoView.IdentifyLayersAsync(Point, Double, Boolean)
GeoView.IdentifyLayersAsync(Point, Double, Boolean, CancellationToken)
GeoView.IdentifyLayersAsync(Point, Double, Boolean, Int64)
GeoView.IdentifyLayersAsync(Point, Double, Boolean, Int64, CancellationToken)
GeoView.GeoViewTapped
GeoView.GeoViewDoubleTapped
GeoView.GeoViewHolding
GeoView.INotifyPropertyChanged.PropertyChanged
GeoView.IsAttributionTextVisible
GeoView.AttributionText
GeoView.IsAttributionTextVisibleProperty
GeoView.SpatialReference
GeoView.IsWrapAroundEnabled
GeoView.IsNavigating
GeoView.NavigationCompleted
GeoView.DrawStatus
GeoView.ViewInsets
GeoView.ViewInsetsProperty
GeoView.TimeExtent
GeoView.TimeExtentProperty
GeoView.Overlays
GeoView.OverlaysProperty
GeoView.GetViewOverlayAnchor(FrameworkElement)
GeoView.SetViewOverlayAnchor(FrameworkElement, MapPoint)
GeoView.ViewOverlayAnchorProperty
GeoView.SelectionProperties
GeoView.SelectionPropertiesProperty
GeoView.Labeling
GeoView.LabelingProperty
Namespace: Esri.ArcGISRuntime.UI.Controls
Assembly: Esri.ArcGISRuntime.WinUI.dll
Syntax
public class MapView : GeoView, INotifyPropertyChanged
Remarks

The MapView is a container that holds a Map. A Map holds a collection of operational layers and Basemap. Layers are visual representations of geographic information and come in many forms. The types of layers that are displayed in a MapView are two dimensional in nature; meaning they are displayed in X/Y (a.k.a. Latitude/Longitude) coordinate space.

There is only one Map per MapView and it is set by the MapView.Map Property. Multiple Map objects can be created and swapped out dynamically as the application is running in the MapView.

Constructors

Name Description
MapView()

Initializes a new instance of the MapView class.

Fields

Name Description
BackgroundGridProperty

Identifies the BackgroundGrid Dependency Property

GridProperty

Identifies the Grid Dependency Property

InteractionOptionsProperty

Identifies the InteractionOptions Dependency Property

LocationDisplayProperty

Identifies the LocationDisplay Dependency Property

MapProperty

Identifies the Map dependency property

SketchEditorProperty

Identifies the SketchEditor Dependency Property

Properties

Name Description
BackgroundGrid

Gets or sets the background grid rendered behind the map data.

Grid

Gets or sets the grid that is available to the map for display.

InteractionOptions

Gets or sets a set of properties that control user interaction with the MapView.

LocationDisplay

Gets the location display settings used for display the device's current location.

Map

Gets or sets the map the view is rendering.

MapRotation

Gets the current rotational heading of the map

MapScale

Gets the current scale of the map

SketchEditor

Gets or sets the sketch editor used for drawing and editing on the map.

UnitsPerPixel

Gets the current size of each device independent pixel in map units.

VisibleArea

Gets the view's visible area.

WrapAroundMode

Gets or sets a whether the map will do continuous pan across the antimeridian

Methods

Name Description
CancelSetViewpointOperations()

Cancels any pending or currently running SetViewpointAsync operations.

LocationToScreen(MapPoint)

Converts a location in map coordinates to a screen coordinate relative to the upper-left corner of the map.

OnApplyTemplate()
OnCreateAutomationPeer()
ScreenToLocation(Point)

Converts a screen point relative to the upper left of the map into a location on the map.

SetViewpointAsync(Viewpoint, TimeSpan, AnimationCurve)

Animates the view to the given Viewpoint location using the provided animation curve

SetViewpointCenterAsync(MapPoint)

Centers the view on the provided point.

SetViewpointCenterAsync(MapPoint, Double)

Centers the view on the provided point and zooms to the provided scale.

SetViewpointCenterAsync(Double, Double)

Centers the view on the provided point.

SetViewpointCenterAsync(Double, Double, Double)

Centers the view on the provided point and zooms to the provided scale.

SetViewpointGeometryAsync(Geometry)

Zooms to the provided geometry.

SetViewpointGeometryAsync(Geometry, Double)

Zooms to the provided geometry and leaves some padding around the geometry.

SetViewpointRotationAsync(Double)

Sets the rotation angle of the map

SetViewpointScaleAsync(Double)

Zooms to the given scale.

Applies to

TargetVersions
.NET 6.0 Windows100.13 - 100.15
In This Article
Back to top Copyright © 2022 Esri.