Package Things :: Module timeline :: Class Timeline
[frames] | no frames]

Class Timeline

object --+
         |
        Timeline
Known Subclasses:

A Timeline is a collection of Things.

Instance Methods
 
__init__(self)
x.__init__(...) initializes x; see x.__class__.__doc__ for signature
 
add(self, thing, layer=-1, parentFrame=1, globalProps=None)
Add a Thing to this Thing's Timeline.

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

Instance Variables
  parentThing
A reference to my parent.
Properties

Inherited from object: __class__

Method Details

__init__(self)
(Constructor)

 

x.__init__(...) initializes x; see x.__class__.__doc__ for signature

Overrides: object.__init__
(inherited documentation)

add(self, thing, layer=-1, parentFrame=1, globalProps=None)

 

Add a Thing to this Thing's Timeline. There is one Timeline per Thing, but you can add many Things to this Timeline.

A layer can be supplied, larger numbers go above smaller ones.

Use

YourThing.add( SomeOtherThing, layer=10, parentFrame = 2)

Parameters:
  • thing - The Thing you want to add.
  • layer - Layering of this thing (z-order.) 0 is the bottom. The default is to draw everything overlapping on layer zero. If you want to use thing.changeLayer() then make sure you give things layers that are > 0.
  • parentFrame - What frame number (in self) you want the thing being added to begin playing from. This is the same as padding the thing being added with blanks "....#" implies it starts from frame 5. So you could have "#" and set parentFrame = 5 instead.
  • globalProps - This is a Props() object. If you skip it, an ordinary Props() object is employed (position 0, alpha 1 etc.) If you want to control the placement/rotation of the Thing you are adding, then use this param.