Skip to content

Overlay

Namespace: ThinkGeo.UI.WebApi

A base class of Overlay, provides some methods and properties for Overlays.

public abstract class Overlay

Inheritance ObjectOverlay

Properties

Id

Gets the ID.

public string Id { get; }

Property Value

String
The ID.

IsVisible

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

public bool IsVisible { get; set; }

Property Value

Boolean
true if this overlay is visible; otherwise, false.

DrawingExceptionMode

Gets or sets the drawing exception mode.

public DrawingExceptionMode DrawingExceptionMode { get; set; }

Property Value

DrawingExceptionMode
The drawing exception mode.

Methods

Draw(GeoCanvas)

Draws the tile on GeoCanvas.

public void Draw(GeoCanvas geoCanvas)

Parameters

geoCanvas GeoCanvas
The GeoCanvas.

DrawCore(GeoCanvas)

The core process of Draw.

protected abstract void DrawCore(GeoCanvas geoCanvas)

Parameters

geoCanvas GeoCanvas
The geo canvas.

DrawException(GeoCanvas, Exception)

This method will draw on the canvas when an exception occurs during the drawing process.

protected void DrawException(GeoCanvas geoCanvas, Exception e)

Parameters

geoCanvas GeoCanvas
This parameter is the canvas object to draw on.

e Exception
This parameter is the exception that is occurring.

DrawExceptionCore(GeoCanvas, Exception)

This method is the Core method of DrawException, which can be overridden if you want to change its logic. This method will draw on the canvas when an exception occurs during drawing process.

protected void DrawExceptionCore(GeoCanvas geoCanvas, Exception e)

Parameters

geoCanvas GeoCanvas
This parameter is the canvas object to draw on.

e Exception
This parameter is the exception that is occurring.

OnDrawing(DrawingOverlayEventArgs)

This event will be fired before Overlay is drawn.

protected void OnDrawing(DrawingOverlayEventArgs e)

Parameters

e DrawingOverlayEventArgs
The OverlayDrawingEventArgs passed for the event raised.

OnDrawn(DrawnOverlayEventArgs)

This event will be fired after Overlay is drawn.

protected void OnDrawn(DrawnOverlayEventArgs e)

Parameters

e DrawnOverlayEventArgs
The OverlayDrawnEventArgs passed for the event raised.

Events

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;