What are Morphs?
Last updated at 11:01 am UTC on 26 August 2016
A Morph is the central abstraction of Morphic. The word Morph comes from the Greek for "shape" or "form". A morph is simply a Squeak object that has a visual representation that can be picked up and moved.
In addition, a morph may:
- perform actions in response to user inputs;
- perform an action when another morph is dropped onto it, or when it is dropped onto another morph;
- perform an action at regular intervals; and
- control the placement and size of its submorphs.
- + Any morph can have component morphs (called submorphs).
- +A morph with submorphs is called a composite morph.
- The submorphs are said to be "embedded" in the composite morph.
- The submorphs can in turn be composite morphs, to any depth.
- Each morph can be embedded in at most one composite morph, so the submorph relation defines a tree of morphs.
- A composite morph is treated as a single unit: moving, copying, or deleting a composite morph causes all its submorphs to be moved, copied, or deleted as well.
- By convention, all morphs are visible; morphic does not use invisible structural morphs for aggregation. This means that if a composite morph is disassembled, all its component morphs can be seen and manipulated.
Much more about Morphs at: Morph