UNPKG

evolve-js

Version:

EvolveJS An Elements framework built over CreateJS

32 lines (25 loc) 34 kB
<html> <head> </head> <body style="background: transparent;"> <script src="scripts/docstrap.lib.js"></script> <script src="scripts/lunr.min.js"></script> <script src="scripts/fulltext-search.js"></script> <script type="text/x-docstrap-searchdb"> {"modules.list.html":{"id":"modules.list.html","title":"Modules","body":" EvolveJS Modules Elements Classes BoxElementButtonElementElementHelpersImageElementLabelElementListElementListItemElementPreloaderSpriteElementTextElement Modules Classes BoxElement ButtonElement Element Helpers ImageElement LabelElement ListElement ListItemElement Preloader SpriteElement TextElement × Search results Close "},"classes.list.html":{"id":"classes.list.html","title":"Classes","body":" EvolveJS Modules Elements Classes BoxElementButtonElementElementHelpersImageElementLabelElementListElementListItemElementPreloaderSpriteElementTextElement Classes Classes BoxElement ButtonElement Element Helpers ImageElement LabelElement ListElement ListItemElement Preloader SpriteElement TextElement × Search results Close "},"index.html":{"id":"index.html","title":"Index","body":" EvolveJS Modules Elements Classes BoxElementButtonElementElementHelpersImageElementLabelElementListElementListItemElementPreloaderSpriteElementTextElement evolve-jsv0.1.21 An Elements framework built over CreateJS Getting StartedGetting Started Description Requirements Requirement How To Install Node.js/NPM nodejs.org Webpack npm i -g webpack Babel CLI npm i -g babel-cli Babel ES2015/UMD npm i -g babel-plugin-transform-es2015-modules-umd Brunch Preset Env npm i -g babel-preset-env Brunch Preset ES2015 npm i -g babel-preset-es2015 Documentation Build Requirements (JSDoc) Requirement How To Install JSDoc npm i -g jsdoc Ink-DocStrap npm i -g ink-docstrap × Search results Close "},"BoxElement.html":{"id":"BoxElement.html","title":"Class: BoxElement","body":" EvolveJS Modules Elements Classes BoxElementButtonElementElementHelpersImageElementLabelElementListElementListItemElementPreloaderSpriteElementTextElement Class: BoxElement BoxElement Box Element class, useful to create boxes with a title options (LabelElement) new BoxElement(options) constructs a BoxElement instance Parameters: Name Type Description options Object the options object to be merged with defaults Extends Element Methods align(parentElement, mode) Aligns the Element instance, based on it's parent bounds or specified parentElement bounds and mode parameter Parameters: Name Type Description parentElement Object | null if null, it considers the actual Element instance parent, otherwise it aligns in base of the specified parentElement mode String can be a set of one or two strings (blank separated) in any order, for horizontalModes (left, center, right), for verticalModes (top, middle, bottom) Inherited From: Element#align Returns: to make chainable the method Type Element bindEvents() binds all events specified in the settings object for the Element instance, it supports all DrawJS classes events (eg. click, mouseover, etc...) Inherited From: Element#bindEvents draw() draws all graphic elements of the Element instance Inherited From: Element#draw drawElements() drawElements method implementation getComputedBounds() returns the actual computed bounds of the Element instance, including scale factor and top, right, bottom, left coordinates Inherited From: Element#getComputedBounds Returns: the actual Element instance computed bounds object { { top: number, right: number, bottom: number, left: number, x: number, y: number, width: number, height: number } } Type Object getContentElement() gets the content Element instance Returns: the instance used to draw the content element Type Element getTitleElement() gets the title LabelElement instance Returns: the instance used to draw the title Type LabelElement init() empty init method, to be overriden in classes that extends Element, to use for all those initializations you might need after having rendered the Element Inherited From: Element#init initData() initializes data object for the Element instance Inherited From: Element#initData initDefaults() Initialize default settings for Box Element Overrides: Element#initDefaults initSettings(options) initializes settings object for the Element instance Parameters: Name Type Description options Object the options object to be merged with defaults Inherited From: Element#initSettings setCache(cacheOptions, force) sets or updates the Cache of the Element instance Parameters: Name Type Description cacheOptions Object | Shadow .. force Boolean .... Inherited From: Element#setCache Returns: to make chainable the method Type Element setComputedBounds(boundsOptions) sets or updates the bounds of the Element instance Parameters: Name Type Description boundsOptions Object | Number ... Inherited From: Element#setComputedBounds Returns: to make chainable the method Type Element setMask(maskOptions, force) sets or updates the Mask of the Element instance Parameters: Name Type Description maskOptions Object | Shadow can be an object with {color, x, y, blur}or directly an instance of Shadow (DrawJS) force Boolean .... Inherited From: Element#setMask Returns: to make chainable the method Type Element setPosition( [positionOptions] [, override] [, force]) sets or updates the position of the Element instance Parameters: Name Type Argument Default Description positionOptions Object &lt;optional&gt; null can contain x and y or only one or them Properties Name Type Argument Default Description x Number &lt;optional&gt; 0 the x position y Number &lt;optional&gt; 0 the y position override Boolean &lt;optional&gt; false specify to override actual Element position force Boolean &lt;optional&gt; true ... Inherited From: Element#setPosition Returns: to make chainable the method Type Element setReg() sets to center/middle the regPoint of the Element instance Inherited From: Element#setReg setScale(scaleOptions) sets or updates the scaling of the Element instance Parameters: Name Type Description scaleOptions Object | Number can be an object with x and y couple or only a number to be used for both Inherited From: Element#setScale Overrides: Element#setScale Returns: to make chainable the method Type Element setShadow(shadowOptions, force) sets or updates the Shadow of the Element instance Parameters: Name Type Description shadowOptions Object | Shadow can be an object with {color, x, y, blur}or directly an instance of Shadow (DrawJS) force Boolean .... Inherited From: Element#setShadow Returns: to make chainable the method Type Element × Search results Close "},"ButtonElement.html":{"id":"ButtonElement.html","title":"Class: ButtonElement","body":" EvolveJS Modules Elements Classes BoxElementButtonElementElementHelpersImageElementLabelElementListElementListItemElementPreloaderSpriteElementTextElement Class: ButtonElement ButtonElement Button Element class, extending LabelElement with a click event handler new ButtonElement(options) constructs a ButtonElement instance Parameters: Name Type Description options Object the options object to be merged with defaults Extends LabelElement Methods alignText(mode) aligns the text inside the LabelElement container Parameters: Name Type Description mode String can be a couple of word for horizontal or vertical align, in any order accepts the following modes Horizontal Modes: left, center, right Vertical Modes: top, middle, bottom Inherited From: LabelElement#alignText Returns: Type LabelElement centerText() centers the text inside LabelElement container Inherited From: LabelElement#centerText computeBounds() compute bounds before drawing all graphic elements of LabelElement instance Inherited From: LabelElement#computeBounds initDefaults() Initialize default settings for Button Element Overrides: LabelElement#initDefaults initDefaults() Initialize default settings for Button Element Overrides: LabelElement#initDefaults × Search results Close "},"Element.html":{"id":"Element.html","title":"Class: Element","body":" EvolveJS Modules Elements Classes BoxElementButtonElementElementHelpersImageElementLabelElementListElementListItemElementPreloaderSpriteElementTextElement Class: Element Element Element Class //* @extends Container new Element(options) constructs an Element instance Parameters: Name Type Description options Object the options object to be merged with defaults Methods align(parentElement, mode) Aligns the Element instance, based on it's parent bounds or specified parentElement bounds and mode parameter Parameters: Name Type Description parentElement Object | null if null, it considers the actual Element instance parent, otherwise it aligns in base of the specified parentElement mode String can be a set of one or two strings (blank separated) in any order, for horizontalModes (left, center, right), for verticalModes (top, middle, bottom) Returns: to make chainable the method Type Element bindEvents() binds all events specified in the settings object for the Element instance, it supports all DrawJS classes events (eg. click, mouseover, etc...) draw() draws all graphic elements of the Element instance getComputedBounds() returns the actual computed bounds of the Element instance, including scale factor and top, right, bottom, left coordinates Returns: the actual Element instance computed bounds object { { top: number, right: number, bottom: number, left: number, x: number, y: number, width: number, height: number } } Type Object init() empty init method, to be overriden in classes that extends Element, to use for all those initializations you might need after having rendered the Element initData() initializes data object for the Element instance initDefaults(defaults) initializes default settings for Element instance Parameters: Name Type Description defaults Object the defaults object for Element instance initSettings(options) initializes settings object for the Element instance Parameters: Name Type Description options Object the options object to be merged with defaults setCache(cacheOptions, force) sets or updates the Cache of the Element instance Parameters: Name Type Description cacheOptions Object | Shadow .. force Boolean .... Returns: to make chainable the method Type Element setComputedBounds(boundsOptions) sets or updates the bounds of the Element instance Parameters: Name Type Description boundsOptions Object | Number ... Returns: to make chainable the method Type Element setMask(maskOptions, force) sets or updates the Mask of the Element instance Parameters: Name Type Description maskOptions Object | Shadow can be an object with {color, x, y, blur}or directly an instance of Shadow (DrawJS) force Boolean .... Returns: to make chainable the method Type Element setPosition( [positionOptions] [, override] [, force]) sets or updates the position of the Element instance Parameters: Name Type Argument Default Description positionOptions Object &lt;optional&gt; null can contain x and y or only one or them Properties Name Type Argument Default Description x Number &lt;optional&gt; 0 the x position y Number &lt;optional&gt; 0 the y position override Boolean &lt;optional&gt; false specify to override actual Element position force Boolean &lt;optional&gt; true ... Returns: to make chainable the method Type Element setReg() sets to center/middle the regPoint of the Element instance setScale(scaleOptions) sets or updates the scaling of the Element instance Parameters: Name Type Description scaleOptions Object | Number can be an object with x and y couple or only a number to be used for both Returns: to make chainable the method Type Element setScale(scaleOptions) sets or updates the scaling of the Element instance Parameters: Name Type Description scaleOptions Object | Number can be an object with x and y couple or only a number to be used for both Returns: to make chainable the method Type Element setScale(scaleOptions) sets or updates the scaling of the Element instance Parameters: Name Type Description scaleOptions Object | Number can be an object with x and y couple or only a number to be used for both Returns: to make chainable the method Type Element setShadow(shadowOptions, force) sets or updates the Shadow of the Element instance Parameters: Name Type Description shadowOptions Object | Shadow can be an object with {color, x, y, blur}or directly an instance of Shadow (DrawJS) force Boolean .... Returns: to make chainable the method Type Element × Search results Close "},"Helpers.html":{"id":"Helpers.html","title":"Class: Helpers","body":" EvolveJS Modules Elements Classes BoxElementButtonElementElementHelpersImageElementLabelElementListElementListItemElementPreloaderSpriteElementTextElement Class: Helpers Helpers all the helpers we need to draw the elements new Helpers() Methods &lt;static&gt; align(element, parent, mode, regPoint, regPointMode) Aligns an element (horizontally, vertically or both) based on it's parent bounds. Parameters: Name Type Description element Object | Container | Element can be an Object, an DrawJS instance, a CreateJS Core Elements instance parent null | Object | Container | Element can be an Object, an DrawJS instance, a CreateJS Core Elements instance if null, it takes automatically the parent property of element parameter mode String can be a couple of word for horizontal or vertical align, in any order accepts the following modes Horizontal Modes: left, center, right Vertical Modes: top, middle, bottom regPoint Boolean enabled alignment also on registration point regPointMode null | String can be a couple of word for horizontal or vertical align, in any order accepts the following modes Horizontal Modes: left, center, right Vertical Modes: top, middle, bottom if null it considers mode parameter as fallback Returns: Type Object | Container | Element &lt;static&gt; alignRegPoint(element, mode) aligns the reg point or an element Parameters: Name Type Description element Object | Container | Element can be an Object, an DrawJS instance, a CreateJS Core Elements instance mode String can be a couple of word for horizontal or vertical align, in any order accepts the following modes Horizontal Modes: left, center, right Vertical Modes: top, middle, bottom Returns: Type Object | Container | Element &lt;static&gt; createCircle(options, bounds) creates an DrawJS Circle Shape instance Parameters: Name Type Description options Object the options can contain Properties Name Type Description fill String | Object color for filling graphics Properties Name Type Description colors Array colors to create a linear gradient fill ratios Array color ratios to create a linear gradient fill points Array start &amp; stop points to create a linear gradient fill stroke String | Object stroke options, if string it creates a stroke with size 1 Properties Name Type Description size Number the size color String the color radius Number the radius of the circle bounds Arguments the bounds parameter will be passed to setBounds method of DrawJS Container class so it has to be an array with this sequence {Number} x {Number} y {Number} width {Number} height Returns: Type Shape &lt;static&gt; createContainer(bounds) creates an DrawJS Container instance based on bounds parameters Parameters: Name Type Description bounds Arguments the bounds parameter will be passed to setBounds method of DrawJS Container class so it has to be an array with this sequence {Number} x {Number} y {Number} width {Number} height Returns: Type Container &lt;static&gt; createGraphics(options, bounds) creates an DrawJS Graphics instance Parameters: Name Type Description options Object the options can contain Properties Name Type Description fill String | Object color for filling graphics Properties Name Type Description colors Array colors to create a linear gradient fill ratios Array color ratios to create a linear gradient fill points Array start &amp; stop points to create a linear gradient fill stroke String | Object stroke options, if string it creates a stroke with size 1 Properties Name Type Description size Number the size color String the color bounds Arguments the bounds parameter will be passed to setBounds method of DrawJS Container class so it has to be an array with this sequence {Number} x {Number} y {Number} width {Number} height Returns: Type Graphics &lt;static&gt; createImage(image) creates an DrawJS Bitmap instance Parameters: Name Type Description image HTMLElement the preloaded DOM element representing the image Returns: Type Bitmap &lt;static&gt; createRect(options, bounds) creates an DrawJS Rect Shape instance Parameters: Name Type Description options Object the options can contain Properties Name Type Description fill String | Object color for filling graphics Properties Name Type Description colors Array colors to create a linear gradient fill ratios Array color ratios to create a linear gradient fill points Array start &amp; stop points to create a linear gradient fill stroke String | Object stroke options, if string it creates a stroke with size 1 Properties Name Type Description size Number the size color String the color radius Boolean | Number | Array if false it draws a rect if Number it draws a round rect if Array it draws a round rect complex (array has to respect the arguments sequence of drawRoundRectComplex method of DrawJS Graphics class bounds Arguments the bounds parameter will be passed to setBounds method of DrawJS Container class so it has to be an array with this sequence {Number} x {Number} y {Number} width {Number} height Returns: Type Shape &lt;static&gt; createSprite(spritesheet) creates an DrawJS Sprite instance Parameters: Name Type Description spritesheet HTMLElement the preloaded DOM element representing the sprite Returns: Type Sprite &lt;static&gt; createText(text, font, color) creates an DrawJS Text instance Parameters: Name Type Description text String the text to be rendered font String font options as expected by the DrawJS Text class color String the color of the text Returns: Type Text &lt;static&gt; scale(element, scale) sets the scale factor of an DrawJS element Parameters: Name Type Description element Object | Container | Element can be an Object, an DrawJS instance, a CreateJS Core Elements instance scale Number | Object the scale factor to be used for both scaleX and scaleY Returns: Type Object | Container | Element &lt;static&gt; setBoxSize(element, width, height, css) sets the box size of an DrawJS element Parameters: Name Type Description element Object | Container | Element can be an Object, an DrawJS instance, a CreateJS Core Elements instance width Number the width height Number the height css Boolean specity if you want to override also the css box size properties Returns: Type Object | Container | Element × Search results Close "},"ImageElement.html":{"id":"ImageElement.html","title":"Class: ImageElement","body":" EvolveJS Modules Elements Classes BoxElementButtonElementElementHelpersImageElementLabelElementListElementListItemElementPreloaderSpriteElementTextElement Class: ImageElement ImageElement ImageElement class, extending Element new ImageElement(options) constructs an ImageElement instance Parameters: Name Type Description options Object the options object to be merged with defaults Extends Element Methods align(parentElement, mode) Aligns the Element instance, based on it's parent bounds or specified parentElement bounds and mode parameter Parameters: Name Type Description parentElement Object | null if null, it considers the actual Element instance parent, otherwise it aligns in base of the specified parentElement mode String can be a set of one or two strings (blank separated) in any order, for horizontalModes (left, center, right), for verticalModes (top, middle, bottom) Inherited From: Element#align Returns: to make chainable the method Type Element bindEvents() binds all events specified in the settings object for the Element instance, it supports all DrawJS classes events (eg. click, mouseover, etc...) Inherited From: Element#bindEvents draw() draws all graphic elements of the Element instance Inherited From: Element#draw drawElements() draws all graphic elements of the ImageElement instance getComputedBounds() returns the actual computed bounds of the Element instance, including scale factor and top, right, bottom, left coordinates Inherited From: Element#getComputedBounds Returns: the actual Element instance computed bounds object { { top: number, right: number, bottom: number, left: number, x: number, y: number, width: number, height: number } } Type Object init() empty init method, to be overriden in classes that extends Element, to use for all those initializations you might need after having rendered the Element Inherited From: Element#init initData() initializes data object for the Element instance Inherited From: Element#initData initDefaults() Initialize default settings for ImageElement Overrides: Element#initDefaults initSettings(options) initializes settings object for the Element instance Parameters: Name Type Description options Object the options object to be merged with defaults Inherited From: Element#initSettings setCache(cacheOptions, force) sets or updates the Cache of the Element instance Parameters: Name Type Description cacheOptions Object | Shadow .. force Boolean .... Inherited From: Element#setCache Returns: to make chainable the method Type Element setComputedBounds(boundsOptions) sets or updates the bounds of the Element instance Parameters: Name Type Description boundsOptions Object | Number ... Inherited From: Element#setComputedBounds Returns: to make chainable the method Type Element setMask(maskOptions, force) sets or updates the Mask of the Element instance Parameters: Name Type Description maskOptions Object | Shadow can be an object with {color, x, y, blur}or directly an instance of Shadow (DrawJS) force Boolean .... Inherited From: Element#setMask Returns: to make chainable the method Type Element setPosition( [positionOptions] [, override] [, force]) sets or updates the position of the Element instance Parameters: Name Type Argument Default Description positionOptions Object &lt;optional&gt; null can contain x and y or only one or them Properties Name Type Argument Default Description x Number &lt;optional&gt; 0 the x position y Number &lt;optional&gt; 0 the y position override Boolean &lt;optional&gt; false specify to override actual Element position force Boolean &lt;optional&gt; true ... Inherited From: Element#setPosition Returns: to make chainable the method Type Element setReg() sets to center/middle the regPoint of the Element instance Inherited From: Element#setReg setScale(scaleOptions) sets or updates the scaling of the Element instance Parameters: Name Type Description scaleOptions Object | Number can be an object with x and y couple or only a number to be used for both Inherited From: Element#setScale Overrides: Element#setScale Returns: to make chainable the method Type Element setShadow(shadowOptions, force) sets or updates the Shadow of the Element instance Parameters: Name Type Description shadowOptions Object | Shadow can be an object with {color, x, y, blur}or directly an instance of Shadow (DrawJS) force Boolean .... Inherited From: Element#setShadow Returns: to make chainable the method Type Element × Search results Close "},"LabelElement.html":{"id":"LabelElement.html","title":"Class: LabelElement","body":" EvolveJS Modules Elements Classes BoxElementButtonElementElementHelpersImageElementLabelElementListElementListItemElementPreloaderSpriteElementTextElement Class: LabelElement LabelElement the LabelElement class extends TextElement, implementing padding, minWidth, etc etc ... new LabelElement(options) constructs a LabelElement instance Parameters: Name Type Description options Object the options to be merged with defaults settings Methods alignText(mode) aligns the text inside the LabelElement container Parameters: Name Type Description mode String can be a couple of word for horizontal or vertical align, in any order accepts the following modes Horizontal Modes: left, center, right Vertical Modes: top, middle, bottom Returns: Type LabelElement centerText() centers the text inside LabelElement container computeBounds() compute bounds before drawing all graphic elements of LabelElement instance initDefaults(defaults) Initialize default settings for Label Element Parameters: Name Type Description defaults Object the defaults settings × Search results Close "},"ListElement.html":{"id":"ListElement.html","title":"Class: ListElement","body":" EvolveJS Modules Elements Classes BoxElementButtonElementElementHelpersImageElementLabelElementListElementListItemElementPreloaderSpriteElementTextElement Class: ListElement ListElement the ListElement class allows to create a list of any type of elements new ListElement(options) constructs a ListElement instance Parameters: Name Type Description options Object the options to be merged with defaults settings Methods computeBounds() compute bounds before drawing all graphic elements of ListElement instance drawElements() draws all graphic elements of the ListElement instance, cycles the items, draw them and computes positions initData() initializes data object for the ListElement instance initDefaults() Initialize default settings for List Element × Search results Close "},"ListItemElement.html":{"id":"ListItemElement.html","title":"Class: ListItemElement","body":" EvolveJS Modules Elements Classes BoxElementButtonElementElementHelpersImageElementLabelElementListElementListItemElementPreloaderSpriteElementTextElement Class: ListItemElement ListItemElement the ListItemElement extends ButtonElement allowing you to add a list item indicator and a text, with a click event handler new ListItemElement(options) constructs a ListItemElement instance Parameters: Name Type Description options Object the options object to be merged with defaults Methods drawElements() draws all graphic elements of the ListItemElement instance initDefaults() Initialize default settings for ListItemElement instance × Search results Close "},"module-Elements.html":{"id":"module-Elements.html","title":"Module: Elements","body":" EvolveJS Modules Elements Classes BoxElementButtonElementElementHelpersImageElementLabelElementListElementListItemElementPreloaderSpriteElementTextElement Module: Elements The Elements module of CreateJS Core Framework Properties: Name Type Description Helpers Helpers all the helpers we need to draw the elements StageElement StageElement Element Element TextElement TextElement LabelElement LabelElement ButtonElement ButtonElement ListItemElement ListItemElement ListElement ListElement ImageElement ImageElement SpriteElement SpriteElement BoxElement BoxElement × Search results Close "},"Preloader.html":{"id":"Preloader.html","title":"Class: Preloader","body":" EvolveJS Modules Elements Classes BoxElementButtonElementElementHelpersImageElementLabelElementListElementListItemElementPreloaderSpriteElementTextElement Class: Preloader Preloader the game preload class used for loading content new Preloader() constructs the preloader and returns a promise Methods init(resolve) sets up game loader. Resolve promise when loading is complete. Parameters: Name Type Description resolve function resolve function of the constructor Promise × Search results Close "},"SpriteElement.html":{"id":"SpriteElement.html","title":"Class: SpriteElement","body":" EvolveJS Modules Elements Classes BoxElementButtonElementElementHelpersImageElementLabelElementListElementListItemElementPreloaderSpriteElementTextElement Class: SpriteElement SpriteElement SpriteElement class, extending Element new SpriteElement(options) constructs an SpriteElement instance Parameters: Name Type Description options Object the options object to be merged with defaults Extends Element Methods align(parentElement, mode) Aligns the Element instance, based on it's parent bounds or specified parentElement bounds and mode parameter Parameters: Name Type Description parentElement Object | null if null, it considers the actual Element instance parent, otherwise it aligns in base of the specified parentElement mode String can be a set of one or two strings (blank separated) in any order, for horizontalModes (left, center, right), for verticalModes (top, middle, bottom) Inherited From: Element#align Returns: to make chainable the method Type Element animate(options) animates the sprite Parameters: Name Type Description options Object the animate options including Properties Name Type Description animationName String the animation name in the spritesheet json to start function Returns: Type SpriteElement bindEvents() binds all events specified in the settings object for the Element instance, it supports all DrawJS classes events (eg. click, mouseover, etc...) Inherited From: Element#bindEvents draw() draws all graphic elements of the Element instance Inherited From: Element#draw drawElements() draws all graphic elements of the SpriteElement instance getComputedBounds() returns the actual computed bounds of the Element instance, including scale factor and top, right, bottom, left coordinates Inherited From: Element#getComputedBounds Returns: the actual Element instance computed bounds object { { top: number, right: number, bottom: number, left: number, x: number, y: number, width: number, height: number } } Type Object init() empty init method, to be overriden in classes that extends Element, to use for all those initializations you might need after having rendered the Element Inherited From: Element#init initData() initializes data object for the Element instance Inherited From: Element#initData initDefaults() Initialize default settings for SpriteElement Overrides: Element#initDefaults initSettings(options) initializes settings object for the Element instance Parameters: Name Type Description options Object the options object to be merged with defaults Inherited From: Element#initSettings setCache(cacheOptions, force) sets or updates the Cache of the Element instance Parameters: Name Type Description cacheOptions Object | Shadow .. force Boolean .... Inherited From: Element#setCache Returns: to make chainable the method Type Element setComputedBounds(boundsOptions) sets or updates the bounds of the Element instance Parameters: Name Type Description boundsOptions Object | Number ... Inherited From: Element#setComputedBounds Returns: to make chainable the method Type Element setMask(maskOptions, force) sets or updates the Mask of the Element instance Parameters: Name Type Description maskOptions Object | Shadow can be an object with {color, x, y, blur}or directly an instance of Shadow (DrawJS) force Boolean .... Inherited From: Element#setMask Returns: to make chainable the method Type Element setPosition( [positionOptions] [, override] [, force]) sets or updates the position of the Element instance Parameters: Name Type Argument Default Description positionOptions Object &lt;optional&gt; null can contain x and y or only one or them Properties Name Type Argument Default Description x Number &lt;optional&gt; 0 the x position y Number &lt;optional&gt; 0 the y position override Boolean &lt;optional&gt; false specify to override actual Element position force Boolean &lt;optional&gt; true ... Inherited From: Element#setPosition Returns: to make chainable the method Type Element setReg() sets to center/middle the regPoint of the Element instance Inherited From: Element#setReg setScale(scaleOptions) sets or updates the scaling of the Element instance Parameters: Name Type Description scaleOptions Object | Number can be an object with x and y couple or only a number to be used for both Inherited From: Element#setScale Overrides: Element#setScale Returns: to make chainable the method Type Element setShadow(shadowOptions, force) sets or updates the Shadow of the Element instance Parameters: Name Type Description shadowOptions Object | Shadow can be an object with {color, x, y, blur}or directly an instance of Shadow (DrawJS) force Boolean .... Inherited From: Element#setShadow Returns: to make chainable the method Type Element × Search results Close "},"TextElement.html":{"id":"TextElement.html","title":"Class: TextElement","body":" EvolveJS Modules Elements Classes BoxElementButtonElementElementHelpersImageElementLabelElementListElementListItemElementPreloaderSpriteElementTextElement Class: TextElement TextElement extends Element Class adding an EaselJS Text instance inside of it new TextElement(options) constructs a TextElement instance Parameters: Name Type Description options Object the options to be merged with defaults settings Methods drawElements() draws all graphic elements of the TextElement instance getText() gets the actual text content Returns: Type String initDefaults() initializes defaults settings for TextElement initSettings(options) initializes the settings object for the TextElement instance Parameters: Name Type Description options Object the options to be merged with the defaults settings setComputedBounds() computes the bounds based on specified text parameter setText(text) sets the text content for the TextElement instance, considering also the textOutline Parameters: Name Type Description text String the text content Returns: to make chainable the method Type TextElement × Search results Close "}} </script> <script type="text/javascript"> $(document).ready(function() { Searcher.init(); }); $(window).on("message", function(msg) { var msgData = msg.originalEvent.data; if (msgData.msgid != "docstrap.quicksearch.start") { return; } var results = Searcher.search(msgData.searchTerms); window.parent.postMessage({"results": results, "msgid": "docstrap.quicksearch.done"}, "*"); }); </script> </body> </html>