Show / Hide Table of Contents

Class GraphicsOverlay

A collection of vector graphics for display in a map or scene view.

Inheritance
Object
GraphicsOverlay
Implements
System.ComponentModel.INotifyPropertyChanged
IPopupSource
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
Object.ToString()
Namespace: Esri.ArcGISRuntime.UI
Assembly: Esri.ArcGISRuntime.dll
Syntax
public sealed class GraphicsOverlay : INotifyPropertyChanged, IPopupSource
Remarks

Graphics overlays display on top of all other data in a map or scene view. A graphics overlay can contain graphics of various geometry types and can define symbology for the graphics it contains using its Renderer.

A graphic's Z-index can be used to define its draw order in the collection and is mostly relevant for display in a two dimensional map. For dynamic 3D rendering (in a scene), graphic display order is determined by the distance to the camera rather than by Z-index. Z-index is considered, however, when using static rendering in a scene (draping graphics on the surface, in other words).

If Z-index for graphics is not set, they will usually render in the order in which they were added to the graphics overlay, the first added is rendered first and subsequent ones on top. In rare cases, the rendering algorithm may change the display order to provide more efficient rendering. If ordering is important, set the ZIndex explicitly on graphics. You can also place graphics of the same geometry type in their own graphics overlay and manage the order of the overlays in the view.

Constructors

Name Description
GraphicsOverlay()

Initializes a new instance of the GraphicsOverlay class.

Properties

Name Description
Extent

Gets the calculated extent of the graphics contained in the overlay's Graphics collection.

Graphics

Gets the graphics collection.

Id

Gets or sets an ID for the overlay.

IsPopupEnabled

Gets or sets a value indicating whether the PopupDefinition defined is enabled.

IsVisible

Gets or sets a value indicating whether the overlay is visible.

LabelDefinitions

Gets a modifiable collection of label definitions for this graphics overlay.

LabelsEnabled

Gets or sets a value indicating whether labels should be displayed for Graphics in this overlay.

MaxScale

Gets or sets the maximum scale to display this layer at. A small number allows the map to display the layer when zooming further in.

MinScale

Gets or sets the minimum scale to render this layer at. A large number allows the map to display the layer when zooming further out.

Opacity

Gets or sets the opacity. Must be a value between 0 and 1.

PopupDefinition

Gets or sets the pop-up definition for the graphics overlay.

Renderer

Gets or sets the renderer used for generating symbols.

RenderingMode

Gets or sets a value indicating which rendering mode to use.

ScaleSymbols

Gets or sets a value indicating whether the overlay's symbols and labels honor the map reference scale when displayed in a map view.

SceneProperties

Gets or sets the scene properties for the graphics overlay.

SelectedGraphics

Gets the selected graphics.

Methods

Name Description
ClearSelection()

Unselects all graphics in the layer

SelectGraphics(IEnumerable<Graphic>)

Selects the specified graphics.

UnselectGraphics(IEnumerable<Graphic>)

Unselects the specified graphics.

Events

Name Description
PropertyChanged

Occurs when a property value changes.

Applies to

TargetVersions
.NET Standard 2.0100.3 - 100.15
.NET 6.0100.13 - 100.15
.NET 6.0 Windows100.13 - 100.15
.NET Framework100.0 - 100.15
.NET 5100.10 - 100.12
.NET Core 3.1100.7 - 100.12
Xamarin.Android100.0 - 100.15
Xamarin.iOS100.0 - 100.15
UWP100.0 - 100.15

Relevant samples

Add graphics with symbols: Use a symbol style to display a graphic on a graphics overlay.
Buffer: Create a buffer around a map point and display the results as a `Graphic`
In This Article
Back to top Copyright © 2022 Esri.