'\"macro stdmacro
.if n .pH g3w.olPkWid @(#)olPkWid	40.3 of 1/8/90
.ds oS PACKED
.nr oN 0
.nr X
.if \nX=0 .ds x} ""PACKED WIDGETS" 3W "\&"
.if \nX=1 .ds x} ""PACKED WIDGETS" 3W
.if \nX=2 .ds x} ""PACKED WIDGETS" "" "\&"
.if \nX=3 .ds x} ""PACKED "" "" "\&"
.TH \*(x}
.SH "SYNOPSIS"
.nf
\s-1\f4#include <Intrinsic.h>
#include <StringDefs.h>
#include <OpenLook.h>
.P
\s-1\f4typedef struct {
        Widget widget_returned;
        String name;
        WidgetClass *class_ptr;
        Widget *parent_ptr;
        String descendant;
        ArgList resources;
        Cardinal num_resources;
        Boolean managed;
} OlPackedWidget;
.P
\s-1\f4Widget = OlCreatePackedWidgetList(pw_list, num_pw)
OlPackedWidget *pw_list;
Cardinal num_pw;\f1\s+1
.fi
.SH "DESCRIPTION"
.sp
\f3Create Widget (Sub)Trees in One Call\f1
.P
The
\f4OlCreatePackedWidgetList()\f1
routine and its associated
\f4OlPackedWidget\f1
structure allow an application to create a widget tree or
subtree in one call.
.P
The tree is pointing to \f4pw_list\f1.
Each element in this array is of the type
\f4OlPackedWidget\f1.
This structure gives all the information needed to create a new
widget:
.IP \f4widget_returned\f1 8 
will contain the ID of the newly created widget. 
.IP \f4name\f1 8
is the name of the widget that will be created.
.IP \f4class_ptr\f1 8
is a
\f2pointer\f1
to the
\f4WidgetClass\f1
pointer for the new widget.
This gives the class of widget to create.
It is a pointer to the pointer because typically the pointer
itself is an external value that is not suitable for using in
an array initialization;
the pointer to the pointer is.
.IP \f4parent_ptr\f1 8
is a pointer to the widget ID of the intended parent of the new
widget \f2or\f1 the ID of an indirect widget that "knows who
the parent is" (see below).
This value may point to a
\f4\&.widget\f1
member in another
\f4PackedWidget\f1
item;
if the parent is an indirect widget,
it must appear earlier in the list.
.IP \f4descendant\f1 8
is the name of a resource available in the widget identified by
\f4parent_ptr\f1.
The value of this resource is the ID of the real parent
for the new widget.
.IP \& 8
If the
\f4\&.descendant\f1
value is not zero,
\f4\&.parent\f1
is expected to identify an indirect parent that is interrogated
for the ID of the real parent.
If this value is zero,
\f4\&.parent\f1
is expected to identify the real parent.
.in
.IP \f4resources\f1 8
is the resource array to use when creating the new widget. 
.IP \f4num_resources\f1 8
is the number of resources in the array.
.IP \f4managed\f1 8
is
\f4TRUE\f1
if the new widget should be managed when created,
\f4FALSE\f1
otherwise.
.P
The
\f4OlCreatePackedWidgetList()\f1
is passed a pointer to an
\f4OlPackedWidget\f1
array and the number of elements in the array.
It creates widgets starting from the first element in the
array, and returns the ID of the topmost widget.
