search

goog.graphics.CanvasTextElement

Provided By
Extends
All Implemented Interfaces

Thin wrapper for canvas text elements. This is an implementation of the goog.graphics.TextElement interface. You should not construct objects from this constructor. The graphics will return the object for you.

new CanvasTextElement( graphics, text, x1, y1, x2, y2, align, font, stroke, fill )

Parameters
graphicsgoog.graphics.CanvasGraphics

The graphics creating this element.

textstring

The text to draw.

x1number

X coordinate of start of line.

y1number

Y coordinate of start of line.

x2number

X coordinate of end of line.

y2number

Y coordinate of end of line.

align(string|null)

Horizontal alignment: left (default), center, right.

fontgoog.graphics.Font

Font describing the font properties.

stroke(goog.graphics.Stroke|null)

The stroke to use for this element.

fill(goog.graphics.Fill|null)

The fill to use for this element.

Instance Methods

Instance Properties