Package: pumpkin.display

DisplayObject


Description

The DisplayObject is a base class that can be added to a display lists.

All functionality is derrived from this class, any object that appears on the screen or is rendered will inherit this class.


Constructors

DisplayObject

Create empty display object.


Functions

getFullMatrix

Get the combined matrix.

getFullMatrix

Get the combined matrix.

setBounds

Set the DisplayObject local bounding box.

getBounds

Returns a Rectangle of the DisplayObject relative to the target.

updateBounds

Updates local bounding box from the DisplayObject contents.

getMatrix

Get the DisplayObject transform matrix.

setMatrix

Set the local transform matrix.

setMatrixOverride

setMatrixOverride

setTransformInfo

getObjectUnderPoint

Get the DisplayObject under the x,y position.

getObjectUnderPoint

Get the DisplayObject under the position.

localToGlobal

Transform the local position to global stage space.

globalToLocal

Transform the global position to local space.

globalToLocal

Transform the global position to local space.

getInheritedAlpha

Helper to calculate the inherited alpha blend value from the DisplayObject parents.

getInheritedColor

Helper to calculate the inherited color transform from the DisplayObject parents.

getInheritedBlendMode

Helper to calculate the inherited blendmode from the DisplayObject parents.

updateFrame

Frame update handler ( internal )

invalidateMatrix

Invalidate internal transform matrix cache.

getChildByName

Get a child DisplayObject by name.

getChildByName< T >

Get a child DisplayObject by name.

getChildAt

Get a child DisplayObject at an index.

getChildAt< T >

Get a child DisplayObject at an index.

setBlendmodeChildren

Sets the color transform and every child object ( unstable ).

setColorTransformChildren

Sets the color transform and every child object ( unstable ).

broadcastEvent

Broadcast event to the DisplayObject and its children.

fireEvent

Fire event on the current DisplayObject.

startDrag

Start dragging the DisplayObject, locks position relative to the mouse position.

startDrag

Start dragging the DisplayObject, release on global mouse up.

startDrag

Start dragging the DisplayObject, constrain to a rectangle.

stopDrag

Stop dragging this DisplayObject.

getMatrixRaw


Variables

stage

A reference to the Stage when this or one of its parents exist on the stage.

name

Indicates the name of the DisplayObject.

dirtyMask

Flags changes to display objects.

rotateX

Not imlemented.

rotateY

Not imlemented.

rotateZ

Not imlemented.

userData

Associate user data with this display object.

cachedCid

tweens

translateX

Not implemented.

translateY

Not implemented.

translateZ

Not implemented.

clipRect

Clip rect, clips contents this object and its children in the given rectangle in local space.

hasClipRect

Has clip rect.

mask

[alpha][dev] Experimental bitmap mask implementation.

mouseX

Indicates the local mouse x position in pixels.

mouseY

Indicates the local mouse y position in pixels.

x

Indicates the x coordinate of the DisplayObject in local coordinates relative to the parent DisplayObjectContainer.

y

Indicates the y coordinate of the DisplayObject in local coordinates relative to the parent DisplayObjectContainer.

zWorldOffset

Indicates the z offset of the DisplayObject in world coordinates.

rotation

Indicates the rotation of the DisplayObject in degrees relative to the parent DisplayObjectContainer.

scaleX

Indicates the x scale of the DisplayObject in normal units relative to the parent DisplayObjectContainer.

scaleY

Indicates the y scale of the DisplayObject in normal units relative to the parent DisplayObjectContainer.

alpha

Indicates the alpha blending value of the DisplayObject.

internalAlpha

visible

Indicates the DisplayObject visibility.

internalVisible

parent

Set when the DisplayObject is attached to a parent DisplayObjectContainer.

width

Indicates the DisplayObject width in pixels.

height

Indicates the DisplayObject height in pixels.

blendMode

Indicates the DisplayObject blend mode.

colorTransform

Indicates the DisplayObject color transform.

scale9Grid

srcTransformInfo

Indicates transform info applied to this DisplayObject from the exported swf.

srcWidth

Exported source width in pixels.

srcHeight

Exported source height in pixels.

interactionInfo

Indicates interaction info, useful for associating interactive meta data with display objects such as tab/joystick index, tooltips etc.

uniqueDispId

Indicates unique display object id.


Inherited members

Functions

EventCallback

addEventListener

Add listener function to response to the event type.

addEventListener

Add listener function to response to the event type with capture.

addGameObjectEventListener

Add GameObject message handler, dispatching event sends message to the method name listenerFun.

addGameObjectEventListener

Add GameObject message handler, dispatching event sends message to the method name listenerFun with capture.

dispatchEventReturnVoid

Same as dispatchEvent but void return type workarround for closures.

dispatchEvent

Dispatches an even bound using addEventListener.

removeAllEventListeners

Remove all event listeners.

removeEventListener

Remove event listener.

removeEventListener

Remove event listener with capture.

removeGameObjectEventListener

Remove event listener.

removeGameObjectEventListener

Remove event listener with capture.

willTrigger

Returns true if the event is being listened on.

hasEventListener

Returns true if the event is being listened on.

getEventListeners

Returns all event listeners.


Variables

MAX_RECURSE

Global max call depth all event dispatchers can recurse.