Skip to content

ExtentInteractiveOverlay

Namespace: ThinkGeo.Core

This class inherits from InteractiveOverlay abstract class. This specified overlay describe the Extent Changing interactive process with MapControl using Mouse or Keyboard.

public class ExtentInteractiveOverlay : InteractiveOverlay, System.IDisposable

Inheritance ObjectOverlayInteractiveOverlayExtentInteractiveOverlay
Implements IDisposable

Fields

ORIGINAL_ZOOM_CENTER

public static string ORIGINAL_ZOOM_CENTER;

Properties

PanMode

Gets or sets the PanMode used for the ExtentInteractiveOverlay.

public MapPanMode PanMode { get; set; }

Property Value

MapPanMode

ZoomSnapDirection

public ZoomSnapDirection ZoomSnapDirection { get; set; }

Property Value

ZoomSnapDirection

MinimumTrackZoomInExtentInPixels

public float MinimumTrackZoomInExtentInPixels { get; set; }

Property Value

Single

MouseWheelMode

Gets or sets the MouseWheelMode used for the ExtentInteractiveOverlay.

public MapMouseWheelMode MouseWheelMode { get; set; }

Property Value

MapMouseWheelMode

DoubleLeftClickMode

Gets or sets the DoubleLeftClickMode used for the ExtentInteractiveOverlay.

public MapDoubleClickMode DoubleLeftClickMode { get; set; }

Property Value

MapDoubleClickMode

DoubleRightClickMode

Gets or sets the DoubleRightClickMode used for the ExtentInteractiveOverlay.

public MapDoubleClickMode DoubleRightClickMode { get; set; }

Property Value

MapDoubleClickMode

RotationMouseButton

Gets or sets the LeftClickDragMode used for the ExtentInteractiveOverlay.

public MapMouseButton RotationMouseButton { get; set; }

Property Value

MapMouseButton

RotationKey

Gets or sets the Keys used in LeftClickDrag for the ExtentInteractiveOverlay.

public Key RotationKey { get; set; }

Property Value

Key

TrackZoomInMouseButton

Gets or sets the RightClickDragMode used for the ExtentInteractiveOverlay.

public MapMouseButton TrackZoomInMouseButton { get; set; }

Property Value

MapMouseButton

TrackZoomInKey

Gets or sets the Keys used in RightClickDrag for the ExtentInteractiveOverlay.

public Key TrackZoomInKey { get; set; }

Property Value

Key

ExtentChangedType

Gets or sets the ExtentChangedType for the ExtentInteractiveOverlay.

public ExtentChangedType ExtentChangedType { get; protected set; }

Property Value

ExtentChangedType

ZoomPercentage

Gets or sets the zoom percentage when using the mouse wheel or double-clicking to zoom the MapControl.

public int ZoomPercentage { get; set; }

Property Value

Int32

MapZoomMode

public MapZoomMode MapZoomMode { get; set; }

Property Value

MapZoomMode

DrawingMarginPercentage

This property gets and sets the extra drawing margin as a percentage around the map that draw to ensure that labeling is correct.

public double DrawingMarginPercentage { get; set; }

Property Value

Double

        This property gets the extra drawing margin as a percentage around the map that
        draws to ensure that labeling is correct.

Remarks:

This extra margin that we draw exists so that labels match up if they are partially cut off.

CanRefreshRegion

public bool CanRefreshRegion { get; protected set; }

Property Value

Boolean

IsBase

public bool IsBase { get; set; }

Property Value

Boolean

Name

Gets or sets the name of this overaly.

public string Name { get; set; }

Property Value

String

MapArguments

Gets or sets current map information which will be used for calculating mechanism.

public MapArguments MapArguments { get; set; }

Property Value

MapArguments

OverlayCanvas

Gets or sets the actual canvas which maintains all the visual elements on the overlay.

public Canvas OverlayCanvas { get; set; }

Property Value

Canvas

DrawingExceptionMode

This property gets and sets the DrawingExceptionMode used when an exception occurs during drawing.

public DrawingExceptionMode DrawingExceptionMode { get; set; }

Property Value

DrawingExceptionMode

IsVisible

Gets or sets if this overlay is visible.

public bool IsVisible { get; set; }

Property Value

Boolean

Attribution

public string Attribution { get; set; }

Property Value

String

IsEmpty

This property gets if this overlay is empty or not.

public bool IsEmpty { get; }

Property Value

Boolean

Remarks:

This property enhances the performance of the overlay while drawing. If is true, we will skip drawing this overlay and continue drawing the next overlay.

AutoRefreshInterval

public TimeSpan AutoRefreshInterval { get; set; }

Property Value

TimeSpan

Constructors

ExtentInteractiveOverlay()

Default constructor of the class.

If you use thi constructor, please set the properties correctly or it will use their default values.

public ExtentInteractiveOverlay()

Methods

InitializeCore(MapArguments)

protected void InitializeCore(MapArguments mapArguments)

Parameters

mapArguments MapArguments

DrawAsyncCore(RectangleShape, OverlayRefreshType, CancellationToken)

This method actually draws this overlay.

protected Task DrawAsyncCore(RectangleShape targetExtent, OverlayRefreshType overlayRefreshType, CancellationToken cancellationToken)

Parameters

targetExtent RectangleShape
The bounding box to draw.

overlayRefreshType OverlayRefreshType
The refresh type.

cancellationToken CancellationToken

Returns

Task

KeyDownCore(KeyEventInteractionArguments)

protected InteractiveResult KeyDownCore(KeyEventInteractionArguments interactionArguments)

Parameters

interactionArguments KeyEventInteractionArguments

Returns

InteractiveResult

MouseDownCore(InteractionArguments)

This overrides the MouseDown logic in its base class InteractiveOverlay.

protected InteractiveResult MouseDownCore(InteractionArguments interactionArguments)

Parameters

interactionArguments InteractionArguments
This parameter is the interaction arguments for the method.

Returns

InteractiveResult
Interaction results of this method.

MouseMoveCore(InteractionArguments)

This overrides the MouseMove logic in its base class InteractiveOverlay.

protected InteractiveResult MouseMoveCore(InteractionArguments interactionArguments)

Parameters

interactionArguments InteractionArguments
This parameter is the interaction arguments for the method.

Returns

InteractiveResult
Interaction results of this method.

ManipulationStartedCore(InteractionArguments)

protected InteractiveResult ManipulationStartedCore(InteractionArguments interactionArguments)

Parameters

interactionArguments InteractionArguments

Returns

InteractiveResult

ManipulationDeltaCore(InteractionArguments)

protected InteractiveResult ManipulationDeltaCore(InteractionArguments interactionArguments)

Parameters

interactionArguments InteractionArguments

Returns

InteractiveResult

ManipulationCompletedCore(InteractionArguments)

protected InteractiveResult ManipulationCompletedCore(InteractionArguments interactionArguments)

Parameters

interactionArguments InteractionArguments

Returns

InteractiveResult

MouseUpCore(InteractionArguments)

This overrides the MouseUp logic in its base class InteractiveOverlay.

protected InteractiveResult MouseUpCore(InteractionArguments interactionArguments)

Parameters

interactionArguments InteractionArguments
This parameter is the interaction arguments for the method.

Returns

InteractiveResult
Interaction results of this method.

MouseWheelCore(InteractionArguments)

This overrides the MouseWheel logic in its base class InteractiveOverlay.

protected InteractiveResult MouseWheelCore(InteractionArguments interactionArguments)

Parameters

interactionArguments InteractionArguments
This parameter is the interaction arguments for the method.

Returns

InteractiveResult
Interaction results of this method.

MouseDoubleClickCore(InteractionArguments)

This overrides the MouseDoubleClick logic in its base class InteractiveOverlay.

protected InteractiveResult MouseDoubleClickCore(InteractionArguments interactionArguments)

Parameters

interactionArguments InteractionArguments
This parameter is the interaction arguments for the method.

Returns

InteractiveResult
Interaction results of this method.

MouseEnterCore(InteractionArguments)

This overrides the MouseEnter logic in its base class InteractiveOverlay.

protected InteractiveResult MouseEnterCore(InteractionArguments interactionArguments)

Parameters

interactionArguments InteractionArguments

Returns

InteractiveResult

Events

MapMouseDown

This event will be fired when Mouse pressed Down on the Map.

public event EventHandler<MapMouseDownInteractiveOverlayEventArgs> MapMouseDown;

MapMouseMove

This event will be fired when Mouse moved on the Map.

public event EventHandler<MapMouseMoveInteractiveOverlayEventArgs> MapMouseMove;

MapMouseUp

This event will be fired when Mouse released up on the Map.

public event EventHandler<MapMouseUpInteractiveOverlayEventArgs> MapMouseUp;

MapMouseClick

This event will be fired when Mouse clicked(mouse up and mouse down in the same postion) on the Map.

public event EventHandler<MapMouseClickInteractiveOverlayEventArgs> MapMouseClick;

MapMouseDoubleClick

This event will be fired when Mouse double clicked on the Map.

public event EventHandler<MapMouseDoubleClickInteractiveOverlayEventArgs> MapMouseDoubleClick;

MapMouseWheel

This event will be fired when Mouse wheel on the Map.

public event EventHandler<MapMouseWheelInteractiveOverlayEventArgs> MapMouseWheel;

MapMouseLeave

Occurs when mouse leave the map canvas.

public event EventHandler<MapMouseLeaveInteractiveOverlayEventArgs> MapMouseLeave;

MapMouseEnter

Occurs when mouse enter the map canvas.

public event EventHandler<MapMouseEnterInteractiveOverlayEventArgs> MapMouseEnter;

MapKeyDown

Occurs when key down on the map canvas.

public event EventHandler<MapKeyDownInteractiveOverlayEventArgs> MapKeyDown;

MapKeyUp

Occurs when key up on the map canvas.

public event EventHandler<MapKeyUpInteractiveOverlayEventArgs> MapKeyUp;

Drawing

This event raises before the overlay is drawing.

public event EventHandler<DrawingOverlayEventArgs> Drawing;

Drawn

This event raises after the overlay is drawn.

public event EventHandler<DrawnOverlayEventArgs> Drawn;

DrawingAttribution

public event EventHandler<DrawingAttributionOverlayEventArgs> DrawingAttribution;

DrawnAttribution

public event EventHandler<DrawnAttributionOverlayEventArgs> DrawnAttribution;

ThrowingException

public event EventHandler<ThrowingExceptionOverlayEventArgs> ThrowingException;