A pergola.Menu object instantiates its components and you don't need to instantiate explicitly the pergola.MenuList and pergola.MenuItem classes. A menu can be appended to a menu bar (whether painted or not) on the pergola.taskbar, in a window, or on the desk. A pergola.Window object automatically builds a menubar if the property menu is set at instantiation.
Pergola classes allow both method chaining and deferred construction. The latter allows you to predefine objects and their component objects, keeping a clean structure that gives you at a glance control, and allows dynamic or conditional construction:
The deferred construction of the menu components: