ICanvasTile

Interface for tiles that can be displayed in the canvas object's 2d context.

Constructor | Fields | Events | Methods

Constructor

ICanvasTile(url)

Parameters:

Parameter Default value Description
url *

Type: String

Tile URL.

* Mandatory parameter/option.

Fields

Name Type Description
events IEventManager

Tile event manager.

Events

Name Description
ready

Tile ready event.

Methods

Name Returns Description
destroy()

Destroys the tile.

isReady()

Boolean

Checks tile readiness.

renderAt(context, canvasSize, bounds[, animate])

Draws an image tile in the canvas object's 2d context.

Fields details

events

{IEventManager} events

Tile event manager.

Events details

ready

Tile ready event.

Methods details

destroy

{} destroy()

Destroys the tile.

isReady

{Boolean} isReady()

Checks tile readiness.

Returns true if the tile is ready, or false if it is not ready.

renderAt

{} renderAt(context, canvasSize, bounds[, animate])

Draws an image tile in the canvas object's 2d context.

Parameters:

Parameter Default value Description
context *

Type: Object

2D context of the canvas object.

canvasSize *

Type: Number[]

Dimensions of the canvas HTML element.

bounds *

Type: Number[][]

Area in client coordinates where the tile should be drawn.

animate false

Type: Boolean

If true, rendering is animated; if false, it is not.

* Mandatory parameter/option.