#include <Xm/PushB.h>
#include <Xm/Form.h>
#include <Xm/MessageB.h>
#include <Xm/RowColumn.h>
#include <Xm/TextF.h>
#include <Xm/Label.h>

#include <stdio.h>
#include <unistd.h>

#include <sys/types.h>
#include <sys/stat.h>
#include <fcntl.h>


String fallbacks [] = {
  "*fontList: -*-new century schoolbook-bold-r-*--17-*",
  "*Hostname.labelString: Hostname:",
  "*Ipaddr.labelString: IP Address:",
  "*Netmask.labelString: Netmask:",
  "*Phone.labelString: Phone Number:",
  NULL
};


int main(int argc, char *argv[])
{
  Widget toplevel, rc, ok, cancel, form;
  Widget hostname, ipaddr, netmask, phone;
  Widget hostname_text, ipaddr_text, netmask_text, phone_text;
  XmString str;
  XtAppContext app;


  XtSetLanguageProc(NULL, NULL, NULL);
  
  toplevel = XtVaAppInitialize(&app, "XPppinst", NULL, 0,
			       &argc, argv, fallbacks, NULL);

  form = XtVaCreateManagedWidget("Form", xmFormWidgetClass, toplevel, NULL);

  rc = XtVaCreateManagedWidget("Rc", xmRowColumnWidgetClass, form,
			       XmNnumColumns, 4,
     			       XmNorientation, XmHORIZONTAL,
			       XmNpacking, XmPACK_COLUMN,
			       XmNisAligned, True,
			       XmNentryAlignment, XmALIGNMENT_END,
			       XmNrightAttachment, XmATTACH_FORM,
			       NULL);
  

  hostname = XtVaCreateManagedWidget("Hostname", xmLabelWidgetClass, rc,
				     NULL);
  hostname_text = XtVaCreateManagedWidget("Hostname_text", 
					  xmTextFieldWidgetClass, rc,
					  NULL);
  ipaddr = XtVaCreateManagedWidget("Ipaddr", xmLabelWidgetClass, rc,
				   NULL);
  ipaddr_text = XtVaCreateManagedWidget("Ipaddr_text", xmTextFieldWidgetClass,
					  rc, NULL);
  netmask = XtVaCreateManagedWidget("Netmask", xmLabelWidgetClass, rc,
				    NULL);
  netmask_text = XtVaCreateManagedWidget("Netmask_text",
					 xmTextFieldWidgetClass, rc,
					 NULL);
  phone = XtVaCreateManagedWidget("Phone", xmLabelWidgetClass, rc,
				  NULL);
  phone_text = XtVaCreateManagedWidget("Phone_text", xmTextFieldWidgetClass,
				       rc, NULL);

  /*
  ok = XtVaCreateManagedWidget("Ok", xmPushButtonWidgetClass, rc,
			       NULL);
  
  cancel = XtVaCreateManagedWidget("Cancel", xmPushButtonWidgetClass, rc,
				   NULL);

				   */
  XtRealizeWidget(toplevel);
  XtAppMainLoop(app);

}

