@begin(header)
author: ackerman@ics.uci.edu
show_author: ShowNone
author_organization: MIT
node_expert: ackerman=ag@ics.uci.edu 
expiration_date: 08/29/93
last_modifier: ackerman@ics.uci.edu
last_mod_date: 08/29/91
mod_num: 3
@end(header)
/***************************************************

bye_bye.c

	This code creates one command button inside
	a shell.  It uses the Athena widget set.

	This is an example of beginning Xt code.
	It has code for handling callbacks and events.
	It shows the R4 style of writing, including
	using application contexts.


	Mark Ackerman
	first written June, 1987 

****************************************************/



#include <X11/Intrinsic.h>
#include <X11/StringDefs.h>
#include <X11/Xaw/Command.h>

void bye_bye(widget, client_data, call_data)
     Widget widget;
     XtPointer client_data;
     XtPointer call_data;
{
  exit();
}

main(argc,argv)
     int argc;
     char **argv;
{
  Widget shell;
  Widget command;
  XtAppContext app_context;
  
  shell = XtAppInitialize(&app_context,"SmallButBoring",NULL,0,&argc,argv,
			  NULL,NULL,0);

  command = XtCreateManagedWidget("quit",commandWidgetClass,
				  shell, NULL, 0);
  XtAddCallback(command,XtNcallback,bye_bye,NULL);

  XtRealizeWidget(shell);
  XtAppMainLoop(app_context);
}
