Managers are composite widgets that contain primitives, gadgets, or other managers. Managers are responsible for the geometrical arrangement of their children. They also process and dispatch input to their gadget children. Specialized Motif managers include frames , scrolled and paned windows , menus , constraint-based geometry managers, and several kinds of dialogs. Shells are widgets whose main purpose is to communicate with the window manager.
Most shells have only one child, and they maintain the same size and position as the child.
Specialized Motif shells exist to envelop applications , dialogs , and menus . Defining a widget hierarchy is one of the two main tasks of a Motif application. The other is to define a set of callback procedures . Callbacks are the primary means by which the application responds to user input. When the user takes an action like pressing a key or a mouse button, the X server sends the application an event .