Whiz-DOM Wiki
Formerly CraveJs, it's for creating JavaScript applications and games.
Status: Abandoned
Brought to you by:
winstontamblyn
| package | crv.display |
|---|---|
| extends | crv.display.EventDispatcher |
| inherits | EventDispatcher → Class |
| All objects that are rendered on-screen inherit from the DisplayObject class. A DisplayObject can not be initialized or extended. Use one of the many objects that natively inherit from this class, like Sprite, Shape, and Bitmap to name a few. | |
| Properties | ||
|---|---|---|
| alpha | number | A number from 0 to 1 that affects the transparency of the object. |
| name | string | A string that represents the object within it's parent container. |
| offsetX | number | The amount on the x-axis that the object is translated. |
| offsetY | number | The amount on the y-axis that the object is translated. |
| parent | DisplayObjectContainer | The parent container of this object. |
| rotation | number | The amount of rotation applied to the object. Ranges from -180 to 180 and rotates around the object's origin. |
| scaleX | number | The amount of scale on the object's width. |
| scaleY | number | The amount of scale on the object's height. |
| skewX | number | The amount of skew applied to the x-axis. |
| skewY | number | The amount of skew applied to the y-axis. |
| stage | Stage | The instance of Stage where everything is added. This property isn't set until it is added to the stage. |
| x | number | The x-coordinates of the object's origin. |
| y | number | The y-coordinates of the object's origin. |
| Methods |
|---|
| addTo(dom:DOMElement, pos:number):undefined
[internal use] Adds the DisplayObject to the dom element at a certain position, if provided. |
| removeFrom(dom:DOMElement):undefined
[internal use] Removes the DisplayObject from the dom element. |
| scale(sx:number, sy:number):undefined
Sets scaleX and scaleY to the given values. |
| skew(sx:number, sy:number):undefined
Sets the objects skewX and skewY to the given values. |
| translate(dx:number, dy:number):undefined
Translates the object by dx and dy, adding the values to the objects offset properties. |