Creating Renderings for List Objects

An the object with a type definition of the form TypeA[] -> TypeB is referred to as a "list object". Instances of list objects can have any number of parameters. In the Rendering Editor, you can create renderings with zero parameters, one parameter, or you can create a list rendering that defines how the object is rendered when an instance of the object has more than one parameter.

If the type definition of the object has the form:

TypeA[] → TypeB

then when you create a new rendering, the Rendering Editor will open with a rendering that looks like this:

Note that there are two groups in this rendering, but that in the Rendering Tree only the first list group has any components in it. The second list group is just a mirror of the first list group with the "b" parameter replaced by "…".

When a list object is rendered, the rendering will contain a group of components for each parameter in the current instance of the object other than the first parameter. For example, if we open a document section and create an instance of MyListObject with 4 parameters, then the rendering is:

When working with list objects, there are several constraints on what can be done with the parameters and groups:
  • You can't move the "b" parameter out of List group 1
  • You can't put anything in List group 2. It will always just be a mirror of List group 1 with "…" in place of "b"
  • The "a" parameter can't be moved into List group 1
  • You can't add or delete parameters from the rendering. You can create a zero parameter or one parameter rendering for the object by right clicking on the object in the Object Module and selecting Add rendering... and then selecting either MyListObject[a] or MyListObject.