Table of Contents

Class GeoCanvas

Namespace
ThinkGeo.Core
Assembly
ThinkGeo.Core.dll

This class represents a view that is used to draw geographic shapes. It is intended to be inherited for the implementation of different drawing systems, such as GDI+ or WPF.

public abstract class GeoCanvas
Inheritance
GeoCanvas
Derived
Inherited Members

Remarks

This class allows you to implement different drawing systems, such as GDI+, GDI, or WPF. It can also be used for other systems, such as PDF.

The basic flow of the use of the class is to first call BeginDrawing and pass in an image along with its world extent.

Constructors

GeoCanvas()

This method is the default constructor for the GeoCanvas.

protected GeoCanvas()

Remarks

None

Properties

CancellationToken

Gets or sets the cancellation token source.

public CancellationToken CancellationToken { get; set; }

Property Value

CancellationToken

The cancellation token source.

ClippingArea

It's a property only used in printing related Canvas such as PdfGeoCanvas and PrinterGeoCanvas

public RectangleShape ClippingArea { get; set; }

Property Value

RectangleShape

CurrentScale

This property gets the current scale of the view.

public double CurrentScale { get; }

Property Value

double

Exceptions

InvalidOperationException

In the event you attempt to call this property when the GeoCanvas' IsDrawing mode is false, it will throw an InvalidOperationException.

CurrentWorldExtent

This property gets the adjusted current extent based on what was set when BeginDrawing was called.

public RectangleShape CurrentWorldExtent { get; protected set; }

Property Value

RectangleShape

Remarks

The extent that gets passed in on BeginDrawing is adjusted for the height and width of the physical media being drawn on. For example if the current extent is wider than taller but the bitmap being drawn on is square then the current extent needs to be adjusted. The extent will be adjusted larger so that we ensure that the entire original extent will still be represented.

Exceptions

InvalidOperationException

In the event you attempt to call this method when the GeoCanvas' IsDrawing mode is false, it will throw an InvalidOperationException.

Dpi

The DPI value for the final drawing result, only valid when HasDpi set to true.

public virtual float Dpi { get; set; }

Property Value

float

DrawingQuality

This property returns the drawing quality when rendering on the GeoCanvas.

public DrawingQuality DrawingQuality { get; set; }

Property Value

DrawingQuality

Remarks

The DrawingQuality specifies whether BaseLineShapes, BasePointShapes, and BaseAreaShapes use anti-aliasing methods or other techniques that control the quality. In some cases you may want a higher quality rendering, and in other cases higher speed is more desirable. It is up to the implementer of the derived GeoCanvas class to control exactly what this setting means.

FontDisplayDensity

This property gets and sets the current device pixel ratio of platform. It would be used by scale text and icon from map. Android: it's "Application.Context.Resources.DisplayMetrics.Density". iOS: it's "UIScreen.MainScreen.Scale". Others: it's default value "1".

public virtual double FontDisplayDensity { get; }

Property Value

double

Height

This property gets the height of the view.

public float Height { get; protected set; }

Property Value

float

Remarks

This property reflects the height of the view image that was passed in on BeginDrawing.

Exceptions

InvalidOperationException

In the event you attempt to call this method when the GeoCanvas' IsDrawing mode is false, it will throw an InvalidOperationException.

IsDrawing

This property gets the drawing status of the GeoCanvas.

public bool IsDrawing { get; protected set; }

Property Value

bool

Remarks

This property is set to true when the BeginDrawing method is called, and false after the EndDrawing method is called.

KeyColors

Gets a value represents a collection of key colors. If SupportKeyColor property is false, it will throw exception when you use KeyColors.

public Collection<GeoColor> KeyColors { get; }

Property Value

Collection<GeoColor>

Remarks

It will make these colors transparent when draw image.

MapUnit

This property returns the MapUnit passed in on the BeginDrawingAPI in the GeoCanvas.

public GeographyUnit MapUnit { get; }

Property Value

GeographyUnit

NativeImage

The same reference to the parameter 'NativeImage' in BeginDrawing function.

public object NativeImage { get; }

Property Value

object

ScaleFactor

Gets or sets the scale factor, this is a value number of device pixels per logical coordinate point.

public float ScaleFactor { get; set; }

Property Value

float

The scale factory value.

Remarks

The coordinate space used by application developers is measured in logical points. High-resolution (Retina) displays will have more than a single physical pixel per logical point and this property specifies the scale factor.

SupportKeyColor

This property indicates whether a GeoCanvas has the KeyColor or not. If it has no KeyColor, it will throw an exception when you get or set the value of KeyColors property.

public virtual bool SupportKeyColor { get; }

Property Value

bool

Remarks

The default value is false.

Width

This property gets the width of the view.

public float Width { get; protected set; }

Property Value

float

Remarks

This property reflects the width of the view image that was passed in on BeginDrawing.

Exceptions

InvalidOperationException

In the event you attempt to call this method when the GeoCanvas' IsDrawing mode is false, it will throw an InvalidOperationException.

Methods

BeginDrawing(object, RectangleShape, GeographyUnit)

This method begins the act of drawing on the GeoCanvas.

public void BeginDrawing(object geoImage, RectangleShape worldExtent, GeographyUnit drawingMapUnit)

Parameters

geoImage object

This parameter represents the image you want the GeoCanvas to draw on.

worldExtent RectangleShape

This parameter is the world extent of the canvasImage.

drawingMapUnit GeographyUnit

This parameter is the map unit of the canvasImage.

Remarks

This is the first method that needs to be called before any drawing takes place. Calling this method will set the IsDrawing property to true. When you finish drawing, you must call EndDrawing to commit the changes to the image.

BeginDrawingCore(object, RectangleShape, GeographyUnit)

This method begins the act of drawing on the GeoCanvas.

protected abstract void BeginDrawingCore(object nativeImage, RectangleShape worldExtent, GeographyUnit drawingMapUnit)

Parameters

nativeImage object

This parameter represents the image you want the GeoCanvas to draw on.

worldExtent RectangleShape

This parameter is the world extent of the canvasImage.

drawingMapUnit GeographyUnit

This parameter is the map unit of the canvasImage.

Remarks

This is the first method that needs to be called before any drawing takes place. Calling this method will set the IsDrawing property to true. When you finish drawing, you must call EndDrawing to commit the changes to the image.

Clear(GeoBrush)

This method clears the current GeoCanvas using the color specified.

public void Clear(GeoBrush fillBrush)

Parameters

fillBrush GeoBrush

Remarks

Use this method to clear the GeoCanvas.

ClearCore(GeoBrush)

This method clears the current GeoCanvas using the color specified.

protected virtual void ClearCore(GeoBrush fillBrush)

Parameters

fillBrush GeoBrush

This parameter specifies the the brush that will be used to clear the GeoCanvas.

Remarks

Use this method to clear the GeoCanvas.

This method is designed to be overridden by the deriving class.

CreateDefaultGeoCanvas()

Creates the default geo canvas.

public static GeoCanvas CreateDefaultGeoCanvas()

Returns

GeoCanvas

DrawArc(GeoPen, float, float, float, float, float, float, DrawingLevel)

Draws the arc.

public void DrawArc(GeoPen pen, float x, float y, float width, float height, float startAngle, float sweepAngle, DrawingLevel drawingLevel)

Parameters

pen GeoPen

The pen.

x float

The x.

y float

The y.

width float

The width.

height float

The height.

startAngle float

The start angle.

sweepAngle float

The sweep angle.

drawingLevel DrawingLevel

The drawing level.

DrawArc(GeoPen, DrawingRectangleF, float, float, DrawingLevel)

Draws the arc.

public void DrawArc(GeoPen pen, DrawingRectangleF rect, float startAngle, float sweepAngle, DrawingLevel drawingLevel)

Parameters

pen GeoPen

The pen.

rect DrawingRectangleF

The rect.

startAngle float

The start angle.

sweepAngle float

The sweep angle.

drawingLevel DrawingLevel

The drawing level.

DrawArcCore(GeoPen, float, float, float, float, float, float, DrawingLevel)

Draws the arc core.

protected abstract void DrawArcCore(GeoPen pen, float x, float y, float width, float height, float startAngle, float sweepAngle, DrawingLevel drawingLevel)

Parameters

pen GeoPen

The pen.

x float

The x.

y float

The y.

width float

The width.

height float

The height.

startAngle float

The start angle.

sweepAngle float

The sweep angle.

drawingLevel DrawingLevel

The drawing level.

DrawArea(IEnumerable<ScreenPointF[]>, GeoPen, GeoBrush, DrawingLevel, float, float, PenBrushDrawingOrder)

This method draws an area on the GeoCanvas.

public void DrawArea(IEnumerable<ScreenPointF[]> screenPoints, GeoPen outlinePen, GeoBrush fillBrush, DrawingLevel drawingLevel, float xOffset, float yOffset, PenBrushDrawingOrder penBrushDrawingOrder)

Parameters

screenPoints IEnumerable<ScreenPointF[]>

This parameter is the AreaShape in well-known binary format.

outlinePen GeoPen

This parameter describes the outline GeoPen that will be used to draw the AreaShape.

fillBrush GeoBrush

This parameter describes the fill GeoBrush that will be used to draw the AreaShape.

drawingLevel DrawingLevel

This parameter determines the DrawingLevel that the GeoPen will draw on.

xOffset float

This parameter determines the X offset for the feature to be drawn.

yOffset float

This parameter determines the Y offset for the feature to be drawn.

penBrushDrawingOrder PenBrushDrawingOrder

This parameter determines the PenBrushDrawingOrder used when drawing the area type feature.

Remarks

This method is used to draw on the GeoCanvas. It provides you with a number of overloads that allow you to control how things are drawn. Specify the GeoBrush to fill in an area. Specify the GeoPen to outline an area using that GeoPen. You can also call an overload that will allow you to specify both a GeoPen and a GeoBrush.

The DrawingLevel allows you to specify the level you will draw on when you are drawing multiple areas. This is very useful when you want to draw a drop shadow, for example. In that case, you could draw the black backdrop on the lowest level with an offset, then draw the normal shape on a higher level without an offset.

Exceptions

InvalidOperationException

In the event you attempt to call this method when the GeoCanvas' IsDrawing mode is false, it will throw an InvalidOperationException.

ArgumentException

Passing invalid well-known binary in the areaShapeWkb parameter will throw an ArgumentException.

ArgumentNullException

If you pass a null as the areaShapeWkb, we will throw an ArgumentNullException.

ArgumentNullException

If you pass a null as the outlinePen, we will throw an ArgumentNullException.

ArgumentNullException

If you pass a null as the fillBrush, we will throw an ArgumentNullException.

ArgumentOutOfRangeException

If you pass in a drawingLevel that is not defined in the enumeration, it will throw a ArgumentOutOfRangeException.

DrawArea(AreaBaseShape, GeoBrush, DrawingLevel)

This method draws an area on the GeoCanvas.

public void DrawArea(AreaBaseShape shape, GeoBrush fillBrush, DrawingLevel drawingLevel)

Parameters

shape AreaBaseShape

This parameter is the area shape to be drawn.

fillBrush GeoBrush

This parameter describes the fill Brush that will be used to draw the AreaShape.

drawingLevel DrawingLevel

This parameter determines the DrawingLevel that the GeoPen will draw on.

Remarks

This method is used to draw on the GeoCanvas. It provides you with a number of overloads that allow you to control how things are drawn. Specify the GeoBrush to fill in an area. Specify the GeoPen to outline an area using that GeoPen. You can also call an overload that will allow you to specify both a GeoPen and a GeoBrush.

The DrawingLevel allows you to specify the level you will draw on when you are drawing multiple areas. This is very useful when you want to draw a drop shadow, for example. In that case, you could draw the black backdrop on the lowest level with an offset, then draw the normal shape on a higher level without an offset.

Exceptions

InvalidOperationException

In the event you attempt to call this method when the GeoCanvas' IsDrawing mode is false, it will throw an InvalidOperationException.

ArgumentException

Passing invalid well-known binary in the areaShapeWkb parameter will throw an ArgumentException.

ArgumentNullException

If you pass a null as the areaShapeWkb, we will throw an ArgumentNullException.

ArgumentNullException

If you pass a null as the outlinePen, we will throw an ArgumentNullException.

ArgumentNullException

If you pass a null as the fillBrush, we will throw an ArgumentNullException.

ArgumentOutOfRangeException

If you pass in a drawingLevel that is not defined in the enumeration, it will throw a ArgumentOutOfRangeException.

DrawArea(AreaBaseShape, GeoPen, DrawingLevel)

This method draws an area on the GeoCanvas.

public void DrawArea(AreaBaseShape shape, GeoPen outlinePen, DrawingLevel drawingLevel)

Parameters

shape AreaBaseShape

This parameter is the area shape.

outlinePen GeoPen

This parameter describes the outline GeoPen that will be used to draw the area.

drawingLevel DrawingLevel

This parameter determines the DrawingLevel that the GeoPen will draw on.

Remarks

This method is used to draw on the GeoCanvas. It provides you with a number of overloads that allow you to control how things are drawn. Specify the GeoBrush to fill in an area. Specify the GeoPen to outline an area using that GeoPen. You can also call an overload that will allow you to specify both a GeoPen and a GeoBrush.

The DrawingLevel allows you to specify the level you will draw on when you are drawing multiple areas. This is very useful when you want to draw a drop shadow, for example. In that case, you could draw the black backdrop on the lowest level with an offset, then draw the normal shape on a higher level without an offset.

Exceptions

InvalidOperationException

In the event you attempt to call this method when the GeoCanvas' IsDrawing mode is false, it will throw an InvalidOperationException.

ArgumentException

Passing invalid well-known binary in the areaShapeWkb parameter will throw an ArgumentException.

ArgumentNullException

If you pass a null as the areaShapeWkb, we will throw an ArgumentNullException.

ArgumentNullException

If you pass a null as the outlinePen, we will throw an ArgumentNullException.

ArgumentOutOfRangeException

If you pass in a drawingLevel that is not defined in the enumeration, it will throw a ArgumentOutOfRangeException.

DrawArea(AreaBaseShape, GeoPen, GeoBrush, DrawingLevel)

This method draws an area on the GeoCanvas.

public void DrawArea(AreaBaseShape shape, GeoPen outlinePen, GeoBrush fillBrush, DrawingLevel drawingLevel)

Parameters

shape AreaBaseShape

This parameter is the area shape to be drawn.

outlinePen GeoPen

This parameter describes the outline pen that will be used to draw the AreaShape.

fillBrush GeoBrush

This parameter describes the fill Brush that will be used to draw the AreaShape.

drawingLevel DrawingLevel

This parameter determines the DrawingLevel that the GeoPen will draw on.

Remarks

This method is used to draw on the GeoCanvas. It provides you with a number of overloads that allow you to control how things are drawn. Specify the GeoBrush to fill in an area. Specify the GeoPen to outline an area using that GeoPen. You can also call an overload that will allow you to specify both a GeoPen and a GeoBrush.

The DrawingLevel allows you to specify the level you will draw on when you are drawing multiple areas. This is very useful when you want to draw a drop shadow, for example. In that case, you could draw the black backdrop on the lowest level with an offset, then draw the normal shape on a higher level without an offset.

Exceptions

InvalidOperationException

In the event you attempt to call this method when the GeoCanvas' IsDrawing mode is false, it will throw an InvalidOperationException.

ArgumentException

Passing invalid well-known binary in the areaShapeWkb parameter will throw an ArgumentException.

ArgumentNullException

If you pass a null as the areaShapeWkb, we will throw an ArgumentNullException.

ArgumentNullException

If you pass a null as the outlinePen, we will throw an ArgumentNullException.

ArgumentNullException

If you pass a null as the fillBrush, we will throw an ArgumentNullException.

ArgumentOutOfRangeException

If you pass in a drawingLevel that is not defined in the enumeration, it will throw a ArgumentOutOfRangeException.

DrawArea(AreaBaseShape, GeoPen, GeoBrush, DrawingLevel, float, float, PenBrushDrawingOrder)

This method draws an area on the GeoCanvas.

public void DrawArea(AreaBaseShape shape, GeoPen outlinePen, GeoBrush fillBrush, DrawingLevel drawingLevel, float xOffset, float yOffset, PenBrushDrawingOrder penBrushDrawingOrder)

Parameters

shape AreaBaseShape

This parameter is the area shape to be drawn.

outlinePen GeoPen

This parameter describes the outline GeoPen that will be used to draw the AreaShape.

fillBrush GeoBrush

This parameter describes the fill GeoBrush that will be used to draw the AreaShape.

drawingLevel DrawingLevel

This parameter determines the DrawingLevel that the GeoPen will draw on.

xOffset float

This parameter determines the X offset for the feature to be drawn.

yOffset float

This parameter determines the Y offset for the feature to be drawn.

penBrushDrawingOrder PenBrushDrawingOrder

This parameter determines the PenBrushDrawingOrder used when drawing the area type feature.

Remarks

This method is used to draw on the GeoCanvas. It provides you with a number of overloads that allow you to control how things are drawn. Specify the GeoBrush to fill in an area. Specify the GeoPen to outline an area using that GeoPen. You can also call an overload that will allow you to specify both a GeoPen and a GeoBrush.

The DrawingLevel allows you to specify the level you will draw on when you are drawing multiple areas. This is very useful when you want to draw a drop shadow, for example. In that case, you could draw the black backdrop on the lowest level with an offset, then draw the normal shape on a higher level without an offset.

Exceptions

InvalidOperationException

In the event you attempt to call this method when the GeoCanvas' IsDrawing mode is false, it will throw an InvalidOperationException.

ArgumentException

Passing invalid well-known binary in the areaShapeWkb parameter will throw an ArgumentException.

ArgumentNullException

If you pass a null as the areaShapeWkb, we will throw an ArgumentNullException.

ArgumentNullException

If you pass a null as the outlinePen, we will throw an ArgumentNullException.

ArgumentNullException

If you pass a null as the fillBrush, we will throw an ArgumentNullException.

ArgumentOutOfRangeException

If you pass in a drawingLevel that is not defined in the enumeration, it will throw a ArgumentOutOfRangeException.

DrawArea(Feature, GeoBrush, DrawingLevel)

This method draws an area on the GeoCanvas.

public void DrawArea(Feature feature, GeoBrush fillBrush, DrawingLevel drawingLevel)

Parameters

feature Feature

This parameter is the AreaShape in well-known binary format.

fillBrush GeoBrush

This parameter describes the fill GeoBrush that will be used to draw the AreaShape.

drawingLevel DrawingLevel

This parameter determines the DrawingLevel that the GeoPen will draw on.

Remarks

This method is used to draw on the GeoCanvas. It provides you with a number of overloads that allow you to control how things are drawn. Specify the GeoBrush to fill in an area. Specify the GeoPen to outline an area using that GeoPen. You can also call an overload that will allow you to specify both a GeoPen and a GeoBrush.

The DrawingLevel allows you to specify the level you will draw on when you are drawing multiple areas. This is very useful when you want to draw a drop shadow, for example. In that case, you could draw the black backdrop on the lowest level with an offset, then draw the normal shape on a higher level without an offset.

Exceptions

InvalidOperationException

In the event you attempt to call this method when the GeoCanvas' IsDrawing mode is false, it will throw an InvalidOperationException.

ArgumentException

Passing invalid well-known binary in the areaShapeWkb parameter will throw an ArgumentException.

ArgumentNullException

If you pass a null as the areaShapeWkb, we will throw an ArgumentNullException.

ArgumentNullException

If you pass a null as the fillBrush, we will throw an ArgumentNullException.

ArgumentOutOfRangeException

If you pass in a drawingLevel that is not defined in the enumeration, it will throw a ArgumentOutOfRangeException.

DrawArea(Feature, GeoPen, DrawingLevel)

This method draws an area on the GeoCanvas.

public void DrawArea(Feature feature, GeoPen outlinePen, DrawingLevel drawingLevel)

Parameters

feature Feature

This parameter is the area feature.

outlinePen GeoPen

This parameter describes the outline GeoPen that will be used to draw the area.

drawingLevel DrawingLevel

This parameter determines the DrawingLevel that the GeoPen will draw on.

Remarks

This method is used to draw on the GeoCanvas. It provides you with a number of overloads that allow you to control how things are drawn. Specify the GeoBrush to fill in an area. Specify the GeoPen to outline an area using that GeoPen. You can also call an overload that will allow you to specify both a GeoPen and a GeoBrush.

The DrawingLevel allows you to specify the level you will draw on when you are drawing multiple areas. This is very useful when you want to draw a drop shadow, for example. In that case, you could draw the black backdrop on the lowest level with an offset, then draw the normal shape on a higher level without an offset.

Exceptions

InvalidOperationException

In the event you attempt to call this method when the GeoCanvas' IsDrawing mode is false, it will throw an InvalidOperationException.

ArgumentException

Passing invalid well-known binary in the areaShapeWkb parameter will throw an ArgumentException.

ArgumentNullException

If you pass a null as the areaShapeWkb, we will throw an ArgumentNullException.

ArgumentNullException

If you pass a null as the outlinePen, we will throw an ArgumentNullException.

ArgumentOutOfRangeException

If you pass in a drawingLevel that is not defined in the enumeration, it will throw a ArgumentOutOfRangeException.

DrawArea(Feature, GeoPen, GeoBrush, DrawingLevel)

This method draws an area on the GeoCanvas.

public void DrawArea(Feature feature, GeoPen outlinePen, GeoBrush fillBrush, DrawingLevel drawingLevel)

Parameters

feature Feature

This parameter is the AreaFeature to be drawn.

outlinePen GeoPen

This parameter describes the outline GeoPen that will be used to draw the AreaShape.

fillBrush GeoBrush

This parameter describes the fill GeoBrush that will be used to draw the AreaShape.

drawingLevel DrawingLevel

This parameter determines the DrawingLevel that the GeoPen will draw on.

Remarks

This method is used to draw on the GeoCanvas. It provides you with a number of overloads that allow you to control how things are drawn. Specify the GeoBrush to fill in an area. Specify the GeoPen to outline an area using that GeoPen. You can also call an overload that will allow you to specify both a GeoPen and a GeoBrush.

The DrawingLevel allows you to specify the level you will draw on when you are drawing multiple areas. This is very useful when you want to draw a drop shadow, for example. In that case, you could draw the black backdrop on the lowest level with an offset, then draw the normal shape on a higher level without an offset.

Exceptions

InvalidOperationException

In the event you attempt to call this method when the GeoCanvas' IsDrawing mode is false, it will throw an InvalidOperationException.

ArgumentException

Passing invalid well-known binary in the areaShapeWkb parameter will throw an ArgumentException.

ArgumentNullException

If you pass a null as the areaShapeWkb, we will throw an ArgumentNullException.

ArgumentNullException

If you pass a null as the outlinePen, we will throw an ArgumentNullException.

ArgumentNullException

If you pass a null as the fillBrush, we will throw an ArgumentNullException.

ArgumentOutOfRangeException

If you pass in a drawingLevel that is not defined in the enumeration, it will throw a ArgumentOutOfRangeException.

DrawArea(Feature, GeoPen, GeoBrush, DrawingLevel, float, float, PenBrushDrawingOrder)

This method draws an area on the GeoCanvas.

public void DrawArea(Feature feature, GeoPen outlinePen, GeoBrush fillBrush, DrawingLevel drawingLevel, float xOffset, float yOffset, PenBrushDrawingOrder penBrushDrawingOrder)

Parameters

feature Feature

This parameter is the AreaFeature to be drawn.

outlinePen GeoPen

This parameter describes the outline GeoPen that will be used to draw the AreaShape.

fillBrush GeoBrush

This parameter describes the fill GeoBrush that will be used to draw the AreaShape.

drawingLevel DrawingLevel

This parameter determines the DrawingLevel that the GeoPen will draw on.

xOffset float

This parameter determines the X offset for the feature that will be drawn.

yOffset float

This parameter determines the Y offset for the feature that will be drawn.

penBrushDrawingOrder PenBrushDrawingOrder

This parameter determines the PenBrushingDrawingOrder used when drawing the area type feature.

Remarks

This method is used to draw on the GeoCanvas. It provides you with a number of overloads that allow you to control how things are drawn. Specify the GeoBrush to fill in an area. Specify the GeoPen to outline an area using that GeoPen. You can also call an overload that will allow you to specify both a GeoPen and a GeoBrush.

The DrawingLevel allows you to specify the level you will draw on when you are drawing multiple areas. This is very useful when you want to draw a drop shadow, for example. In that case, you could draw the black backdrop on the lowest level with an offset, then draw the normal shape on a higher level without an offset.

Exceptions

InvalidOperationException

In the event you attempt to call this method when the GeoCanvas' IsDrawing mode is false, it will throw an InvalidOperationException.

ArgumentException

Passing invalid well-known binary in the areaShapeWkb parameter will throw an ArgumentException.

ArgumentNullException

If you pass a null as the areaShapeWkb, we will throw an ArgumentNullException.

ArgumentNullException

If you pass a null as the outlinePen, we will throw an ArgumentNullException.

ArgumentNullException

If you pass a null as the fillBrush, we will throw an ArgumentNullException.

ArgumentOutOfRangeException

If you pass in a drawingLevel that is not defined in the enumeration, it will throw a ArgumentOutOfRangeException.

DrawAreaCore(IEnumerable<ScreenPointF[]>, GeoPen, GeoBrush, DrawingLevel, float, float, PenBrushDrawingOrder)

This method draws an area on the GeoCanvas.

protected abstract void DrawAreaCore(IEnumerable<ScreenPointF[]> screenPoints, GeoPen outlinePen, GeoBrush fillBrush, DrawingLevel drawingLevel, float xOffset, float yOffset, PenBrushDrawingOrder penBrushDrawingOrder)

Parameters

screenPoints IEnumerable<ScreenPointF[]>

This parameter is the AreaShape in well-known binary format.

outlinePen GeoPen

This parameter describes the outline GeoPen that will be used to draw the AreaShape.

fillBrush GeoBrush

This parameter describes the fill GeoBrush that will be used to draw the AreaShape.

drawingLevel DrawingLevel

This parameter determines the DrawingLevel that the GeoPen will draw on.

xOffset float

This parameter determines the X offset for the feature to be drawn.

yOffset float

This parameter determines the Y offset for the feature to be drawn.

penBrushDrawingOrder PenBrushDrawingOrder

This parameter determines the PenBrushDrawingOrder used when drawing the area type feature.

Remarks

This method is used to draw on the GeoCanvas. It provides you with a number of overloads that allow you to control how things are drawn. Specify the GeoBrush to fill in an area. Specify the GeoPen to outline an area using that GeoPen. You can also call an overload that will allow you to specify both a GeoPen and a GeoBrush.

The DrawingLevel allows you to specify the level you will draw on when you are drawing multiple areas. This is very useful when you want to draw a drop shadow, for example. In that case, you could draw the black backdrop on the lowest level with an offset, then draw the normal shape on a higher level without an offset.

Exceptions

InvalidOperationException

In the event you attempt to call this method when the GeoCanvas' IsDrawing mode is false, it will throw an InvalidOperationException.

ArgumentException

Passing invalid well-known binary in the areaShapeWkb parameter will throw an ArgumentException.

ArgumentNullException

If you pass a null as the areaShapeWkb, we will throw an ArgumentNullException.

ArgumentNullException

If you pass a null as the outlinePen, we will throw an ArgumentNullException.

ArgumentNullException

If you pass a null as the fillBrush, we will throw an ArgumentNullException.

ArgumentOutOfRangeException

If you pass in a drawingLevel that is not defined in the enumeration, it will throw a ArgumentOutOfRangeException.

DrawEllipse(Feature, float, float, GeoBrush, DrawingLevel)

Draws a point on the GeoCanvas.

public void DrawEllipse(Feature centerPointFeature, float width, float height, GeoBrush fillBrush, DrawingLevel drawingLevel)

Parameters

centerPointFeature Feature

This parameter is the center point feature.

width float

This parameter describes the width of the ellipse to be drawn.

height float

This parameter describes the height of the ellipse to be drawn.

fillBrush GeoBrush

This parameter describes the fill GeoBrush that will be used to draw the point.

drawingLevel DrawingLevel

This parameter determines the DrawingLevel the the GeoBrush will draw on.

Remarks

This method is used to draw a point on the GeoCanvas. It provides you with a number of overloads that allow you to control how it is drawn. Specify the GeoBrush to fill in the area of the point. Specify the GeoPen to outline the point using that GeoPen. You can also call a overload that will allow you to specify both a GeoPen and a GeoBrush.

The DrawingLevel allows you to specify the level you will draw on when drawing many points.

Exceptions

InvalidOperationException

In the event you attempt to call this method when the GeoCanvas' IsDrawing mode is false, it will throw an InvalidOperationException.

ArgumentException

Passing invalid well-known binary in the pointShapeWkb parameter will throw an ArgumentException.

ArgumentNullException

If you pass a null as the pointShapeWkb, we will throw an ArgumentNullException.

ArgumentNullException

If you pass a null as the fillBrush, we will throw an ArgumentNullException.

ArgumentOutOfRangeException

If you pass in a drawingLevel that is not defined in the enumeration, it will throw a ArgumentOutOfRangeException.

DrawEllipse(Feature, float, float, GeoPen, DrawingLevel)

Draws a point on the GeoCanvas.

public void DrawEllipse(Feature feature, float width, float height, GeoPen outlinePen, DrawingLevel drawingLevel)

Parameters

feature Feature

This parameter is the center point feature.

width float

This parameter describes the width of the ellipse to be drawn.

height float

This parameter describes the height of the ellipse to be drawn.

outlinePen GeoPen

This parameter describes the outline GeoPen that will be used to draw the point.

drawingLevel DrawingLevel

This parameter determines the DrawingLevel that the GeoPen will draw on.

Remarks

This method is used to draw a point on the GeoCanvas. It provides you with a number of overloads that allow you to control how it is drawn. Specify the GeoBrush to fill in the area of the point. Specify the GeoPen to outline the point using that GeoPen. You can also call a overload that will allow you to specify both a GeoPen and a GeoBrush.

The DrawingLevel allows you to specify the level you will draw on when drawing many points.

Exceptions

InvalidOperationException

In the event you attempt to call this method when the GeoCanvas' IsDrawing mode is false, it will throw an InvalidOperationException.

ArgumentException

Passing invalid well-known binary in the pointShapeWkb parameter will throw an ArgumentException.

ArgumentNullException

If you pass a null as the pointShapeWkb, we will throw an ArgumentNullException.

ArgumentNullException

If you pass a null as the outlinePen, we will throw an ArgumentNullException.

ArgumentOutOfRangeException

If you pass in a drawingLevel that is not defined in the enumeration, it will throw a ArgumentOutOfRangeException.

DrawEllipse(Feature, float, float, GeoPen, GeoBrush, DrawingLevel)

Draws a point on the GeoCanvas.

public void DrawEllipse(Feature feature, float width, float height, GeoPen outlinePen, GeoBrush fillBrush, DrawingLevel drawingLevel)

Parameters

feature Feature

This parameter is the center point feature.

width float

This parameter describes the width of the ellipse to be drawn.

height float

This parameter describes the height of the ellipse to be drawn.

outlinePen GeoPen

This parameter describes the outline GeoPen that will be used to draw the point.

fillBrush GeoBrush

This parameter describes the fill GeoBrush that will be used to draw the point.

drawingLevel DrawingLevel

This parameter determines the DrawingLevel that the GeoPen or GeoBrush will draw on.

Remarks

This method is used to draw a point on the GeoCanvas. It provides you with a number of overloads that allow you to control how it is drawn. Specify the GeoBrush to fill in the area of the point. Specify the GeoPen to outline the point using that GeoPen. You can also call a overload that will allow you to specify both a GeoPen and a GeoBrush.

The DrawingLevel allows you to specify the level you will draw on when drawing many points.

Exceptions

InvalidOperationException

In the event you attempt to call this method when the GeoCanvas' IsDrawing mode is false, it will throw an InvalidOperationException.

ArgumentException

Passing invalid well-known binary in the pointShapeWkb parameter will throw an ArgumentException.

ArgumentNullException

If you pass a null as the pointShapeWkb, we will throw an ArgumentNullException.

ArgumentNullException

If you pass a null as the outlinePen and a null as the fillBrush, we will throw an ArgumentNullException.

ArgumentOutOfRangeException

If you pass in a drawingLevel that is not defined in the enumeration, it will throw a ArgumentOutOfRangeException.

DrawEllipse(Feature, float, float, GeoPen, GeoBrush, DrawingLevel, float, float, PenBrushDrawingOrder)

Draws a point on the GeoCanvas.

public void DrawEllipse(Feature feature, float width, float height, GeoPen outlinePen, GeoBrush fillBrush, DrawingLevel drawingLevel, float xOffset, float yOffset, PenBrushDrawingOrder penBrushDrawingOrder)

Parameters

feature Feature

This parameter is the center point feature.

width float

This parameter describes the width of the ellipse to be drawn.

height float

This parameter describes the height of the ellipse to be drawn.

outlinePen GeoPen

This parameter describes the outline GeoPen that will be used to draw the point.

fillBrush GeoBrush

This parameter describes the fill GeoBrush that will be used to draw the point.

drawingLevel DrawingLevel

This parameter determines the DrawingLevel that the GeoPen or GeoBrush will draw on.

xOffset float

This parameter determines the X offset for the ellipse to be drawn.

yOffset float

This parameter determines the Y offset for the ellipse to be drawn.

penBrushDrawingOrder PenBrushDrawingOrder

This parameter determines the PenBrushDrawingOrder used when drawing the ellipse.

Remarks

This method is used to draw a point on the GeoCanvas. It provides you with a number of overloads that allow you to control how it is drawn. Specify the GeoBrush to fill in the area of the point. Specify the GeoPen to outline the point using that GeoPen. You can also call a overload that will allow you to specify both a GeoPen and a GeoBrush.

The DrawingLevel allows you to specify the level you will draw on when drawing many points.

Exceptions

InvalidOperationException

In the event you attempt to call this method when the GeoCanvas' IsDrawing mode is false, it will throw an InvalidOperationException.

ArgumentException

Passing invalid well-known binary in the pointShapeWkb parameter will throw an ArgumentException.

ArgumentNullException

If you pass a null as the pointShapeWkb, we will throw an ArgumentNullException.

ArgumentNullException

If you pass a null as the fillBrush, we will throw an ArgumentNullException.

ArgumentOutOfRangeException

If you pass in a drawingLevel that is not defined in the enumeration, it will throw a ArgumentOutOfRangeException.

DrawEllipse(PointBaseShape, float, float, GeoBrush, DrawingLevel)

Draws a point on the GeoCanvas.

public void DrawEllipse(PointBaseShape shape, float width, float height, GeoBrush fillBrush, DrawingLevel drawingLevel)

Parameters

shape PointBaseShape

This parameter is the center point shape.

width float

This parameter describes the width of the ellipse to be drawn.

height float

This parameter describes the height of the ellipse to be drawn.

fillBrush GeoBrush

This parameter describes the fill GeoBrush that will be used to draw the point.

drawingLevel DrawingLevel

This parameter determines the DrawingLevel the the GeoBrush will draw on.

Remarks

This method is used to draw a point on the GeoCanvas. It provides you with a number of overloads that allow you to control how it is drawn. Specify the GeoBrush to fill in the area of the point. Specify the GeoPen to outline the point using that GeoPen. You can also call a overload that will allow you to specify both a GeoPen and a GeoBrush.

The DrawingLevel allows you to specify the level you will draw on when drawing many points.

Exceptions

InvalidOperationException

In the event you attempt to call this method when the GeoCanvas' IsDrawing mode is false, it will throw an InvalidOperationException.

ArgumentException

Passing invalid well-known binary in the pointShapeWkb parameter will throw an ArgumentException.

ArgumentNullException

If you pass a null as the pointShapeWkb, we will throw an ArgumentNullException.

ArgumentNullException

If you pass a null as the fillBrush, we will throw an ArgumentNullException.

ArgumentOutOfRangeException

If you pass in a drawingLevel that is not defined in the enumeration, it will throw a ArgumentOutOfRangeException.

DrawEllipse(PointBaseShape, float, float, GeoPen, DrawingLevel)

Draws a point on the GeoCanvas.

public void DrawEllipse(PointBaseShape shape, float width, float height, GeoPen outlinePen, DrawingLevel drawingLevel)

Parameters

shape PointBaseShape

This parameter is the center point shape.

width float

This parameter describes the width of the ellipse to be drawn.

height float

This parameter describes the height of the ellipse to be drawn.

outlinePen GeoPen

This parameter describes the outline GeoPen that will be used to draw the point.

drawingLevel DrawingLevel

This parameter determines the DrawingLevel that the GeoPen will draw on.

Remarks

This method is used to draw a point on the GeoCanvas. It provides you with a number of overloads that allow you to control how it is drawn. Specify the GeoBrush to fill in the area of the point. Specify the GeoPen to outline the point using that GeoPen. You can also call a overload that will allow you to specify both a GeoPen and a GeoBrush.

The DrawingLevel allows you to specify the level you will draw on when drawing many points.

Exceptions

InvalidOperationException

In the event you attempt to call this method when the GeoCanvas' IsDrawing mode is false, it will throw an InvalidOperationException.

ArgumentException

Passing invalid well-known binary in the pointShapeWkb parameter will throw an ArgumentException.

ArgumentNullException

If you pass a null as the pointShapeWkb, we will throw an ArgumentNullException.

ArgumentNullException

If you pass a null as the outlinePen, we will throw an ArgumentNullException.

ArgumentOutOfRangeException

If you pass in a drawingLevel that is not defined in the enumeration, it will throw a ArgumentOutOfRangeException.

DrawEllipse(PointBaseShape, float, float, GeoPen, GeoBrush, DrawingLevel)

Draws a point on the GeoCanvas.

public void DrawEllipse(PointBaseShape shape, float width, float height, GeoPen outlinePen, GeoBrush fillBrush, DrawingLevel drawingLevel)

Parameters

shape PointBaseShape

This parameter is the center point shape.

width float

This parameter describes the width of the ellipse to be drawn.

height float

This parameter describes the height of the ellipse to be drawn.

outlinePen GeoPen

This parameter describes the outline GeoPen that will be used to draw the point.

fillBrush GeoBrush

This parameter describes the fill GeoBrush that will be used to draw the point.

drawingLevel DrawingLevel

This parameter determines the DrawingLevel that the GeoPen or GeoBrush will draw on.

Remarks

This method is used to draw a point on the GeoCanvas. It provides you with a number of overloads that allow you to control how it is drawn. Specify the GeoBrush to fill in the area of the point. Specify the GeoPen to outline the point using that GeoPen. You can also call a overload that will allow you to specify both a GeoPen and a GeoBrush.

The DrawingLevel allows you to specify the level you will draw on when drawing many points.

Exceptions

InvalidOperationException

In the event you attempt to call this method when the GeoCanvas' IsDrawing mode is false, it will throw an InvalidOperationException.

ArgumentException

Passing invalid well-known binary in the pointShapeWkb parameter will throw an ArgumentException.

ArgumentNullException

If you pass a null as the pointShapeWkb, we will throw an ArgumentNullException.

ArgumentNullException

If you pass a null as the fillBrush, we will throw an ArgumentNullException.

ArgumentOutOfRangeException

If you pass in a drawingLevel that is not defined in the enumeration, it will throw a ArgumentOutOfRangeException.

DrawEllipse(PointBaseShape, float, float, GeoPen, GeoBrush, DrawingLevel, float, float, PenBrushDrawingOrder)

Draws a point on the GeoCanvas.

public void DrawEllipse(PointBaseShape shape, float width, float height, GeoPen outlinePen, GeoBrush fillBrush, DrawingLevel drawingLevel, float xOffset, float yOffset, PenBrushDrawingOrder penBrushDrawingOrder)

Parameters

shape PointBaseShape

This parameter is the center point shape.

width float

This parameter describes the width of the ellipse to be drawn.

height float

This parameter describes the height of the ellipse to be drawn.

outlinePen GeoPen

This parameter describes the outline GeoPen that will be used to draw the point.

fillBrush GeoBrush

This parameter describes the fill GeoBrush that will be used to draw the point.

drawingLevel DrawingLevel

This parameter determines the DrawingLevel that the GeoPen or GeoBrush will draw on.

xOffset float

This parameter determines the X offset for the ellipse to be drawn.

yOffset float

This parameter determines the Y offset for the ellipse to be drawn.

penBrushDrawingOrder PenBrushDrawingOrder

This parameter determines the PenBrushDrawingOrder used when drawing the ellipse.

Remarks

This method is used to draw a point on the GeoCanvas. It provides you with a number of overloads that allow you to control how it is drawn. Specify the GeoBrush to fill in the area of the point. Specify the GeoPen to outline the point using that GeoPen. You can also call a overload that will allow you to specify both a GeoPen and a GeoBrush.

The DrawingLevel allows you to specify the level you will draw on when drawing many points.

Exceptions

InvalidOperationException

In the event you attempt to call this method when the GeoCanvas' IsDrawing mode is false, it will throw an InvalidOperationException.

ArgumentException

Passing invalid well-known binary in the pointShapeWkb parameter will throw an ArgumentException.

ArgumentNullException

If you pass a null as the pointShapeWkb, we will throw an ArgumentNullException.

ArgumentNullException

If you pass a null as the fillBrush, we will throw an ArgumentNullException.

ArgumentOutOfRangeException

If you pass in a drawingLevel that is not defined in the enumeration, it will throw a ArgumentOutOfRangeException.

DrawEllipse(ScreenPointF, float, float, GeoPen, GeoBrush, DrawingLevel, float, float, PenBrushDrawingOrder)

Draws a point on the GeoCanvas.

public void DrawEllipse(ScreenPointF screenPoint, float width, float height, GeoPen outlinePen, GeoBrush fillBrush, DrawingLevel drawingLevel, float xOffset, float yOffset, PenBrushDrawingOrder penBrushDrawingOrder)

Parameters

screenPoint ScreenPointF

This parameter is the center point in screen coordinate.

width float

This parameter describes the width of the ellipse to be drawn.

height float

This parameter describes the height of the ellipse to be drawn.

outlinePen GeoPen

This parameter describes the outline GeoPen that will be used to draw the point.

fillBrush GeoBrush

This parameter describes the fill GeoBrush that will be used to draw the point.

drawingLevel DrawingLevel

This parameter determines the DrawingLevel that the GeoPen or GeoBrush will draw on.

xOffset float

This parameter determines the X offset for the ellipse to be drawn.

yOffset float

This parameter determines the Y offset for the ellipse to be drawn.

penBrushDrawingOrder PenBrushDrawingOrder

Remarks

This method is used to draw a point on the GeoCanvas. It provides you with a number of overloads that allow you to control how it is drawn. Specify the GeoBrush to fill in the area of the point. Specify the GeoPen to outline the point using that GeoPen. You can also call a overload that will allow you to specify both a GeoPen and a GeoBrush.

The DrawingLevel allows you to specify the level you will draw on when drawing many points.

Exceptions

InvalidOperationException

In the event you attempt to call this method when the GeoCanvas' IsDrawing mode is false, it will throw an InvalidOperationException.

ArgumentException

Passing invalid well-known binary in the pointShapeWkb parameter will throw an ArgumentException.

ArgumentNullException

If you pass a null as the pointShapeWkb, we will throw an ArgumentNullException.

ArgumentNullException

If you pass a null as the fillBrush, we will throw an ArgumentNullException.

ArgumentOutOfRangeException

If you pass in a drawingLevel that is not defined in the enumeration, it will throw a ArgumentOutOfRangeException.

DrawEllipseCore(ScreenPointF, float, float, GeoPen, GeoBrush, DrawingLevel, float, float, PenBrushDrawingOrder)

Draws a point on the GeoCanvas.

protected abstract void DrawEllipseCore(ScreenPointF screenPoint, float width, float height, GeoPen outlinePen, GeoBrush fillBrush, DrawingLevel drawingLevel, float xOffset, float yOffset, PenBrushDrawingOrder penBrushDrawingOrder)

Parameters

screenPoint ScreenPointF

This parameter is the center point in well-known binary format.

width float

This parameter describes the width of the ellipse to be drawn.

height float

This parameter describes the height of the ellipse to be drawn.

outlinePen GeoPen

This parameter describes the outline GeoPen that will be used to draw the point.

fillBrush GeoBrush

This parameter describes the fill GeoBrush that will be used to draw the point.

drawingLevel DrawingLevel

This parameter determines the DrawingLevel that the GeoPen or GeoBrush will draw on.

xOffset float

This parameter determines the X offset for the screenPoint to be drawn.

yOffset float

This parameter determines the Y offset for the screenPoint to be drawn.

penBrushDrawingOrder PenBrushDrawingOrder

This parameter determines the PenBrushDrawingOrder used when drawing the ellipse.

Remarks

This method is used to draw a point on the GeoCanvas. It provides you with a number of overloads that allow you to control how it is drawn. Specify the GeoBrush to fill in the area of the point. Specify the GeoPen to outline the point using that GeoPen. You can also call a overload that will allow you to specify both a GeoPen and a GeoBrush.

The DrawingLevel allows you to specify the level you will draw on when drawing many points.

Exceptions

InvalidOperationException

In the event you attempt to call this method when the GeoCanvas' IsDrawing mode is false, it will throw an InvalidOperationException.

ArgumentException

Passing invalid well-known binary in the pointShapeWkb parameter will throw an ArgumentException.

ArgumentNullException

If you pass a null as the pointShapeWkb, we will throw an ArgumentNullException.

ArgumentNullException

If you pass a null as the outlinePen and a null as the fillBrush, we will throw an ArgumentNullException.

ArgumentOutOfRangeException

If you pass in a drawingLevel that is not defined in the enumeration, it will throw a ArgumentOutOfRangeException.

DrawLine(IEnumerable<ScreenPointF>, GeoPen, DrawingLevel, float, float)

Draws the LineShape on the GeoCanvas.

public void DrawLine(IEnumerable<ScreenPointF> screenPoints, GeoPen linePen, DrawingLevel drawingLevel, float xOffset, float yOffset)

Parameters

screenPoints IEnumerable<ScreenPointF>

This parameter is the LineShape in well-known binary format.

linePen GeoPen

This parameter describes the GeoPen that will be used to draw the LineShape.

drawingLevel DrawingLevel

This parameter determines the DrawingLevel that the GeoPen will draw on.

xOffset float

This parameter determines the X offset for the feature to be drawn.

yOffset float

This parameter determines the Y offset for the feature to be drawn.

Remarks

This method is used to draw a line on the GeoCanvas using the specified GeoPen.

The DrawingLevel allows you to specify the level you will draw on when drawing multiple lines. This is very useful when you want to draw a road, for example. You can draw the black background on the lowest level, then draw a slightly thinner white line on a higher level. This will result in a great effect for a road.

Exceptions

InvalidOperationException

In the event you attempt to call this method when the GeoCanvas' IsDrawing mode is false, it will throw an InvalidOperationException.

ArgumentException

Passing invalid well-known binary in the lineShapeWkb parameter will throw an ArgumentException.

ArgumentNullException

If you pass a null as the lineShapeWkb, we will throw an ArgumentNullException.

ArgumentNullException

If you pass a null as the linePen, we will throw an ArgumentNullException.

ArgumentOutOfRangeException

If you pass in a drawingLevel that is not defined in the enumeration, it will throw a ArgumentOutOfRangeException.

DrawLine(Feature, GeoPen, DrawingLevel)

Draws a line on the GeoCanvas.

public void DrawLine(Feature feature, GeoPen linePen, DrawingLevel drawingLevel)

Parameters

feature Feature

This parameter is the line feature.

linePen GeoPen

This parameter describes the GeoPen that will be used to draw the line.

drawingLevel DrawingLevel

This parameter determines the DrawingLevel that the GeoPen will draw on.

Remarks

This method is used to draw a line on the GeoCanvas using the specified GeoPen.

The DrawingLevel allows you to specify the level you will draw on when drawing multiple lines. This is very useful when you want to draw a road, for example. You can draw the black background on the lowest level, then draw a slightly thinner white line on a higher level. This will result in a great effect for a road.

Exceptions

InvalidOperationException

In the event you attempt to call this method when the GeoCanvas' IsDrawing mode is false, it will throw an InvalidOperationException.

ArgumentException

Passing invalid well-known binary in the lineShapeWkb parameter will throw an ArgumentException.

ArgumentNullException

If you pass a null as the lineShapeWkb, we will throw an ArgumentNullException.

ArgumentNullException

If you pass a null as the linePen, we will throw an ArgumentNullException.

ArgumentOutOfRangeException

If you pass in a drawingLevel that is not defined in the enumeration, it will throw a ArgumentOutOfRangeException.

DrawLine(Feature, GeoPen, DrawingLevel, float, float)

Draws a line on the GeoCanvas.

public void DrawLine(Feature feature, GeoPen linePen, DrawingLevel drawingLevel, float xOffset, float yOffset)

Parameters

feature Feature

This parameter is the line feature to be drawn by GeoCannvas.

linePen GeoPen

This parameter describes the GeoPen that will be used to draw the line.

drawingLevel DrawingLevel

This parameter determines the DrawingLevel that the GeoPen will draw on.

xOffset float

This parameter determines the X offset for the feature to be drawn.

yOffset float

This parameter determines the Y offset for the feature to be drawn.

Remarks

This method is used to draw a line on the GeoCanvas using the specified GeoPen.

The DrawingLevel allows you to specify the level you will draw on when drawing multiple lines. This is very useful when you want to draw a road, for example. You can draw the black background on the lowest level, then draw a slightly thinner white line on a higher level. This will result in a great effect for a road.

Exceptions

InvalidOperationException

In the event you attempt to call this method when the GeoCanvas' IsDrawing mode is false, it will throw an InvalidOperationException.

ArgumentException

Passing invalid well-known binary in the lineShapeWkb parameter will throw an ArgumentException.

ArgumentNullException

If you pass a null as the lineShapeWkb, we will throw an ArgumentNullException.

ArgumentNullException

If you pass a null as the linePen, we will throw an ArgumentNullException.

ArgumentOutOfRangeException

If you pass in a drawingLevel that is not defined in the enumeration, it will throw a ArgumentOutOfRangeException.

DrawLine(LineBaseShape, GeoPen, DrawingLevel)

Draws a line on the GeoCanvas.

public void DrawLine(LineBaseShape shape, GeoPen linePen, DrawingLevel drawingLevel)

Parameters

shape LineBaseShape

This parameter is the line shape to be drawn by GeoCannvas.

linePen GeoPen

This parameter describes the GeoPen that will be used to draw the line.

drawingLevel DrawingLevel

This parameter determines the DrawingLevel that the GeoPen will draw on.

Remarks

This method is used to draw a line on the GeoCanvas using the specified GeoPen.

The DrawingLevel allows you to specify the level you will draw on when drawing multiple lines. This is very useful when you want to draw a road, for example. You can draw the black background on the lowest level, then draw a slightly thinner white line on a higher level. This will result in a great effect for a road.

Exceptions

InvalidOperationException

In the event you attempt to call this method when the GeoCanvas' IsDrawing mode is false, it will throw an InvalidOperationException.

ArgumentException

Passing invalid well-known binary in the lineShapeWkb parameter will throw an ArgumentException.

ArgumentNullException

If you pass a null as the lineShapeWkb, we will throw an ArgumentNullException.

ArgumentNullException

If you pass a null as the linePen, we will throw an ArgumentNullException.

ArgumentOutOfRangeException

If you pass in a drawingLevel that is not defined in the enumeration, it will throw a ArgumentOutOfRangeException.

DrawLine(LineBaseShape, GeoPen, DrawingLevel, float, float)

Draws a line on the GeoCanvas.

public void DrawLine(LineBaseShape shape, GeoPen linePen, DrawingLevel drawingLevel, float xOffset, float yOffset)

Parameters

shape LineBaseShape

This parameter is the line shape to be drawn by GeoCannvas.

linePen GeoPen

This parameter describes the GeoPen that will be used to draw the line.

drawingLevel DrawingLevel

This parameter determines the DrawingLevel that the GeoPen will draw on.

xOffset float

This parameter determines the X offset for the feature to be drawn.

yOffset float

This parameter determines the Y offset for the feature to be drawn.

Remarks

This method is used to draw a line on the GeoCanvas using the specified GeoPen.

The DrawingLevel allows you to specify the level you will draw on when drawing multiple lines. This is very useful when you want to draw a road, for example. You can draw the black background on the lowest level, then draw a slightly thinner white line on a higher level. This will result in a great effect for a road.

Exceptions

InvalidOperationException

In the event you attempt to call this method when the GeoCanvas' IsDrawing mode is false, it will throw an InvalidOperationException.

ArgumentException

Passing invalid well-known binary in the lineShapeWkb parameter will throw an ArgumentException.

ArgumentNullException

If you pass a null as the lineShapeWkb, we will throw an ArgumentNullException.

ArgumentNullException

If you pass a null as the linePen, we will throw an ArgumentNullException.

ArgumentOutOfRangeException

If you pass in a drawingLevel that is not defined in the enumeration, it will throw a ArgumentOutOfRangeException.

DrawLineCore(IEnumerable<ScreenPointF>, GeoPen, DrawingLevel, float, float)

Draws the LineShape on the GeoCanvas.

protected abstract void DrawLineCore(IEnumerable<ScreenPointF> screenPoints, GeoPen linePen, DrawingLevel drawingLevel, float xOffset, float yOffset)

Parameters

screenPoints IEnumerable<ScreenPointF>

This parameter is the LineShape in well-known binary format.

linePen GeoPen

This parameter describes the GeoPen that will be used to draw the LineShape.

drawingLevel DrawingLevel

This parameter determines the DrawingLevel that the GeoPen will draw on.

xOffset float

This parameter determines the X offset for the feature to be drawn.

yOffset float

This parameter determines the Y offset for the feature to be drawn.

Remarks

This method is used to draw a line on the GeoCanvas using the specified GeoPen.

The DrawingLevel allows you to specify the level you will draw on when drawing multiple lines. This is very useful when you want to draw a road, for example. You can draw the black background on the lowest level, then draw a slightly thinner white line on a higher level. This will result in a great effect for a road.

Exceptions

InvalidOperationException

In the event you attempt to call this method when the GeoCanvas' IsDrawing mode is false, it will throw an InvalidOperationException.

ArgumentException

Passing invalid well-known binary in the lineShapeWkb parameter will throw an ArgumentException.

ArgumentNullException

If you pass a null as the lineShapeWkb, we will throw an ArgumentNullException.

ArgumentNullException

If you pass a null as the linePen, we will throw an ArgumentNullException.

ArgumentOutOfRangeException

If you pass in a drawingLevel that is not defined in the enumeration, it will throw a ArgumentOutOfRangeException.

DrawScreenImage(GeoImage, float, float, float, float, DrawingLevel, float, float, float)

Draws a screen image on the GeoCanvas.

public void DrawScreenImage(GeoImage image, float centerXInScreen, float centerYInScreen, float widthInScreen, float heightInScreen, DrawingLevel drawingLevel, float xOffset, float yOffset, float rotateAngle)

Parameters

image GeoImage

The image you want to draw.

centerXInScreen float

The X coordinate of the center point (in screen coordinates) of where you want to draw the image.

centerYInScreen float

The Y coordinate of the center point (in screen coordinates) of where you want to draw the image.

widthInScreen float

The width you want to scale the image to. This is the width of the image that will be drawn.

heightInScreen float

The height you want to scale the image to. This is the height of the image that will be drawn.

drawingLevel DrawingLevel

This parameter determines the DrawingLevel the image will draw on.

xOffset float

This parameter determines the X offset for the image to be drawn.

yOffset float

This parameter determines the Y offset for the image to be drawn.

rotateAngle float

This parameter determines the rotation angle for the image to be drawn.

Remarks

Drawing an image scaled is slower than using the API that draws it unscaled.

Exceptions

InvalidOperationException

In the event you attempt to call this method when the GeoCanvas' IsDrawing mode is false, it will throw an InvalidOperationException.

ArgumentNullException

If you pass a null as the image, we will throw an ArgumentNullException.

ArgumentOutOfRangeException

If you pass in a drawingLevel that is not defined in the enumeration, it will throw a ArgumentOutOfRangeException.

ArgumentOutOfRangeException

If you pass in a widthInScreen that is not greater than 0, it will throw a ArgumentOutOfRangeException.

ArgumentOutOfRangeException

If you pass in a heightInScreen that is not greater than 0, it will throw a ArgumentOutOfRangeException.

DrawScreenImageCore(GeoImage, float, float, float, float, DrawingLevel, float, float, float)

Draws a scaled image on the GeoCanvas.

protected abstract void DrawScreenImageCore(GeoImage image, float centerXInScreen, float centerYInScreen, float widthInScreen, float heightInScreen, DrawingLevel drawingLevel, float xOffset, float yOffset, float rotateAngle)

Parameters

image GeoImage

The image you want to draw.

centerXInScreen float

The X coordinate of the center point (in screen coordinates) of where you want to draw the image.

centerYInScreen float

The Y coordinate of the center point (in screen coordinates) of where you want to draw the image.

widthInScreen float

The width you want to scale the image to. This is the width of the image that will be drawn.

heightInScreen float

The height you want to scale the image to. This is the height of the image that will be drawn.

drawingLevel DrawingLevel

This parameter determines the DrawingLevel the image will draw on.

xOffset float

This parameter determines the X offset for the image to be drawn.

yOffset float

This parameter determines the Y offset for the image to be drawn.

rotateAngle float

This parameter determines the rotation angle for the image to be drawn.

Remarks

Drawing an image scaled is slower than using the API that draws it unscaled.

Exceptions

InvalidOperationException

In the event you attempt to call this method when the GeoCanvas' IsDrawing mode is false, it will throw an InvalidOperationException.

ArgumentNullException

If you pass a null as the image, we will throw an ArgumentNullException.

ArgumentOutOfRangeException

If you pass in a drawingLevel that is not defined in the enumeration, it will throw a ArgumentOutOfRangeException.

ArgumentOutOfRangeException

If you pass in a widthInScreen that is not greater than 0, it will throw a ArgumentOutOfRangeException.

ArgumentOutOfRangeException

If you pass in a heightInScreen that is not greater than 0, it will throw a ArgumentOutOfRangeException.

DrawScreenImageWithoutScaling(GeoImage, float, float, DrawingLevel, float, float, float)

Draws an unscaled image on the GeoCanvas.

public void DrawScreenImageWithoutScaling(GeoImage image, float centerXInScreen, float centerYInScreen, DrawingLevel drawingLevel, float xOffset, float yOffset, float rotateAngle)

Parameters

image GeoImage

The image you want to draw unscaled.

centerXInScreen float

The X coordinate of the center point (in screen coordinates) of where you want to draw the image.

centerYInScreen float

The Y coordinate of the center point (in screen coordinates) of where you want to draw the image.

drawingLevel DrawingLevel

This parameter determines the DrawingLevel the image will draw on.

xOffset float

This parameter determines the X offset for the image to be drawn.

yOffset float

This parameter determines the Y offset for the image to be drawn.

rotateAngle float

This parameter determines the rotation angle for the image to be drawn.

Remarks

Drawing an image unscaled is faster than using the API that scales it.

The X & Y in work coordinates is where the center of the image will be drawn.

Exceptions

InvalidOperationException

In the event you attempt to call this method when the GeoCanvas' IsDrawing mode is false, it will throw an InvalidOperationException.

ArgumentNullException

If you pass a null as the image, we will throw an ArgumentNullException.

ArgumentOutOfRangeException

If you pass in a drawingLevel that is not defined in the enumeration, it will throw a ArgumentOutOfRangeException.

ArgumentException

Passing an invalid image parameter will throw an ArgumentException.

DrawScreenImageWithoutScalingCore(GeoImage, float, float, DrawingLevel, float, float, float)

Draws an unscaled image on the GeoCanvas.

protected abstract void DrawScreenImageWithoutScalingCore(GeoImage image, float centerXInScreen, float centerYInScreen, DrawingLevel drawingLevel, float xOffset, float yOffset, float rotateAngle)

Parameters

image GeoImage

The image you want to draw unscaled.

centerXInScreen float

The X coordinate of the center point (in screen coordinates) of where you want to draw the image.

centerYInScreen float

The Y coordinate of the center point (in screen coordinates) of where you want to draw the image.

drawingLevel DrawingLevel

This parameter determines the DrawingLevel the image will draw on.

xOffset float

This parameter determines the X offset for the image to be drawn.

yOffset float

This parameter determines the Y offset for the image to be drawn.

rotateAngle float

This parameter determines the rotation angle for the image to be drawn.

Remarks

Drawing an image unscaled is faster than using the API that scales it.

Exceptions

InvalidOperationException

In the event you attempt to call this method when the GeoCanvas' IsDrawing mode is false, it will throw an InvalidOperationException.

ArgumentNullException

If you pass a null as the image, we will throw an ArgumentNullException.

ArgumentOutOfRangeException

If you pass in a drawingLevel that is not defined in the enumeration, it will throw a ArgumentOutOfRangeException.

ArgumentException

Passing an invalid image parameter will throw an ArgumentException.

DrawText(string, GeoFont, GeoBrush, IEnumerable<ScreenPointF>, DrawingLevel)

This method allows you to draw text at the specified location, using the specified brush and font parameters.

public void DrawText(string text, GeoFont font, GeoBrush fillBrush, IEnumerable<ScreenPointF> textPathInScreen, DrawingLevel drawingLevel)

Parameters

text string

This parameter specifies the text you wish to draw.

font GeoFont

This parameter represents the font you wish to use to draw the text.

fillBrush GeoBrush

This parameter specifies the kind of fill you want to use to draw the text.

textPathInScreen IEnumerable<ScreenPointF>

This parameter specifies the path on which to draw the text.

drawingLevel DrawingLevel

This parameter specifies the drawing level you wish to draw the text on. Higher levels overwrite lower levels.

Exceptions

InvalidOperationException

In the event you attempt to call this method when the GeoCanvas' IsDrawing mode is false, it will throw an InvalidOperationException.

ArgumentOutOfRangeException

If you pass in a drawingLevel that is not defined in the enumeration, it will throw a ArgumentOutOfRangeException.

ArgumentNullException

If you pass a null as the fillBrush, we will throw an ArgumentNullException.

ArgumentNullException

If you pass a null as the text, we will throw an ArgumentNullException.

ArgumentNullException

If you pass a null as the font, we will throw an ArgumentNullException.

ArgumentException

If you pass a blank string in the text parameter, we will throw an ArgumentException.

DrawText(string, GeoFont, GeoBrush, GeoPen, IEnumerable<ScreenPointF>, DrawingLevel, float, float, DrawingTextAlignment)

Draws the text.

public void DrawText(string text, GeoFont font, GeoBrush fillBrush, GeoPen haloPen, IEnumerable<ScreenPointF> textPathInScreen, DrawingLevel drawingLevel, float xOffset, float yOffset, DrawingTextAlignment drawingTextAlignment)

Parameters

text string

The text.

font GeoFont

The font.

fillBrush GeoBrush

The fill brush.

haloPen GeoPen

The halo pen.

textPathInScreen IEnumerable<ScreenPointF>

The text path in screen.

drawingLevel DrawingLevel

The drawing level.

xOffset float

The x offset.

yOffset float

The y offset.

drawingTextAlignment DrawingTextAlignment

The drawing text alignment.

DrawText(string, GeoFont, GeoBrush, GeoPen, IEnumerable<ScreenPointF>, DrawingLevel, float, float, DrawingTextAlignment, float)

This method allows you to draw text at the specified location, using the specified brush and font parameters.

public void DrawText(string text, GeoFont font, GeoBrush fillBrush, GeoPen haloPen, IEnumerable<ScreenPointF> textPathInScreen, DrawingLevel drawingLevel, float xOffset, float yOffset, DrawingTextAlignment drawingTextAlignment, float rotateAngle)

Parameters

text string

This parameter specifies the text you wish to draw.

font GeoFont

This parameter represents the font you wish to use to draw the text.

fillBrush GeoBrush

This parameter specifies the kind of fill you want to use to draw the text.

haloPen GeoPen

This parameter specifies the HaloPen that will be used to draw the text, when the HaloPen effect is needed.

textPathInScreen IEnumerable<ScreenPointF>

This parameter specifies the path on which to draw the text.

drawingLevel DrawingLevel

This parameter specifies the drawing level you wish to draw the text on. Higher levels overwrite lower levels.

xOffset float

This parameter determines the X offset for the text to be drawn.

yOffset float

This parameter determines the Y offset for the text to be drawn.

drawingTextAlignment DrawingTextAlignment

This parameter determines text alignment for the text to be drawn.

rotateAngle float

This parameter determines the rotation angle for the text to be drawn.

Exceptions

InvalidOperationException

In the event you attempt to call this method when the GeoCanvas' IsDrawing mode is false, it will throw an InvalidOperationException.

ArgumentOutOfRangeException

If you pass in a drawingLevel that is not defined in the enumeration, it will throw a ArgumentOutOfRangeException.

ArgumentNullException

If you pass a null as the fillBrush, we will throw an ArgumentNullException.

ArgumentNullException

If you pass a null as the text, we will throw an ArgumentNullException.

ArgumentNullException

If you pass a null as the font, we will throw an ArgumentNullException.

ArgumentException

If you pass a blank string in the text parameter, we will throw an ArgumentException.

DrawTextCore(string, GeoFont, GeoBrush, GeoPen, IEnumerable<ScreenPointF>, DrawingLevel, float, float, DrawingTextAlignment, float)

This method allows you to draw text at the specified location, using the specified brush and font parameters.

protected abstract void DrawTextCore(string text, GeoFont font, GeoBrush fillBrush, GeoPen haloPen, IEnumerable<ScreenPointF> textPathInScreen, DrawingLevel drawingLevel, float xOffset, float yOffset, DrawingTextAlignment drawingTextAlignment, float rotateAngle)

Parameters

text string

This parameter specifies the text you wish to draw.

font GeoFont

This parameter represents the font you wish to use to draw the text.

fillBrush GeoBrush

This parameter specifies the kind of fill you want to use to draw the text.

haloPen GeoPen

This parameter specifies the HaloPen that will be used to draw the text, when the HaloPen effect is needed.

textPathInScreen IEnumerable<ScreenPointF>

This parameter specifies the path on which to draw the text.

drawingLevel DrawingLevel

This parameter specifies the drawing level you wish to draw the text on. Higher levels overwrite lower levels.

xOffset float

This parameter determines the X offset for the text to be drawn.

yOffset float

This parameter determines the Y offset for the text to be drawn.

drawingTextAlignment DrawingTextAlignment

This parameter determines text alignment for the text to be drawn.

rotateAngle float

This parameter determines the rotation angle for the text to be drawn.

Remarks

This method is used to draw text on the GeoCanvas.

The DrawingLevel allows you to specify the level you will draw on when drawing multiple text items. This is very useful when you want to draw a drop shadow, for example. You can draw the black backdrop on the lowest level with an offset, then draw the normal text on a higher level without an offset.

Exceptions

InvalidOperationException

In the event you attempt to call this method when the GeoCanvas' IsDrawing mode is false, it will throw an InvalidOperationException.

ArgumentOutOfRangeException

If you pass in a drawingLevel that is not defined in the enumeration, it will throw a ArgumentOutOfRangeException.

ArgumentNullException

If you pass a null as the fillBrush, we will throw an ArgumentNullException.

ArgumentNullException

If you pass a null as the text, we will throw an ArgumentNullException.

ArgumentNullException

If you pass a null as the font, we will throw an ArgumentNullException.

ArgumentException

If you pass a blank string in the text parameter, we will throw an ArgumentException.

DrawTextWithScreenCoordinate(string, GeoFont, GeoBrush, float, float, DrawingLevel)

This method allows you to draw text at the specified location, using the specified brush and font parameters.

public void DrawTextWithScreenCoordinate(string text, GeoFont font, GeoBrush fillBrush, float upperLeftXInScreen, float upperLeftYInScreen, DrawingLevel drawingLevel)

Parameters

text string

This parameter specifies the text you wish to draw.

font GeoFont

This parameter represents the font you wish to use to draw the text.

fillBrush GeoBrush

This parameter specifies the kind of fill you want to use to draw the text.

upperLeftXInScreen float

This parameter is the upper left horizontal point in screen coordinates of where you want to start drawing the text from.

upperLeftYInScreen float

This parameter is the upper left vertical point in screen coordinates of where you want to start drawing the text from.

drawingLevel DrawingLevel

This parameter specifies the drawing level you wish to draw the text on. Higher levels overwrite lower levels.

Remarks

This method is used to draw text on the GeoCanvas at specific screen coordinates. It provides you with a number of overloads that allow you to control how the text is drawn. This is useful especially when adding things such as legends, titles, etc.

The DrawingLevel allows you to specify the level you will draw on when drawing multiple text items. This is very useful when you want to draw a drop shadow, for example. You can draw the black backdrop on the lowest level with an offset, then draw the normal text on a higher level without an offset.

Exceptions

InvalidOperationException

In the event you attempt to call this method when the GeoCanvas' IsDrawing mode is false, it will throw an InvalidOperationException.

ArgumentOutOfRangeException

If you pass in a drawingLevel that is not defined in the enumeration, it will throw a ArgumentOutOfRangeException.

ArgumentNullException

If you pass a null as the fillBrush, we will throw an ArgumentNullException.

ArgumentNullException

If you pass a null as the text, we will throw an ArgumentNullException.

ArgumentNullException

If you pass a null as the font, we will throw an ArgumentNullException.

ArgumentException

If you pass a blank string in the text parameter, we will throw an ArgumentException.

DrawTextWithScreenCoordinate(string, GeoFont, GeoBrush, GeoPen, float, float, DrawingLevel)

Draws the text with screen coordinate.

public void DrawTextWithScreenCoordinate(string text, GeoFont font, GeoBrush fillBrush, GeoPen haloPen, float upperLeftXInScreen, float upperLeftYInScreen, DrawingLevel drawingLevel)

Parameters

text string

The text.

font GeoFont

The font.

fillBrush GeoBrush

The fill brush.

haloPen GeoPen

The halo pen.

upperLeftXInScreen float

The upper left x in screen.

upperLeftYInScreen float

The upper left y in screen.

drawingLevel DrawingLevel

The drawing level.

DrawTextWithWorldCoordinate(string, GeoFont, GeoBrush, double, double, DrawingLevel, DrawingTextAlignment)

This method allows you to draw text at the specified location, using the specified brush and font parameters.

public void DrawTextWithWorldCoordinate(string text, GeoFont font, GeoBrush fillBrush, double upperLeftXInWorld, double upperLeftYInWorld, DrawingLevel drawingLevel, DrawingTextAlignment drawingTextAlignment = DrawingTextAlignment.Default)

Parameters

text string

This parameter specifies the text you wish to draw.

font GeoFont

This parameter represents the font you wish to use to draw the text.

fillBrush GeoBrush

This parameter specifies the kind of fill you want to use to draw the text.

upperLeftXInWorld double

This parameter is the upper left horizontal point in world coordinates of where you want to start drawing the text from.

upperLeftYInWorld double

This parameter is the upper left horizontal point in world coordinates of where you want to start drawing the text from.

drawingLevel DrawingLevel

This parameter specifies the drawing level you wish to draw the text on. Higher levels overwrite lower levels.

drawingTextAlignment DrawingTextAlignment

Remarks

This method is used to draw text on the GeoCanvas at specific screen coordinates. It provides you with a number of overloads that allow you to control how the text is drawn. This is useful especially when adding things such as legends, titles, etc.

The DrawingLevel allows you to specify the level you will draw on when drawing multiple text items. This is very useful when you want to draw a drop shadow, for example. You can draw the black backdrop on the lowest level with an offset, then draw the normal text on a higher level without an offset.

Exceptions

InvalidOperationException

In the event you attempt to call this method when the GeoCanvas' IsDrawing mode is false, it will throw an InvalidOperationException.

ArgumentOutOfRangeException

If you pass in a drawingLevel that is not defined in the enumeration, it will throw a ArgumentOutOfRangeException.

ArgumentNullException

If you pass a null as the fillBrush, we will throw an ArgumentNullException.

ArgumentNullException

If you pass a null as the text, we will throw an ArgumentNullException.

ArgumentNullException

If you pass a null as the font, we will throw an ArgumentNullException.

ArgumentException

If you pass a blank string in the text parameter, we will throw an ArgumentException.

DrawTextWithWorldCoordinate(string, GeoFont, GeoBrush, GeoPen, double, double, DrawingLevel, DrawingTextAlignment)

Draws the text with world coordinate.

public void DrawTextWithWorldCoordinate(string text, GeoFont font, GeoBrush fillBrush, GeoPen haloPen, double upperLeftXInWorld, double upperLeftYInWorld, DrawingLevel drawingLevel, DrawingTextAlignment drawingTextAlignment = DrawingTextAlignment.Default)

Parameters

text string

The text.

font GeoFont

The font.

fillBrush GeoBrush

The fill brush.

haloPen GeoPen

The halo pen.

upperLeftXInWorld double

The upper left x in world.

upperLeftYInWorld double

The upper left y in world.

drawingLevel DrawingLevel

The drawing level.

drawingTextAlignment DrawingTextAlignment

DrawWorldImage(GeoImage, double, double, double, DrawingLevel, float, float, float)

Draws a world image on the GeoCanvas.

public void DrawWorldImage(GeoImage image, double centerXInWorld, double centerYInWorld, double imageScale, DrawingLevel drawingLevel, float xOffset, float yOffset, float rotateAngle)

Parameters

image GeoImage

The image you want to draw.

centerXInWorld double

The X coordinate of the center point of where you want to draw the image.

centerYInWorld double

The Y coordinate of the center point of where you want to draw the image.

imageScale double

The scale at which you want to draw the image. The final width and height will be caculated based on the scale.

drawingLevel DrawingLevel

This parameter determines the DrawingLevel the image will draw on.

xOffset float

This parameter determines the X offset for the image to be drawn.

yOffset float

This parameter determines the Y offset for the image to be drawn.

rotateAngle float

This parameter determines the rotation angle for the image to be drawn.

Remarks

Drawing an image scaled is slower than using the API that draws it unscaled.

Exceptions

InvalidOperationException

In the event you attempt to call this method when the GeoCanvas' IsDrawing mode is false, it will throw an InvalidOperationException.

ArgumentNullException

If you pass a null as the image, we will throw an ArgumentNullException.

ArgumentOutOfRangeException

If you pass in a drawingLevel that is not defined in the enumeration, it will throw a ArgumentOutOfRangeException.

ArgumentOutOfRangeException

If you pass in a widthInScreen that is not greater than 0, it will throw a ArgumentOutOfRangeException.

ArgumentOutOfRangeException

If you pass in a heightInScreen that is not greater than 0, it will throw a ArgumentOutOfRangeException.

DrawWorldImage(GeoImage, double, double, float, float, DrawingLevel)

Draws a scaled image on the GeoCanvas.

public void DrawWorldImage(GeoImage image, double centerXInWorld, double centerYInWorld, float widthInScreen, float heightInScreen, DrawingLevel drawingLevel)

Parameters

image GeoImage

The image you want to draw.

centerXInWorld double

The X coordinate of the center point of where you want to draw the image.

centerYInWorld double

The Y coordinate of the center point of where you want to draw the image.

widthInScreen float

The width you want to scale the image to. This is the width of the image that will be drawn.

heightInScreen float

The height you want to scale the image to. This is the height of the image that will be drawn.

drawingLevel DrawingLevel

This parameter determines the DrawingLevel the image will draw on.

Remarks

Drawing an image scaled is slower than using the API that draws it unscaled.

Exceptions

InvalidOperationException

In the event you attempt to call this method when the GeoCanvas' IsDrawing mode is false, it will throw an InvalidOperationException.

ArgumentNullException

If you pass a null as the image, we will throw an ArgumentNullException.

ArgumentOutOfRangeException

If you pass in a drawingLevel that is not defined in the enumeration, it will throw a ArgumentOutOfRangeException.

ArgumentOutOfRangeException

If you pass in a widthInScreen that is not greater than 0, it will throw a ArgumentOutOfRangeException.

ArgumentOutOfRangeException

If you pass in a heightInScreen that is not greater than 0, it will throw a ArgumentOutOfRangeException.

DrawWorldImage(GeoImage, double, double, float, float, DrawingLevel, float, float, float)

Draws a world image on the GeoCanvas.

public void DrawWorldImage(GeoImage image, double centerXInWorld, double centerYInWorld, float widthInScreen, float heightInScreen, DrawingLevel drawingLevel, float xOffset, float yOffset, float rotateAngle)

Parameters

image GeoImage

The image you want to draw.

centerXInWorld double

The X coordinate of the center point of where you want to draw the image.

centerYInWorld double

The Y coordinate of the center point of where you want to draw the image.

widthInScreen float

The width you want to scale the image to. This is the width of the image that will be drawn.

heightInScreen float

The height you want to scale the image to. This is the height of the image that will be drawn.

drawingLevel DrawingLevel

This parameter determines the DrawingLevel the image will draw on.

xOffset float

This parameter determines the X offset for the image to be drawn.

yOffset float

This parameter determines the Y offset for the image to be drawn.

rotateAngle float

This parameter determines the rotation angle for the image to be drawn.

Remarks

Drawing an image scaled is slower than using the API that draws it unscaled.

Exceptions

InvalidOperationException

In the event you attempt to call this method when the GeoCanvas' IsDrawing mode is false, it will throw an InvalidOperationException.

ArgumentNullException

If you pass a null as the image, we will throw an ArgumentNullException.

ArgumentOutOfRangeException

If you pass in a drawingLevel that is not defined in the enumeration, it will throw a ArgumentOutOfRangeException.

ArgumentOutOfRangeException

If you pass in a widthInScreen that is not greater than 0, it will throw a ArgumentOutOfRangeException.

ArgumentOutOfRangeException

If you pass in a heightInScreen that is not greater than 0, it will throw a ArgumentOutOfRangeException.

DrawWorldImageWithoutScaling(GeoImage, double, double, DrawingLevel)

Draws an unscaled image on the GeoCanvas.

public void DrawWorldImageWithoutScaling(GeoImage image, double centerXInWorld, double centerYInWorld, DrawingLevel drawingLevel)

Parameters

image GeoImage

The image you want to draw unscaled.

centerXInWorld double

The X coordinate of the center point of where you want to draw the image.

centerYInWorld double

The Y coordinate of the center point of where you want to draw the image.

drawingLevel DrawingLevel

This parameter determines the DrawingLevel the image will draw on.

Remarks

Drawing an image unscaled is faster than using the API that scales it.

The X & Y in work coordinates is where the center of the image will be drawn.

Exceptions

InvalidOperationException

In the event you attempt to call this method when the GeoCanvas' IsDrawing mode is false, it will throw an InvalidOperationException.

ArgumentNullException

If you pass a null as the image, we will throw an ArgumentNullException.

ArgumentOutOfRangeException

If you pass in a drawingLevel that is not defined in the enumeration, it will throw a ArgumentOutOfRangeException.

ArgumentException

Passing an invalid image parameter will throw an ArgumentException.

DrawWorldImageWithoutScaling(GeoImage, double, double, DrawingLevel, float, float, float)

Draws an unscaled image on the GeoCanvas.

public void DrawWorldImageWithoutScaling(GeoImage image, double centerXInWorld, double centerYInWorld, DrawingLevel drawingLevel, float xOffset, float yOffset, float rotateAngle)

Parameters

image GeoImage

The image you want to draw unscaled.

centerXInWorld double

The X coordinate of the center point (in world coordinates) of where you want to draw the image.

centerYInWorld double

The Y coordinate of the center point (in world coordinates) of where you want to draw the image.

drawingLevel DrawingLevel

This parameter determines the DrawingLevel the image will draw on.

xOffset float

This parameter determines the X offset for the image to be drawn.

yOffset float

This parameter determines the Y offset for the image to be drawn.

rotateAngle float

This parameter determines the rotation angle for the image to be drawn.

Remarks

Drawing an image unscaled is faster than using the API that scales it.

The X & Y in work coordinates is where the center of the image will be drawn.

Exceptions

InvalidOperationException

In the event you attempt to call this method when the GeoCanvas' IsDrawing mode is false, it will throw an InvalidOperationException.

ArgumentNullException

If you pass a null as the image, we will throw an ArgumentNullException.

ArgumentOutOfRangeException

If you pass in a drawingLevel that is not defined in the enumeration, it will throw a ArgumentOutOfRangeException.

ArgumentException

Passing an invalid image parameter will throw an ArgumentException.

EndDrawing()

This method ends drawing and commits the drawing on the GeoCanvas.

public void EndDrawing()

Remarks

This method should be called when you are finished drawing. It will commit the image changes to the image you passed in on BeginDrawing. It will also set IsDrawing to false. After you call this method it will put the GeoCanvas into an invalid state, so if you then call any drawing methods it will raise an exception.

EndDrawingCore()

This method ends drawing and commits the drawing on the GeoCanvas.

protected abstract void EndDrawingCore()

Remarks

This methods should be called when you are finished drawing. It will commit the image changes to the image you passed in on BeginDrawing. It will also set IsDrawing to false. After you call this method it will put the GeoCanvas into an invalid state, so if you then call any drawing methods it will raise an exception.

Flush()

This method flush drawing and commits the drawing on the GeoCanvas.

public void Flush()

Remarks

This method should be called when you are finished drawing. It will commit the image changes to the image you passed in on BeginDrawing. It will also set IsDrawing to false. After you call this method it will put the GeoCanvas into an invalid state, so if you then call any drawing methods it will raise an exception.

FlushCore()

This method flush drawing and commits the drawing on the GeoCanvas.

protected abstract void FlushCore()

Remarks

This method should be called when you are finished drawing. It will commit the image changes to the image you passed in on BeginDrawing. It will also set IsDrawing to false. After you call this method it will put the GeoCanvas into an invalid state, so if you then call any drawing methods it will raise an exception.

GetCanvasHeight()

This method gets the view height of the passed-in native image object.

protected float GetCanvasHeight()

Returns

float

The returning view height.

Remarks

This method is a BaseClass API and will be implemented and used in its sub-concrete classes.

GetCanvasHeightCore()

This method gets the view height of the passed-in native image object.

protected abstract float GetCanvasHeightCore()

Returns

float

The returning view height.

Remarks

This method is a BaseClass API and will be implemented and used in its sub-concrete classes.

GetCanvasWidth()

This method gets the view width of the passed-in native image object.

protected float GetCanvasWidth()

Returns

float

The returning view width.

Remarks

This method is a BaseClass API and will be implemented and used in its sub-concrete classes.

GetCanvasWidthCore()

This method gets the view width of the passed-in native image object.

protected abstract float GetCanvasWidthCore()

Returns

float

The returning view width.

Remarks

This method is a BaseClass API and will be implemented and used in its sub-concrete classes.

MeasureOffset(double)

public double MeasureOffset(double offsetInPixel)

Parameters

offsetInPixel double

Returns

double

MeasureOffsetCore(double)

protected virtual double MeasureOffsetCore(double offsetInPixel)

Parameters

offsetInPixel double

Returns

double

MeasureText(string, GeoFont)

This method returns the rectangle that contains the specified text, when that text is drawn with the specified font.

public DrawingRectangleF MeasureText(string text, GeoFont font)

Parameters

text string

This parameter represents the text you want to measure.

font GeoFont

This parameter represents the font of the text you want to measure.

Returns

DrawingRectangleF

This method returns the rectangle that contains the specified text, when that text is drawn with the specified font.

Remarks

This method is typically used for labeling, to determine whether labels overlap.

Exceptions

ArgumentNullException

If you pass a null as the text, we will throw an ArgumentNullException.

ArgumentNullException

If you pass a null as the font, we will throw an ArgumentNullException.

ArgumentException

If you pass a blank string in the text parameter, we will throw an ArgumentException.

MeasureTextCore(string, GeoFont)

This method returns the rectangle that contains the specified text, when that text is drawn with the specified font.

protected abstract DrawingRectangleF MeasureTextCore(string text, GeoFont font)

Parameters

text string

This parameter represents the text you want to measure.

font GeoFont

This parameter represents the font of the text you want to measure.

Returns

DrawingRectangleF

This method returns the rectangle that contains the specified text, when that text is drawn with the specified font.

Remarks

This method is typically used for labeling, to determine whether labels overlap.

Exceptions

ArgumentNullException

If you pass a null as the text, we will throw an ArgumentNullException.

ArgumentNullException

If you pass a null as the font, we will throw an ArgumentNullException.

ArgumentException

If you pass a blank string in the text parameter, we will throw an ArgumentException.

OnDrawingProgressChanged(DrawingProgressChangedEventArgs)

Raises the DrawingProgressChanged event.

protected virtual void OnDrawingProgressChanged(DrawingProgressChangedEventArgs e)

Parameters

e DrawingProgressChangedEventArgs

The DrawingProgressChangedEventArgs instance containing the event data.

Events

DrawingProgressChanged

Occurs when [drawing progress changed].

public event EventHandler<DrawingProgressChangedEventArgs> DrawingProgressChanged

Event Type

EventHandler<DrawingProgressChangedEventArgs>