home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
vis-ftp.cs.umass.edu
/
vis-ftp.cs.umass.edu.tar
/
vis-ftp.cs.umass.edu
/
pub
/
Software
/
universal_plane_file_format
/
NewXShowPlane
/
main.c
< prev
next >
Wrap
C/C++ Source or Header
|
1993-12-06
|
2KB
|
74 lines
/*
** Generated by X-Designer Evaluation version
** This code may not be used in any program
** offered for resale or commercial use.
*/
/*
**LIBS: -lXm -lXt -lX11
*/
#include <X11/Xatom.h>
#include <X11/Intrinsic.h>
#include <X11/Shell.h>
#include <Xm/Xm.h>
#include <Xm/CascadeB.h>
#include <Xm/DialogS.h>
#include <Xm/DrawingA.h>
#include <Xm/FileSB.h>
#include <Xm/Form.h>
#include <Xm/List.h>
#include <Xm/MainW.h>
#include <Xm/MessageB.h>
#include <Xm/PushB.h>
#include <Xm/RowColumn.h>
#include <Xm/ScrollBar.h>
#include <Xm/SelectioB.h>
#include <Xm/Text.h>
#include <Xm/LabelG.h>
#include <Xm/PushBG.h>
#include <Xm/SeparatoG.h>
#include <stdio.h>
#include "widgets.h"
XtAppContext app_context;
Display *display; /* Display */
extern void InstallColorMap();
extern void UninstallColorMap();
static XtActionsRec colormap_actions[] = {
{"install", InstallColorMap},
{"uninstall", UninstallColorMap}
};
int main (argc,argv)
unsigned int argc;
char **argv;
{
XtToolkitInitialize ();
app_context = XtCreateApplicationContext ();
display = XtOpenDisplay (app_context, NULL, argv[0], "XShowPlane",
NULL, 0, &argc, argv);
if (!display)
{
printf("%s: can't open display, exiting...\n", argv[0]);
exit (-1);
}
/* Register converters, just in case you are really unlucky !! */
XmRegisterConverters();
/* String to unit type doesn't get added !! */
XtAddConverter ( XmRString, XmRUnitType, XmCvtStringToUnitType, NULL, 0 );
XtAppAddActions (app_context, colormap_actions,
XtNumber(colormap_actions));
create_toplevel_widget ( display, argv[0], argc, argv );
create_message_box_dialog_widget ( toplevel_widget );
create_image_file_popup_widget ( toplevel_widget );
XtRealizeWidget (toplevel_widget);
XtAppMainLoop (app_context);
exit (0);
}