#include        <Xm/TextF.h>
#include        <Xm/RowColumn.h>

int
main(int ac, char *av[])
{
    XtAppContext app;
    Widget text[3], rc, top;
    int  i;

    top = XtAppInitialize(&app, "Sample", NULL, 0, &ac, av, NULL, NULL, 0);

    rc = XmCreateRowColumn(top, "rc", NULL, 0);
    XtManageChild(rc);
    text[0] = XmCreateTextField(rc, "text1", NULL, 0);
    text[1] = XmCreateTextField(rc, "text2", NULL, 0);
    text[2] = XmCreateTextField(rc, "text3", NULL, 0);
    XtManageChildren(text, 3);

    for (i = 0; i < 3; i++)
	XtAddCallback(text[i], XmNactivateCallback,
		      (XtCallbackProc)XmProcessTraversal,
		      (XtPointer)XmTRAVERSE_NEXT_TAB_GROUP);
    XtRealizeWidget(top);
    XtAppMainLoop(app);
}
