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.
Implements
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
Target | Versions |
---|---|
.NET 6.0 Windows | 100.13 - 100.15 |