Ooidget Component Format 0.1Editor's Draft
Extensions and fallbacks
Extensions
An extension adds members, layer kinds, effect types or events. It is named PREFIX_name, where PREFIX is an
uppercase vendor prefix: OOIDGET for extensions of this project, otherwise a prefix registered in the
specification’s repository. Extension data lives in extensions.PREFIX_name on the component or on the object it
extends.
A component file lists every extension it uses in extensionsUsed, and those without which it cannot be rendered
meaningfully in extensionsRequired. A runtime MUST NOT render a component that requires an extension it does not
support; it reports this to the host instead.
Fallbacks
To keep documents usable across runtimes of different ages and profiles, a runtime MUST treat what it does not understand as follows, and MUST NOT fail:
| It does not understand | It MUST |
|---|---|
| a member of a known object | ignore the member |
| a layer kind | skip the layer, or draw its fallback layer if it has one |
| an effect type | skip the effect |
| a host-drawn name (slot, primitive, painter) the host does not know | draw the layer’s fallback, else nothing |
| an event handler name | never call it |
an extension in extensionsUsed only | proceed without it |
A layer’s fallback is a layer, drawn in its place with its box.