Class Index | File Index

Classes


Class fabric.Text


Extends fabric.Object.
Text
Defined in: text.class.js.

Class Summary
Constructor Attributes Constructor Name and Description
 
Field Summary
Field Attributes Field Name and Description
 
 
Fields borrowed from class fabric.Object:
FX_DURATION, FX_TRANSITION, includeDefaultValues, MIN_SCALE_LIMIT, NUM_FRACTION_DIGITS, rotate, stateProperties
Method Summary
Method Attributes Method Name and Description
<static>  
fabric.Text.fromElement(element)
<static>  
fabric.Text.fromObject(object)
Returns fabric.Text instance from an object representation
 
 
initialize(text, options)
Constructor
 
 
render(ctx)
 
set(name, value)
Sets specified property to a specified value
 
setColor(value)
 
setFontsize(value)
 
setText(value)
Sets text of an instance, and updates its coordinates
 
 
Returns string representation of an instance
Methods borrowed from class fabric.Object:
callSuper, clone, cloneAsImage, complexity, drawBorders, drawCorners, fxRemove, fxStraighten, get, getAngle, getCenter, getHeight, getWidth, hasStateChanged, intersectsWithObject, intersectsWithRect, isActive, isContainedWithinRect, isType, saveState, scale, scaleToHeight, scaleToWidth, setActive, setAngle, setCoords, setOpacity, setOptions, setSourcePath, straighten, toDatalessObject, toDataURL, toggle, toGrayscale, toJSON, transform
Class Detail
fabric.Text()
Field Detail
{Object} options

{String} type
Method Detail
<static> {fabric.Text} fabric.Text.fromElement(element)
Parameters:
element
Returns:
{fabric.Text} an instance

<static> {fabric.Text} fabric.Text.fromObject(object)
Returns fabric.Text instance from an object representation
Parameters:
{Object} object
to create an instance from
Returns:
{fabric.Text} an instance

{String} getText()
Returns:
{String}

{fabric.Text} initialize(text, options)
Constructor
Parameters:
{String} text
{Object} options Optional
Returns:
{fabric.Text} thisArg

initStateProperties()

render(ctx)
Parameters:
ctx
{CanvasRenderingContext2D} context to render on

{fabric.Text} set(name, value)
Sets specified property to a specified value
Parameters:
{String} name
{Any} value
Returns:
{fabric.Text} thisArg

{fabric.Text} setColor(value)
Parameters:
{String} value
Returns:
{fabric.Text} thisArg

{fabric.Text} setFontsize(value)
Parameters:
{Number} value
Returns:
{fabric.Text} thisArg

{fabric.Text} setText(value)
Sets text of an instance, and updates its coordinates
Parameters:
{String} value
Returns:
{fabric.Text} thisArg

{Object} toObject()
Returns:
{Object} Object representation of text object

{String} toString()
Returns string representation of an instance
Returns:
{String} String representation of text object

Documentation generated by JsDoc Toolkit 2.4.0 on Thu Oct 14 2010 21:41:43 GMT-0400 (EDT)