Click or drag to resize
Entity Methods

The Entity type exposes the following members.

Methods
  NameDescription
Public methodAddChild
Add a child entity.
Public methodAttachAnimator
Add animator to this entity.
Public methodBringToFront
Bring this entity to be on front (inside its parent).
Public methodCalcDestRect
Calculate and return the destination rectangle, eg the space this entity is rendered on.
Public methodClearChildren
Remove all children entities.
Public methodDraw
Draw this entity and its children.
Public methodEquals
Determines whether the specified object is equal to the current object.
(Inherited from Object.)
Public methodFind(String, Boolean)
Find and return first occurance of a child entity with a given identifier.
Public methodFindT(String, Boolean)
Find and return first occurance of a child entity with a given identifier and specific type.
Public methodGetActiveStyle
Return stylesheet property for current entity state (or default if undefined for state).
Public methodGetActualDestRect
Return actual destination rectangle. This can be override and implemented by things like Paragraph, where the actual destination rect is based on text content, font and word-wrap.
Public methodGetHashCode
Serves as the default hash function.
(Inherited from Object.)
Public methodGetRelativeOffset
Return the relative offset, in pixels, from parent top-left corner.
Public methodGetStyleProperty
Return stylesheet property for a given state.
Public methodGetType
Gets the Type of the current instance.
(Inherited from Object.)
Public methodIsDeepChildOf
Check if this entity is a descendant of another entity. This goes up all the way to root.
Public methodIsDisabled
Return if this entity is currently disabled, due to self or one of the parents / grandparents being disabled.
Public methodIsLocked
Return if this entity is currently locked, due to self or one of the parents / grandparents being locked.
Public methodIsTouching
Test if a given point is inside entity's boundaries.
Public methodIsVisible
Return if this entity is currently visible, eg this and all its parents and grandparents are visible.
Public methodIterateChildren
Iterate over children and call 'callback' for every direct child of this entity.
Public methodStatic memberMakeSerializable
Make an entity type serializable.
Public methodPropagateEventsTo
Propagate all events trigger by this entity to a given other entity. For example, if "OnClick" will be called on this entity, it will trigger OnClick on 'other' as well.
Public methodRemoveAnimator
Remove animator from entity.
Public methodRemoveChild
Remove child entity.
Public methodRemoveFromParent
Remove this entity from its parent.
Public methodSendToBack
Push this entity to the back (inside its parent).
Public methodSetAnchorAndOffset
Set the position and anchor of this entity.
Public methodSetStyleProperty
Set a stylesheet property.
Public methodToEntitiesDictionary
Create and return a dictionary of entities, where key is Identifier and value is the entity. This will include self + all children (and their children), and will only include entities that have Identifier property defined. Note: if multiple entities share the same identifier, the deepest entity in hirarchy will end up in dict.
Public methodToString
Returns a string that represents the current object.
(Inherited from Object.)
Public methodUpdate
Called every frame to update entity state and call events.
Public methodUpdateStyle
Update the entire stylesheet from a different stylesheet.
Top
See Also