ABSTRACT

Primitive widgets are the "worker" widgets, and as such are the most important ones to understand how to construct. This chapter discusses the two additional kinds of widgets: composite and constraint. The composite widget is a layout-manager type of abstraction. Essentially, it provides client writers with some useful layout mechanisms so that the details of laying out widgets are somewhat removed. In the Athena Widget Set, the BoxWidgetClass is an example of this kind of widget. The client writer simply defines a few resources to instruct the BoxWidget about how spacing should be handled for the children widgets, and then proceeds to add/delete children. The first member of the class structure is a pointer to "geometry_manager." This is a method that performs the negotiation between the widget's children and itself. The CoreClassPart contained a member for a method called query_geometry.